|
-
Aug 28th, 2001, 09:27 AM
#1
Thread Starter
Lively Member
Date Format URGENT!
Here is my code:
Sub Window_Onload
on error resume next
Form1.DateBox.value = empty
window.settimeout "Init", 5, vbscript
Form1.DateBox.value = cstr(form1.Dtpicker1.month) & "/" & cstr(form1.dtpicker1.day) & "/" & cstr(form1.dtpicker1.year)
end sub
sub Init
form1.dtpicker1.value = now
end sub
**********************************************
When the page loads up I want to have the value of Datebox = the date appearing on dtpicker1. When the page loads up the following is in the DateBox; 0/0/1
I know that this is because I set the values to a string but how can I get the value on the dtpciker1?
If i go sub Dtpicker1_change
for1.datebox.value = cstr.....
end sub
the value in the box is in a date format
-
Aug 30th, 2001, 12:49 AM
#2
Frenzied Member
Set the values for each component. Set the day to 1 then set the month then the day to what it should be, then the year. If you have the day set to say 30 and you change the month to February, it will throw an error so set it to 1 to be safe.
oOOo--oOOo
__ /\/\onte96
oOOo--oOOo
Senior Programmer/Analyst
MCP
[email protected]
[email protected]
Your results may vary.. some restrictions may apply.. pricing and participation may vary.. not available in all states.. professional driver closed course..quantities limited..
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|