Description Resource Path Location Type
Save error: Unknown property 'DecoratedCM.LastName' EventCheckIn.page /RVS Working 2/src/pages line 1 Force.com save problemI Have the following code in my controller class:void loadData() { members = new List<DecoratedCM>(); for(CampaignMember m : [select Id, ContactId, LeadId, INS_Territory__c, ANN_Territory__c, Contact.FirstName, Contact.Name, Contact.LastName, Lead.Name, Contact.email, Lead.email, Contact.phone, Contact.Onyx_ID__c, Status,LastModifiedDate from CampaignMember where CampaignId = :theCampaign.id]) { members.add(new DecoratedCM(m)); System.debug('>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>' + m.contact.lastname); } }Line on VF Page where error happens : <apex:column value="{!m.LastName}"/>Any help would be greatly appreciated..Lawrence
1 answer

It's telling you that your DecoratedCM class, presumably a wrapper class, doesn't have a variable named "LastName". Not sure what the DecoratedCM class looks like, but if you have a member variable for CampaignMember, you could access LastName via {!m.member.Contact.LastName}, for example.Also, please use the code formatting button (< >) when posting Apex or Visualforce. Thanks!