+ Start a Discussion
kumar7kumar7 

Visula force page

Hi All

 

my requirement is i have visual force page in that page i created the cusom buttons like Account, Contact etc

 

 

Functionlaity :  if i click on Account button it needs to redirect to Account home page

 

 

can any one help on this

 

Thanks

in advance

 

 

sampath

Devendra@SFDCDevendra@SFDC

 

 

Are you looking to open Account form to create new account record after clicking on "Account" button?

 

Thanks,

Devendra

PrabhaPrabha

Account home URL: https://ap1.salesforce.com/001/o

 

include this in ur page

<button type="button" onclick="parent.location='https://ap1.salesforce.com/001/o'">Account</button>

 HTH

Prabhan

kumar7kumar7

Hi Prabhan, 

 

 

                      you given solution is working fine, But I want to create a

 

                     <apex:commandButton value="Account"/>

 

 

                     using this apex button i kneed the solution Please Help me

 

 

Thanks

sampath

 

 

PrabhaPrabha

You could try with onclick attr on command button.

 

this is what it is...

<apex:page >
<apex:form >
<apex:commandButton value="Account" title="Account Home" onclick="parent.location='https://ap1.salesforce.com/001/o'"/>
<button type="button" onclick="parent.location='https://ap1.salesforce.com/001/o'">html Account</button>
</apex:form>

</apex:page>

 HTH

Prabhan

Devendra@SFDCDevendra@SFDC

Hi,

 

You can use the Global variables for this.

 

Please check the first example from below link:

 

http://www.salesforce.com/us/developer/docs/pages/Content/pages_variables_global.htm

 

Hope this helps :)

 

Thanks,

Devendra