function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
testing123testing123 

Not getting personal information using apex code

Hello !

 

I have created application same as given link

 

http://wiki.developerforce.com/page/Force.com_for_ASP.NET_Developers

 

but i have made soime chages to class as follows:

 

global class GetLeadInfo {

  WebService static Lead GetLeadAddressByEmail(string LeadEmail) {
      Lead l= new Lead();
    List<Lead> c= new List<Lead>();
    c = [SELECT Street, City, State, PostalCode from Lead WHERE Email = :LeadEmail];
    if (c.size() > 0)
    {
        l = new Lead(Street = c[0].Street, City = c[0].City, State = c[0].State, PostalCode = c[0].PostalCode);
    }
    return l; 

  }
}

but i am not able to see response of city,state and etc. Though i am not getting any error but i am not getting any data too !

 

help me asap!

 

Thanks !

sdouglassdouglas

Hi testing123,

 

The response is going to come as a Lead sObject, not as those strings alone.