You need to sign in to do that
Don't have an account?

Invalid Type:MergeRequest
Hello All,
I want to use the api merge() method in this class. I created a apex class and I got the following error for this statement:
MergeRequest mr = new MergeRequest();
Error: Compile Error: Invalid type: MergeRequest at line 7 column 33
If any one could point what am I doing wrong and what should be my approach, I want to call this webservice through flex.
My reference document is
http://www.salesforce.com/us/developer/docs/api/Content/sforce_api_calls_merge.htm
global class clsWbSrv_MyService {
webService static String fnMyService (String StdObjType, String MasterId, String Slave1Id, String Slave2Id) {
String Result ='';
Account masterAccount = new Account();
MergeRequest mr = new MergeRequest();
.................
.................
.................
Result +=StdObjType + ' ' + MasterId + ' ' + Slave1Id + ' ' + Slave2Id;
return Result;
}
}
Thanks
Hector....
You appear to be reading the web services API docs, but trying to program in apex (which is different), check the apex language reference docs for how to do merges in apex.
All Answers
You appear to be reading the web services API docs, but trying to program in apex (which is different), check the apex language reference docs for how to do merges in apex.
Hi Simon,
Thanks for you reply. I have started looking out for merge call using apex itself.
I was trying to expose apex methods as web services, ref link :
http://www.salesforce.com/us/developer/docs/apexcode/index_Left.htm#CSHID=apex_deploying_additional.htm|StartTopic=Content%2Fapex_deploying_additional.htm|SkinName=webhelp
Thanks
Hector....