You need to sign in to do that
Don't have an account?
Zeel Sheth
Method does not exist or incorrect signature: void verify(String)
hii,
how to resolve Method does not exist or incorrect signature ?
my code:
public class VerifyAccountcls {
@AuraEnabled
public static void verify(List<String> recordid){
List<Account> acclist = new List<Account>();
for(Account acc:[select Id, Name, Phone, Website,
BillingStreet, BillingCity,
BillingState, BillingPostalCode, Verified__c from Account where Id in :recordid]){
acc.Verified__c = true;
acclist.add(acc);
}
if(acclist.size()>0){
update acclist;
}
}
@AuraEnabled
public static void unverify(List<String> recordid){
List<Account> acclist = new List<Account>();
for(Account acc:[select Id, Name, Phone, Website,
BillingStreet, BillingCity,
BillingState, BillingPostalCode, Verified__c from Account where Id in :recordid]){
acc.Verified__c = false;
acclist.add(acc);
}
if(acclist.size()>0){
update acclist;
}
}
}
thanks in advance,
Zeel
how to resolve Method does not exist or incorrect signature ?
my code:
public class VerifyAccountcls {
@AuraEnabled
public static void verify(List<String> recordid){
List<Account> acclist = new List<Account>();
for(Account acc:[select Id, Name, Phone, Website,
BillingStreet, BillingCity,
BillingState, BillingPostalCode, Verified__c from Account where Id in :recordid]){
acc.Verified__c = true;
acclist.add(acc);
}
if(acclist.size()>0){
update acclist;
}
}
@AuraEnabled
public static void unverify(List<String> recordid){
List<Account> acclist = new List<Account>();
for(Account acc:[select Id, Name, Phone, Website,
BillingStreet, BillingCity,
BillingState, BillingPostalCode, Verified__c from Account where Id in :recordid]){
acc.Verified__c = false;
acclist.add(acc);
}
if(acclist.size()>0){
update acclist;
}
}
}
thanks in advance,
Zeel
Refresh THe Dev Console Ans Try Agian Calling It
Try Calling As Below Please Mark It As Best Asnwer If It Helps
Thank You!
All Answers
I dont see any issue in the class while saving. Can you confirm is there any issue in calling the method or where exactly are you facing the issue.
Thanks,
Can you confirm how you are calling this method and what are the parameters you are giving while calling the method?
Thanks,
Refresh THe Dev Console Ans Try Agian Calling It
Try Calling As Below Please Mark It As Best Asnwer If It Helps
Thank You!
Due to calling time of verify method you need to send List of string like below:-
Here you need to pass list of Account Ids to verify method
if you need any assistanse, Please let me know!!
Kindly mark my solution as the best answer if it helps you.
Thanks
Mukesh