TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
hamid khan
NA
4
35.7k
Compiler Error Message: CS0161: '_Default.parseValue(string, string, string, bool)': not all code paths return a value
Sep 17 2010 9:10 AM
hi guys i am getting the above error in my code - below
pleas help me what is wrong in this code as i am a beginner in csharp programming
thanks in advance
public string parseValue(String responseBody, String prefix, String posix, bool include1)
{
String action;
int i;
//try to find the first type
i = responseBody.IndexOf(prefix);
if (i >= 0)
{
if (include1)
{
action = responseBody.Substring(i);
}
else
{
action = responseBody.Substring(i + prefix.Length);
}
if (!posix.Equals(""))
{
action = action.Substring(0, action.IndexOf(posix));
return action.Trim();
}
throw new Exception("Value '" + prefix + "' not found");
}
}
Reply
Answers (
1
)
Refresh VS 2010 rdlc files (report viewer)
Database connection (datasetdesigner previewing data)