+ Start a Discussion
Nikhil_KhetanNikhil_Khetan 

Inline VisualForce in Salesforce1 Object Detail page

Hi Guys,

I am facing a starnge behaviour of inline VisaulForce on my deatil page of contact in Salesforce1.
I have 3 buttons on my visualforce(Nothing else on page), now i have added this visualforce on my contact page layout. This works fine when i run this on web browsers, but when i see it on my mobile device the page looks good but when i click on button the complete visaulforce page gets open again with only this 3 buttons on page and then i can click on those button which redirects me to some othe page.

Is it possible to make those button clickable same at inline visualforce itself(instead of opening same page again).

Below is code of the Page:
<apex:page docType="html-5.0" standardController="Contact" showHeader="false" sidebar="false" standardStylesheets="false">
<script>
function test1(){
    if ( (typeof window.sforce != 'undefined') && (window.sforce!=null) ) {
      sforce.one.navigateToURL('/apex/XXXXX?ConId={!Contact.Id}&retURL=/{!Contact.Id}');
    }
    else {
      alert('Not in SF1 :(');
    }
}
function test2(){

}
function test3(){

}   
</script>
                <apex:form >
                    <apex:commandButton styleClass="sf1button" value="Add" onclick="test1()" />
                    <apex:commandButton styleClass="sf1button" value="New" onclick="test2()"/>
                    <apex:commandButton styleClass="sf1button" onclick="test3()" value="View"/>
                </apex:form>
</apex:page>
Best Answer chosen by Nikhil_Khetan
Nikhil_KhetanNikhil_Khetan
Thats sad to hear. So salesforce Inline visualforce in SF1 can be used only when it is readonly :-(

All Answers

KaranrajKaranraj
Hi NikhilKhetan - I believe its a standard behaviour in salesforce1 app for inline VF page and Mobile cards. Even the sample page in the salesforce1 developer guide also has the same behaviour. I'm also faced same problem, i have tried many ways to overcome that, but still not.
Nikhil_KhetanNikhil_Khetan
Thats sad to hear. So salesforce Inline visualforce in SF1 can be used only when it is readonly :-(
This was selected as the best answer
GGJ5GGJ5
I have same issue.  Did you find a solution?