@future(callout=true)
public static void Con_Opt_Invoke_Ins_Mtd(Id d)
{
Opportunity optrec=[select name, description, account.name from Opportunity where id=:d];
sobjectPartner3.Soap obj1 = new sobjectPartner3.Soap();
sobjectPartner3.LoginResult lr = obj1.login('adminnaveen@gmail.com','Rn98481649#');
Con_OpportunitiesCLS.Pub_OpportunitiesCls obj = new Con_OpportunitiesCLS.Pub_OpportunitiesCls();
obj.sessionHeader = new Con_OpportunitiesCLS.sessionHeader_element();
obj.sessionHeader.sessionid = lr.sessionId;
obj.Pub_InsertOptMtd(optrec.name, optrec.description, '0019000000RcEWX');
}
}
5 respuestas
Hi Naveen,
You need to add global in place of public class as you are using callout=true.
Let me know if this works