You need to sign in to do that
Don't have an account?
Amanda Byrne- Carolina Tiger Rescue
Can I prevent the display of an existing field value for an apex input field on a form?
We are launching a Tour Check-In app so guests may check in at a kiosk when they arrive.
The form makes use of the Attendee object that is part of our ticketing app. We do not collect attendee information in advance- the ticketing app creates Attendee records for each attendee with the ticket-purchaser's name at the time of ticket purchase.
Our custom app has a form to collect the attendee's information (they are agreeing to a legal release- so we need their mailing address). The form fields are blank when the guest goes to check in, except for the First Name and Last Name, which are populated with the purchaser's name
We'd prefer the fields were blank- I'm concerned that it would be too tempting not to bother modifying the name fields. Is there a way I can modify the code so that these fields are not prepopulated on the form?
Page Code
Constructor Code:
Thanks in advance! Amanda
The form makes use of the Attendee object that is part of our ticketing app. We do not collect attendee information in advance- the ticketing app creates Attendee records for each attendee with the ticket-purchaser's name at the time of ticket purchase.
Our custom app has a form to collect the attendee's information (they are agreeing to a legal release- so we need their mailing address). The form fields are blank when the guest goes to check in, except for the First Name and Last Name, which are populated with the purchaser's name
We'd prefer the fields were blank- I'm concerned that it would be too tempting not to bother modifying the name fields. Is there a way I can modify the code so that these fields are not prepopulated on the form?
Page Code
<detail>First Name<font class='detailError'>*</font></detail> <apex:inputField value="{!CnP_PaaS_EVT__Event_attendee_session__c.CnP_PaaS_EVT__First_name__c}" required="true" styleClass="detail" id="firstNameField" > <apex:param name="attendeeFirstNameParam" value="{!CnP_PaaS_EVT__Event_attendee_session__c.CnP_PaaS_EVT__First_name__c}" assignTo="{!attendeeFirstName}"/> </apex:inputField>
Constructor Code:
//Constructor public DTCI_Attendee_AB_Ctrl(ApexPages.StandardController controller) { attendee = (CnP_PaaS_EVT__Event_attendee_session__c) controller.getRecord(); eventId = ApexPages.currentPage().getParameters().get('eventPageId'); registrantId = ApexPages.currentPage().getParameters().get('registrantPageId'); }
Thanks in advance! Amanda
Andy Boettcher
You could have two String variables in your controller and bind them to your inputFields instead of the actual record values - then you can control them as you want but still retain the real values.