• ANordman
  • NEWBIE
  • 0 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 5
    Replies

I have created a visualforce page that is linked to a custom object.  When I save the record on that page and get redirected to the record on a SF page the development bar does not go away.  It appears that the URL does not change even though I have moved away from my page.  I cannot use any of the buttons on the SF page either except for one that links back to my visualforce page.  Any Ideas?  I am using retURL on my button to take me back to the record but the {!Save} action should redirect me I thought.

I am having a really hard time trying to get this really simple bit of Javascript to work on this visualforce page.  All I want to do is update a text box or outputText field with Todays date.  It is being called onclick in a button.

 

Code:

<script type="text/javascript">
        
        sforce.connection.sessionId = "{!$Api.Session_ID}";
       
        function UpdateClockIn(textid){
            alert("I am here");
            var DateNow=New Date();
            document.getElementById(textid).value=DateNow;
        };
    </script>

 

Called:

<button onclick="UpdateClockIn('{!$Component.Testing}');">Clock In</button>

 

The alert isn't even appearing on my screen which makes me believe the Javascript isn't running at all.  Am I missing something?

I have a visualforce page which have inputarea which is editable for profiles who donot have field level permission not to edit it. In the object it cannot be edited by that profile but it can still be edited in the visualforce page

 

I have with sharing clause in the attached controller. What can be the possible solution ?

  • April 04, 2012
  • Like
  • 0

I have created a visualforce page that is linked to a custom object.  When I save the record on that page and get redirected to the record on a SF page the development bar does not go away.  It appears that the URL does not change even though I have moved away from my page.  I cannot use any of the buttons on the SF page either except for one that links back to my visualforce page.  Any Ideas?  I am using retURL on my button to take me back to the record but the {!Save} action should redirect me I thought.

I am having a really hard time trying to get this really simple bit of Javascript to work on this visualforce page.  All I want to do is update a text box or outputText field with Todays date.  It is being called onclick in a button.

 

Code:

<script type="text/javascript">
        
        sforce.connection.sessionId = "{!$Api.Session_ID}";
       
        function UpdateClockIn(textid){
            alert("I am here");
            var DateNow=New Date();
            document.getElementById(textid).value=DateNow;
        };
    </script>

 

Called:

<button onclick="UpdateClockIn('{!$Component.Testing}');">Clock In</button>

 

The alert isn't even appearing on my screen which makes me believe the Javascript isn't running at all.  Am I missing something?