| Forum Home | ||||
| Press F1 | ||||
| Thread ID: 8833 | 2001-04-20 03:12:00 | To all you VBSCRIPT guru's | Guest (0) | Press F1 |
| Post ID | Timestamp | Content | User | ||
| 11599 | 2001-04-20 03:12:00 | I have just started learning vbscript and am trying to do a simple password form. Could you please tell me why this code does not work. Also, im wanting to open a new html (or .asp) page if the password is correct (instead of the message box). How is this done? Thanks <head> <title>Password</title> <script language = 'VBscript'> <!--- sub Submit_OnClick Dim Form Set Form = Document.Validation if Form.Password.Text = 'test' then Msgbox 'Welcome' else Msgbox 'Wrong' end if End Sub ----> </script> </head> <body> <Form Name = 'Validation'> <center> Please enter your password here <Input Name = 'Password' Type = 'Text' Size = '30'> <input type = 'Submit' Value = 'Submit'> </Center> </body> </html> |
Guest (0) | ||
| 11600 | 2001-04-20 05:38:00 | Seems the browser decided to run this program, so here is the code again. Sorry 'bout that! <!-- <html> <head> <title>Password</title> <script language = 'VBscript'> <!--- sub Submit_OnClick Dim Form Set Form = Document.Validation if Form.Password.Text = 'test' then Msgbox 'Welcome' else Msgbox 'Wrong' end if End Sub ----> </script> <!-- </head> <body> <Form Name = 'Validation'> <center> Please enter your password here <Input Name = 'Password' Type = 'Text' Size = '30'> <input type = 'Submit' Value = 'Submit'> </Center> </body> </html> --> |
Guest (0) | ||
| 1 | |||||