karthi vimala

karthi vimala

  • NA
  • 49
  • 51.1k

not all code path return a value

Mar 2 2011 6:18 AM
hi,

   when i use the codings i have an error like not all code path return a value.how can i solve this


public

string

try{

       if

         {

                companymailid = mailname;

                Session["cmailid"] = companymailid;

                Server.Transfer(

          }

             {

                  companymailid = "";

              }


       }

else     return companymailid;}
"mail.aspx");
(mailname != null)
companymailid;
string mailid(string mailname){

Answers (8)