You need to sign in to do that
Don't have an account?
Rocks_SFDC
How to Pre - Populate the Name field for custom object in visual force page
Hi Team,
I would like to set the value for the name field for custom object in visual force page when we click on the "New" button. I just want to pre-populate the value to "Some Text". Can anyone help me out ?
Thanks,
Anil
I would like to set the value for the name field for custom object in visual force page when we click on the "New" button. I just want to pre-populate the value to "Some Text". Can anyone help me out ?
Thanks,
Anil
Please use the below syntax to auto-pouplate Name field for any custom object.
Le me know if you need more help on this.
All Answers
Please use the below syntax to auto-pouplate Name field for any custom object.
Le me know if you need more help on this.
And also we want to append "some text" lets say "Copy" to the Name field of a custom object when we click on "Clone" button.
Do we have any workaround for this.
Thanks in Advance,
Anil
The clone parameter is not available on URLfor function.
Clone button by default populates the value from a record on which your are clicking clone So if you want to populate different values other than the current record than you have to create a Custom VF page and in its controller you can change the values of field and than Overide your Clone button with this VF page.
There is no way to do it directly as we have done for New.
Let me know if you need more clarification or help on this.
Regards,
Abhishek.
if you send me some sample VF page and Controller code to achieve the functionality, then that could be great helpful.
Thanks,
Anil
If your original question has been solved than please mark it as SOLVED and it would be good to post you post your new question in another forum so that different questions do no mix up in the single forum.
Posting the new question in another forum will be helpful for everyone to find different solution of different question on different forums and it will alos avoids confusion.
So pelase make a new question of your current request and send me the link here, I will definitely reach you out there and provide you all the possible help.
Thanks,
Abhishek.