Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


How to make a sub only process if a check is marked?

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,62622
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> How to make a sub only process if a check is marked?
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 How to make a sub only process if a check is marked? - 7/23/2008 2:40:35 AM   
  Stumpedtechy

 

Posts: 41
Score: 0
Joined: 11/30/2007
Status: offline
Okay I have this -

[Delete]    [] Are you sure?

Basically this is a button and then a check box.

I want to ensure this does NOT run unless the "Are you sure?" is checked E.G.

<input id=deletebutton class="button" type="button" value="Delete"  name="delete_button"  onClick="Delete"><input type="checkbox" name="Sure"> Are you sure?

This all looks good but when I click on it it still will go to my script portion that is Sub Delete how do I get it so this sub will NOT run if the box is not checked?
 
 
Post #: 1
 
 RE: How to make a sub only process if a check is marked? - 7/23/2008 4:13:41 AM   
  dm_4ever


Posts: 2664
Score: 46
Joined: 6/29/2006
From: Orange County, California
Status: offline
try


      

Refrence:  http://www.w3schools.com/htmldom/prop_checkbox_checked.asp

_____________________________

dm_4ever

My philosophy: K.I.S.S - Keep It Simple Stupid
Read Me: http://www.visualbasicscript.com/m_24727/tm.htm
Frequently Asked Stuff: http://www.visualbasicscript.com/m_47117/tm.htm

(in reply to Stumpedtechy)
 
 
Post #: 2
 
 RE: How to make a sub only process if a check is marked? - 7/23/2008 10:21:03 AM   
  Stumpedtechy

 

Posts: 41
Score: 0
Joined: 11/30/2007
Status: offline
Ahhhh thank you. I knew it had to be simpleish. I am still trying to get a hang of the elements and HTML stuff cause I have been VBScripting but believe it or not I have never even made a web page before. Thank you for your help in this.

(in reply to dm_4ever)
 
 
Post #: 3
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> How to make a sub only process if a check is marked? Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts