Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > JavaScript and VBScript

Reply
Thread Tools

JavaScript and VBScript

 
 
JWM
Guest
Posts: n/a
 
      05-24-2004
Hello: Here is what I am trying to do......

The user clicks on the delete icon, and gets a JavaScript client-side popup
to confirm that he wants to delete. I am passing this client-side function
a contactID.
Then, I want to send the result of this confirm (true|false) to a
server-side VBScript function, along with the contactID.
The VBScript function will then perform a delete in the database for the
specified contactID.

I have seen many examples about sending stuff back and forth between
JavaScript and VBScript, between server and client, but all the examples I
see are just popping up generic alerts and such. I need to execute some JS
on the client side, return a value, and send it to a VBScript function on
the server side.

Someone please help me.

Joe
http://www.velocityreviews.com/forums/(E-Mail Removed)




 
Reply With Quote
 
 
 
 
Randy Webb
Guest
Posts: n/a
 
      05-24-2004
JWM wrote:
> Hello: Here is what I am trying to do......
>
> The user clicks on the delete icon, and gets a JavaScript client-side popup
> to confirm that he wants to delete. I am passing this client-side function
> a contactID.
> Then, I want to send the result of this confirm (true|false) to a
> server-side VBScript function, along with the contactID.
> The VBScript function will then perform a delete in the database for the
> specified contactID.


Why do you want to call the server side script if the user doesn't want
to delete? Seems the only time you want to send the data is when they
want to delete.


> I have seen many examples about sending stuff back and forth between
> JavaScript and VBScript, between server and client, but all the examples I
> see are just popping up generic alerts and such. I need to execute some JS
> on the client side, return a value, and send it to a VBScript function on
> the server side.
>
> Someone please help me.


The solution will depend on the answer to one more question:

What do you want to happen *after* the user says "Yes, I want to
delete". Do you want the page to refresh? I would assume so. <form
onsubnmit="return confirm('Are you sure you want to delete that record?"
action="myFile.asp"> And have the button be a submit button, and let it
submit the form. myFile.asp would pick up the form values, and then act
on it.

If you don't want the page to refresh/update, you could simply change
the source of an image and have the myFile.asp called on the server, as
the img src.


--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
 
Reply With Quote
 
 
 
 
Randy Webb
Guest
Posts: n/a
 
      05-24-2004
Randy Webb wrote:

> What do you want to happen *after* the user says "Yes, I want to
> delete". Do you want the page to refresh? I would assume so. <form
> onsubnmit="return confirm('Are you sure you want to delete that record?"
> action="myFile.asp">


That should be:

onsubmit="return confirm('Are you sure you want to delete that record?')"




--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
 
Reply With Quote
 
TedJM
Guest
Posts: n/a
 
      06-08-2004
Randy Webb <(E-Mail Removed)> wrote in message news:<(E-Mail Removed)>...
> JWM wrote:
> > Hello: Here is what I am trying to do......
> >
> > The user clicks on the delete icon, and gets a JavaScript client-side popup
> > to confirm that he wants to delete. I am passing this client-side function
> > a contactID.
> > Then, I want to send the result of this confirm (true|false) to a
> > server-side VBScript function, along with the contactID.
> > The VBScript function will then perform a delete in the database for the
> > specified contactID.

>
> Why do you want to call the server side script if the user doesn't want
> to delete? Seems the only time you want to send the data is when they
> want to delete.
>
>
> > I have seen many examples about sending stuff back and forth between
> > JavaScript and VBScript, between server and client, but all the examples I
> > see are just popping up generic alerts and such. I need to execute some JS
> > on the client side, return a value, and send it to a VBScript function on
> > the server side.
> >
> > Someone please help me.

>
> The solution will depend on the answer to one more question:
>
> What do you want to happen *after* the user says "Yes, I want to
> delete". Do you want the page to refresh? I would assume so. <form
> onsubnmit="return confirm('Are you sure you want to delete that record?"
> action="myFile.asp"> And have the button be a submit button, and let it
> submit the form. myFile.asp would pick up the form values, and then act
> on it.
>
> If you don't want the page to refresh/update, you could simply change
> the source of an image and have the myFile.asp called on the server, as
> the img src.


what do you know about those two? stop pretending you know something.
useless reply.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ASPX, VBScript, JavaScript, Double-Underscored Variables and setTimeOut Shadow Lynx ASP .Net 10 08-09-2006 07:40 PM
Making the same button do client side javascript and server side vbscript? COHENMARVIN ASP .Net 2 10-20-2005 01:13 AM
javascript and vbscript in the same page William F. Robertson, Jr. ASP .Net 3 12-07-2004 07:17 PM
mixing Javascript and VBScript in ASP.NET? Jamie ASP .Net 1 12-05-2003 11:54 PM
Javascript and VBScript Martin HTML 17 12-04-2003 08:08 PM



Advertisments