Sha1395
asked on
Error :"The name (fname) doesn't exist in the current context"
I have code like below,but am trying to pas fname to search filter its throwing error
Error :"The name (fname) doesn't exist in the current context",some one enlighten me
Error :"The name (fname) doesn't exist in the current context",some one enlighten me
if (username.Contains("."))
{
string Fname = username.Substring(0, username.IndexOf("."));
Fname = Fname.Replace(" ", "");
string[] splitString = username.Split(new char[] { '.' });
username = splitString[splitString.Length - 1];
}
if (username.IndexOf(" ") > 0)
search.Filter = "(cn=" + username + ")";
else
search.Filter = "(sn=" + username + ")(givenname=" + Fname + ")";
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
I've requested that this question be deleted for the following reason:
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
Author has figured out the same aolution which is suggested by carl_tawn and my self provided an explanation for the question asked for.
Hence solution assistence is provided by both the comments which is also accepted by the author.
Hence solution assistence is provided by both the comments which is also accepted by the author.
All,
Following an 'Objection' by Sudhakar-Pulivarthi (at https://www.experts-exchange.com/questions/27177969/Automated-Request-for-Review-Objection-to-Delete-Q-26843333.html) to the intended closure of this question, it has been reviewed by at least one Moderator and is being closed as recommended by the Expert.
At this point I am going to re-start the auto-close procedure.
Thank you,
SouthMod
Community Support Moderator
Following an 'Objection' by Sudhakar-Pulivarthi (at https://www.experts-exchange.com/questions/27177969/Automated-Request-for-Review-Objection-to-Delete-Q-26843333.html) to the intended closure of this question, it has been reviewed by at least one Moderator and is being closed as recommended by the Expert.
At this point I am going to re-start the auto-close procedure.
Thank you,
SouthMod
Community Support Moderator
ASKER
anyway thank you so much.