You need to sign in to do that
Don't have an account?

How to avoid datepicker pop up on load of the visualforce page
Hi,
I am using custom field of type date in my visualforce page as inputfield. the code is like this
<apex:pageBlockSection title="Choose Date Range to generate Reports">
<apex:inputField id="fromdate" value="{!fromDateTask.From_Date__c}" id="fromdate"/><br/>
<apex:inputField id="todate" value="{!toDateTask.To_Date__c}" id="todate"/><br/>
</apex:pageBlockSection>.
<apex:inputField id="fromdate" value="{!fromDateTask.From_Date__c}" id="fromdate"/><br/>
<apex:inputField id="todate" value="{!toDateTask.To_Date__c}" id="todate"/><br/>
</apex:pageBlockSection>.
when ever the page is getting loaded the datepicker pop's up from the "fromdate" inputfield. The datepicker should popup only when we click on it. How to avoid the popup onload event.
Thanks,
Joseph
if not, you can override the default behavior that places the focus on this (date) input field.
try something like this
Ron,
Is this still not available?
Just Set the focus on another field , like this:
<input id="hiddenElementId" type="hidden" />
<script type="text/javascript">
window.onload = setFocus
function setFocus()
{
document.getElementById("hiddenElementId").focus();
}
</script>
<script type="text/javascript">
function setFocus() { }
</script>