473,386 Members | 1,846 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Send value from a asp.net page to a regular asp page..

I am collecting a value in a textbox on an asp.net page and need to open an
asp page and pass the variable containing the value or just the value to
that asp page so I can use it in the vbscript as an arguement
be gentle.. I'm new to this..
PS. I have not been able to convert the ASP page to ASP.net, but that's for
a different post.
Nov 19 '05 #1
7 1522
might be a silly quation, why cant you just use an html page and pass it via
a typical form post of get?

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director

"msnews" <ma*@mas.com> wrote in message
news:e3*************@TK2MSFTNGP10.phx.gbl...
I am collecting a value in a textbox on an asp.net page and need to open an
asp page and pass the variable containing the value or just the value to
that asp page so I can use it in the vbscript as an arguement
be gentle.. I'm new to this..
PS. I have not been able to convert the ASP page to ASP.net, but that's
for
a different post.

Nov 19 '05 #2
The asp.net page will have a few controls on it.. most I think are unique to
..net.

I'm looking at response.redirect, but I don't understand how you select
which value to send..

"John Timney (ASP.NET MVP)" <ti*****@despammed.com> wrote in message
news:e2****************@TK2MSFTNGP10.phx.gbl...
might be a silly quation, why cant you just use an html page and pass it via a typical form post of get?

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director

"msnews" <ma*@mas.com> wrote in message
news:e3*************@TK2MSFTNGP10.phx.gbl...
I am collecting a value in a textbox on an asp.net page and need to open an asp page and pass the variable containing the value or just the value to
that asp page so I can use it in the vbscript as an arguement
be gentle.. I'm new to this..
PS. I have not been able to convert the ASP page to ASP.net, but that's
for
a different post.


Nov 19 '05 #3
One possible solution could be to send it in query string. Something
like this

Response.Redirect("Yourpage.asp?YourVariable=YourV alue");

Or you could add a hidden variable in the asp.net page and then set its
value before opening up the asp page.

Nov 19 '05 #4
I assume that code would go in the asp.net page.

Can you give an example of how I was then "read" that value in the ASP page
so I can use it. It looks exactly like what I need..
<ar**********@gmail.com> wrote in message
news:11**********************@g14g2000cwa.googlegr oups.com...
One possible solution could be to send it in query string. Something
like this

Response.Redirect("Yourpage.asp?YourVariable=YourV alue");

Or you could add a hidden variable in the asp.net page and then set its
value before opening up the asp page.

Nov 19 '05 #5
yeah.. the above code would go in the asp.net code behind file.

In the asp page, you could retrieve it like this
myvalue = Request.QueryString("YourVariable")

Nov 19 '05 #6
It looks so easy but I am getting nowhere.. here is some code

from the asp.net page

'machinename is the vaue I want to pass..
machinename = TextBox1.Text

Response.Redirect("machrest.asp?machinename=" & machinename)

In the asp page

machinename = Request.QueryString("machinename")

Sub FillInCollections
dim CompName,oWshShell
set oWshShell = CreateObject("WScript.Shell")
path = "\\" & "wchsms13" & "\remote$\remote.exe"
oWshShell.run path & " 2 " & machinename

end Sub

I don't see the parameter in the URL when the ASP page opens..

it should launch a commandline that looks like this

\\wchsms13\remote$\remote.exe 2 machinename

<ar**********@gmail.com> wrote in message
news:11**********************@o13g2000cwo.googlegr oups.com...
yeah.. the above code would go in the asp.net code behind file.

In the asp page, you could retrieve it like this
myvalue = Request.QueryString("YourVariable")

Nov 19 '05 #7
Am sorry am not of much help beyond this. Here is some actual code that
i wrote and tested. It worked fine for me.

In webform1.aspx.cs

string s = "myvalue";
Response.Redirect( "WebForm2.aspx?myvariable=" + s );

In webform2.aspx.cs

Response.Write( Request.QueryString["myvariable"] );

( I've used aspx as my target, i dont think this makes any difference ).

Nov 19 '05 #8

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

Similar topics

3
by: Erik T. Nomad | last post by:
I've created a link that will enable the reader of any page on my website to click it, enter an e-mail address, and have it arrive in that inbox with a hyperlink to the site. However, I'm...
5
by: RICHARD BROMBERG | last post by:
I am already using ASP/Cdonts to send the contents of a Form by e-mail and would like to include a link on my page to send the page itself by e-mail to a named recipient. Can anyone start me in...
4
by: tp | last post by:
HI... I have created simple .asp page and i would like to send my page as email using my outlook . is it possible to send form body as new email outlook body using mailto command or any other...
3
by: Kassam | last post by:
Hi MVPs out there. I have constructed an order form and the users will enter the informtion. I now need to send the filled out form as an e-mail (body being the HTML with the fille din data) to...
4
by: Mark J. McGinty | last post by:
Greets, Part of the content of one of our web pages uses wingdings and Chr(239) through Chr(242) (which are little arrow outlines, though that's not really important.) It worked just fine in...
1
by: khawar | last post by:
the following code seams to be sending a silent post. how can we not make it send a silent post but regular post where along with the post the control should also be transferred over to the other...
7
by: moondaddy | last post by:
I have a user control being used instead of a frame page. when the user clicks on a menu item I need to send the ID (integer value) of that menu as a parameter in the postback of the user control...
9
by: eswanson | last post by:
I have a web page I need to post a file plus some other fields to it. How can I do this from a asp.net page. I know I can send individual fields to the other page, but how do I send a file to the...
5
by: Analysis&Solutions | last post by:
Hi: I'm using the following Visual Basic code to open a report and set the value of an unbound text box in its page header. It works... but only on pages other than the first one. ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
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,...

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.