473,795 Members | 2,766 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problem Passing Data from VBS/Javascript

I'm working with a .hta file that uses javascript to produce 3checkboxes. If any checkbox is checked, a corresponding text boxappears. I'd like to be able to pass the data entered in thetext boxes to a single memo field in an Oracle db.

The functionality of the .hta is working, but I'm having troublefiguring out how to pass the text to the db. I need to have abutton "Return Values to HEAT" that will take the values enteredinto the text boxes and pass them via the sql statement in thecode below:

<HTML>

<HEAD>
<TITLE>Select Item to Change</TITLE>

<script language="javas cript">
<!--
function showDiv(objName ) {
obj = document.getEle mentById(objNam e);
obj.style.displ ay = (obj.style.disp lay == 'none') ? '' :'none'
}

-->
</script>

</HEAD>

<BODY scroll="no">

<P>

<form name="the_form" >
Select Item to Change:

<P>

<input type="checkbox" name="Name_chkb ox"onclick="sho wDiv('Name');"> Name
<input type="checkbox" name="Phone_chk box"onclick="sh owDiv('Phone'); ">Phone
<input type="checkbox" name="Address_c hkbox" value="0"onclic k="showDiv('Add ress');">Addres s

<P>

<div id="Name" style="display: none;">
Enter new name: <input type="text" name="Name_text " value=''>
</div>

<BR>

<div id="Phone" style="display: none;">
Enter new phone #: <input type="text" name="Phone_tex t"value=''>
</div>

<BR>

<div id="Address" style="display: none;">
Enter new address: <input type="text" name="Address_t ext"value=''>
</div>

<BR>

<P>
<script type="text/vbscript">

strLocalHEAT = "DSN=LocalHEAT; "
Set oArgs = WScript.Argumen ts

set cnn = createobject("A DODB.Connection ")
set cmd = createobject("A DODB.Command")
set rst = createobject("A DODB.Recordset" )

SqlStatement = "UPDATE CallLog SET CallDesc = '" & Phone & "'WHERE CallID = '01624117'"

cnn.Open strLocalHEAT
cnn.execute SqlStatement

cnn.close
set cnn = nothing

</script>

<P>

<INPUT TYPE="button" name="ReturnHea t" value="Return Values toHEAT">
<INPUT TYPE="button" name="Cancel" value="Cancel"o nClick=window.c lose()>

</FORM>

</BODY>

</HTML>

User submitted from AEWNET (http://www.aewnet.com/)
Nov 19 '05 #1
0 1057

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
4345
by: Raju V.K | last post by:
can I use javascript and PHP in the following manner to create a pop-up window: <--- in <head> </head> <script language=javascript> function popup(folder1, file1) { window1=open("solution.php?folder=folder1&file=file1"); }
2
10863
by: Gung Ho | last post by:
I am using ASP to open a text file on the server and I want to pass variables to Javascript. Any suggestions? For example - I have a text file on the server defining a set of pictures. I open the text file to retrieve the list of files. I want to pass the list of files to the Javascript which will then display the data on the client machine.
12
6559
by: Kevin Lyons | last post by:
Hello, I am trying to get my select options (courses) passed correctly from the following URL: http://www.dslextreme.com/users/kevinlyons/selectBoxes.html I am having difficulty getting the courses to pass the correct option value and then be displayed at the following URL: http://www.dslextreme.com/users/kevinlyons/selectResults.html I am passing countries, products, and courses. The first two display
1
4616
by: Kevin Lyons | last post by:
Hello, I am trying to get all of my form elements passed correctly from the following URL: http://www.dslextreme.com/users/kevinlyons/selectBoxes.html to the following URL: http://www.dslextreme.com/users/kevinlyons/selectResults.html I am passing name, email, countries, cities, products, courses, etc. The others display as they should on the subsequent page,
6
2728
by: Shaun Fleming | last post by:
I've been trying to make this simple script compatible across various browsers. It works for IE 6.0 and NS 7 but doesnt work with Opera (I have version 7.11). This is what is supposed to happen: when the user clicks a button in the main window, a dialog window pops up. In the dialog the user enters a university to search for. When the string is submitted, the dialog then shows all the matches found in the database. The user picks one and...
6
1862
by: KKramsch | last post by:
OK, here's the scenario: I have a CGI script that generates a page with frames (BTW, I'm not crazy about frames, but in this case the decision to use them is out of my hands). In a typical session, the user interacts with two of these frames extensively, and up to the very end of the session, this interaction is handled entirely client-side by a fairly elaborate JavaScript script. (This interaction takes place exclusively via HTML...
6
5582
by: ged | last post by:
Hi, i am a oo (c#) programmer, and have not used javascript for a while and i cant work out how javascript manages its references. Object References work for simple stuff, but once i have an object collection and stanrd using it it starts to fall apart. Clearly there is something about javascript's usage of passing "By ref" that i am not getting. i have had a look on the web and found some examples, but i cant see why my code does not...
5
2425
by: Steve | last post by:
Hi, I currently have a problem passing a variable value from one page to another. Once a form submit button is pressed java pops up a window and displays some information. The problem being is variables value needs to be passed from the main page to this popup window ... but it isn't. why? the submit button one the PHP page is
4
4165
by: moondaddy | last post by:
I have a htm page where I need to pass some data to an aspx page as a means of sending data to the database. I don't need to see the aspx page so I was going to put it in a hidden iframe. This works real good. Since I don't need the aspx page to do any postback, is there a way to pass a parameter to it with out it finishing the round trip back to the htm page? Thanks. -- moondaddy@newsgroup.nospam
3
3930
by: willyWEB66 | last post by:
Hi everyone, I'm having problem with the sequence of execution for xml.onload. It works fine if your not passing parameters to onload event but my code needs to pass parameter to its function. I'm able to research ablut passing parameters for onload event. However my problem is it only executes on the last instance of loading the XML. I'm sure ur all pretty confused. I'll show some of the javascript code: <script...
0
9672
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10436
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10213
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10163
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7538
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6780
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5436
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
3722
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2920
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.