473,395 Members | 1,458 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,395 software developers and data experts.

Passing through a var

I need to click on a button and pass through a variable with a number
associated to it to other form

That is. I know I can do something like this:
<FORM action="http://somesite.com/prog/adduser" method="post">
<INPUT type="submit" value="Send"> <INPUT type="reset">
</FORM>but.. can I do something like this?<FORM
action=http://somesite.com/prog/adduser?data=14 method="post">
<INPUT type="submit" value="Send"> <INPUT type="reset">
</FORM>
How do I do it?

Thanks,

Marcelo.
Jul 19 '05 #1
2 1158
Your alternative is perfectly possible.

<form action="mypage.asp?id=xyz">
</form>

Just note that you need to capture the id within Request.QueryString instead
of Request.Form collection.

--
Manohar Kamath
Editor, .netWire
www.dotnetwire.com
"Marcelo" <mb**********@ciudad.com.ar> wrote in message
news:eQ**************@TK2MSFTNGP15.phx.gbl...
I need to click on a button and pass through a variable with a number
associated to it to other form

That is. I know I can do something like this:
<FORM action="http://somesite.com/prog/adduser" method="post">
<INPUT type="submit" value="Send"> <INPUT type="reset">
</FORM>but.. can I do something like this?<FORM
action=http://somesite.com/prog/adduser?data=14 method="post">
<INPUT type="submit" value="Send"> <INPUT type="reset">
</FORM>
How do I do it?

Thanks,

Marcelo.

Jul 19 '05 #2
Another option is to have hidden fields within the form.

Marcelo wrote:
I need to click on a button and pass through a variable with a number
associated to it to other form

That is. I know I can do something like this:
<FORM action="http://somesite.com/prog/adduser" method="post">
<INPUT type="submit" value="Send"> <INPUT type="reset">
</FORM>but.. can I do something like this?<FORM
action=http://somesite.com/prog/adduser?data=14 method="post">
<INPUT type="submit" value="Send"> <INPUT type="reset">
</FORM>
How do I do it?

Thanks,

Marcelo.


Jul 19 '05 #3

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

Similar topics

15
by: Dave | last post by:
I'm currently working on a small project (admitedly for my CS class) that compares the time difference between passing by value and passing by reference. I'm passing an array of 50000 int's. ...
58
by: jr | last post by:
Sorry for this very dumb question, but I've clearly got a long way to go! Can someone please help me pass an array into a function. Here's a starting point. void TheMainFunc() { // Body of...
9
by: Just Me | last post by:
PARAFORMAT2 is a structure that SendMessage will return stuff in. Is the "ref" correct or since only a pointer is being passed should it be by value? Suppose I was passing data rather then...
8
by: Dennis Myrén | last post by:
I have these tiny classes, implementing an interface through which their method Render ( CosWriter writer ) ; is called. Given a specific context, there are potentially a lot of such objects,...
22
by: Arne | last post by:
How do I pass a dataset to a webservices? I need to submit a shoppingcart from a pocket PC to a webservice. What is the right datatype? II have tried dataset as a datatype, but I can't get it to...
6
by: MSDNAndi | last post by:
Hi, I get the following warning: "Possibly incorrect assignment to local 'oLockObject' which is the argument to a using or lock statement. The Dispose call or unlocking will happen on the...
12
by: Andrew Bullock | last post by:
Hi, I have two classes, A and B, B takes an A as an argument in its constructor: A a1 = new A(); B b = new B(a1);
12
by: Mike | last post by:
Consider the following code: """ struct person { char *name; int age; }; typedef struct person* StructType;
7
by: TS | last post by:
I was under the assumption that if you pass an object as a param to a method and inside that method this object is changed, the object will stay changed when returned from the method because the...
4
by: Deckarep | last post by:
Hello fellow C# programmers, This question is more about general practice and convention so here goes: I got into a discussion with a co-worker who insisted that as a general practice all...
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.