You need to sign in to do that
Don't have an account?
sunny.kapoor1306
Save button not working
I have created a 'save' button in vf page but it just refreshes the page without saving
In the apex class page refrence is created automatically
do i have to do something else too?
Hi,
May be its not returning anything Can you plz post the code.
Thanks
hmm... u r right
actually save coding was automatically done in apex classes
here is the code:
public class clsdisplayleads
{
public PageReference Save() {
return null;
}
public list<Lead> getdetail()
{
list<Lead> led=[select name,Company,Salutation from lead where Status='Open - Not Contacted' or status='Working - Contacted'];
return led;
}
}
Hi,
How you are calling in visualforce page.You will have to retrieve records using id
eg:
Id LeadId=ApexPages.CurrentPage().getParameters().get('id');
list<Lead> led=[select name,Company,Salutation from lead where id=:LeadId];
Try to refer this link
http://www.salesforce.com/us/developer/docs/pages/Content/apex_pages_pagereference.htm
I have created a variable there for showing all the leads
you need to add code to the save method to actually save something if that is what you want.
Or use a standard controller, which has a save method instead of a custom controller where you ahve to do all the coding....