D
davidgordon
Hi,
I have some pages with this VBScript code, which obviously does not
work in Firefox. How can I convert this to Javascript in order for my
web page to work in Firefox ? It basically fills a drop down with a
list of dates that a user can select.
Appreciate any help you can offer
----------------------
<SCRIPT language='vbscript'>
Sub Window_Onload
Dim TheDate
Dim Count
Dim Options
TheDate = Date + vbFriday - WeekDay(Date)
If TheDate < Date Then TheDate = TheDate + 7
Set Options = Document.All.Date.Options
For Count = 1 To 40
StrDate = "Friday " & Right("0" & Day(TheDate),2) & "/" &
Right("0" &_
Month(TheDate),2) & "/" & Year(TheDate)
Options.Add Window.Option(StrDate,"for " & StrDate)
TheDate = TheDate + 7
Next
End Sub
</script>
-----------------------
Thanks
David
I have some pages with this VBScript code, which obviously does not
work in Firefox. How can I convert this to Javascript in order for my
web page to work in Firefox ? It basically fills a drop down with a
list of dates that a user can select.
Appreciate any help you can offer
----------------------
<SCRIPT language='vbscript'>
Sub Window_Onload
Dim TheDate
Dim Count
Dim Options
TheDate = Date + vbFriday - WeekDay(Date)
If TheDate < Date Then TheDate = TheDate + 7
Set Options = Document.All.Date.Options
For Count = 1 To 40
StrDate = "Friday " & Right("0" & Day(TheDate),2) & "/" &
Right("0" &_
Month(TheDate),2) & "/" & Year(TheDate)
Options.Add Window.Option(StrDate,"for " & StrDate)
TheDate = TheDate + 7
Next
End Sub
</script>
-----------------------
Thanks
David