473,473 Members | 2,207 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Writing to Database

Hi Guys,

I am still searching for an answer to this question. Can you help me?

If I have a field on a .aspx form, the classic Textbox1. How do I send the
Textbox1.Text to an .Asp page and assign it to say rs("Name") variable.
Because I have used Request.Redirect("writetodb.asp") in my button click
event, I thought I could use
rs("Name") = request.form("Textbox1") but this does not work.

I am using this method because I am trying to create a new .net input form
based on an old .asp form and then calling the original .asp page to write
to the database. If I could just convert the .net form variables to the
variables I used in my original .Asp page all would be ok.

Any ideas would be greatly appreciated.

Best Regards,

Steve Wilson.
Jul 19 '05 #1
3 2148
Hi Gav,
Thanks for the response.
Is there no way to reference the request form variables like classic asp?

Best regards,

Steve Wilson.

"Gav" <sp**@spam.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Once you have 'redirected' to another page Textbox1 will no longer exist you have to put it in the url and put it in rs('') in the ASP page... ie
aspx
Request.Redirect("writetodb.asp?Name=" + Textbox1.Text)
asp
rs("Name")= Request.Param("Name");

"Always Learning" <st**********@lineone.net> wrote in message
news:OK**************@tk2msftngp13.phx.gbl...
Hi Guys,

I am still searching for an answer to this question. Can you help me?

If I have a field on a .aspx form, the classic Textbox1. How do I send the Textbox1.Text to an .Asp page and assign it to say rs("Name") variable.
Because I have used Request.Redirect("writetodb.asp") in my button click
event, I thought I could use
rs("Name") = request.form("Textbox1") but this does not work.

I am using this method because I am trying to create a new .net input form based on an old .asp form and then calling the original .asp page to write to the database. If I could just convert the .net form variables to the
variables I used in my original .Asp page all would be ok.

Any ideas would be greatly appreciated.

Best Regards,

Steve Wilson.


Jul 19 '05 #2
Gav
I'm not sure about that, sorry. I've not done it from aspx to asp but I have
from aspx to aspx and the only ways I know to do it is, to either put it in
the URL as said before... or to use session variables.

Sorry I can't help you more.

Gav

"Always Learning" <st**********@lineone.net> wrote in message
news:%2***************@tk2msftngp13.phx.gbl...
Hi Gav,
Thanks for the response.
Is there no way to reference the request form variables like classic asp?

Best regards,

Steve Wilson.

"Gav" <sp**@spam.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Once you have 'redirected' to another page Textbox1 will no longer exist

you
have to put it in the url and put it in rs('') in the ASP page... ie
aspx
Request.Redirect("writetodb.asp?Name=" + Textbox1.Text)
asp
rs("Name")= Request.Param("Name");

"Always Learning" <st**********@lineone.net> wrote in message
news:OK**************@tk2msftngp13.phx.gbl...
Hi Guys,

I am still searching for an answer to this question. Can you help me?

If I have a field on a .aspx form, the classic Textbox1. How do I send the Textbox1.Text to an .Asp page and assign it to say rs("Name") variable. Because I have used Request.Redirect("writetodb.asp") in my button click event, I thought I could use
rs("Name") = request.form("Textbox1") but this does not work.

I am using this method because I am trying to create a new .net input form based on an old .asp form and then calling the original .asp page to write to the database. If I could just convert the .net form variables to the variables I used in my original .Asp page all would be ok.

Any ideas would be greatly appreciated.

Best Regards,

Steve Wilson.



Jul 19 '05 #3
Gav
Steve,

you can not use the session variable in the asp page... what is wrong with
putting it in the url of the page?

The only way I can see you achieving what you want is by either sending the
variables in the url like I mentioned before or better yet why don't you
write a new web service to go with your new web application and get that to
write the variables to the database. It is easy enough to do.

Gavin

"Always Learning" <st**********@lineone.net> wrote in message
news:eQ******************@TK2MSFTNGP10.phx.gbl...
Hi Gav,

I have tried using
Session("Name") = Textbox1.Text
Session("Telephone") = TextBox2.Text
in the .aspx page but how do I reference them in the .asp page. I am having trouble with this.

Thanks for your help.

Steve Wilson.

"Gav" <sp**@spam.com> wrote in message
news:eq**************@tk2msftngp13.phx.gbl...
I'm not sure about that, sorry. I've not done it from aspx to asp but I

have
from aspx to aspx and the only ways I know to do it is, to either put it

in
the URL as said before... or to use session variables.

Sorry I can't help you more.

Gav

"Always Learning" <st**********@lineone.net> wrote in message
news:%2***************@tk2msftngp13.phx.gbl...
Hi Gav,
Thanks for the response.
Is there no way to reference the request form variables like classic asp?
Best regards,

Steve Wilson.

"Gav" <sp**@spam.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
> Once you have 'redirected' to another page Textbox1 will no longer exist you
> have to put it in the url and put it in rs('') in the ASP page... ie > aspx
> Request.Redirect("writetodb.asp?Name=" + Textbox1.Text)
> asp
> rs("Name")= Request.Param("Name");
>
>
>
> "Always Learning" <st**********@lineone.net> wrote in message
> news:OK**************@tk2msftngp13.phx.gbl...
> > Hi Guys,
> >
> > I am still searching for an answer to this question. Can you help me? > >
> > If I have a field on a .aspx form, the classic Textbox1. How do I send the
> > Textbox1.Text to an .Asp page and assign it to say rs("Name")

variable.
> > Because I have used Request.Redirect("writetodb.asp") in my button

click
> > event, I thought I could use
> > rs("Name") = request.form("Textbox1") but this does not work.
> >
> > I am using this method because I am trying to create a new .net input form
> > based on an old .asp form and then calling the original .asp page to write
> > to the database. If I could just convert the .net form variables
to the
> > variables I used in my original .Asp page all would be ok.
> >
> > Any ideas would be greatly appreciated.
> >
> > Best Regards,
> >
> > Steve Wilson.
> >
> >
>
>



Jul 19 '05 #4

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

Similar topics

1
by: Google Mike | last post by:
Tell me if this can be done, and if I have a misconception here. I am writing an app that will be served up in an app farm, and therefore I need to move the session information to the client, not...
4
by: George Stout | last post by:
First off I do not know alot about writing queries to an Access Database from an ASP page. This is why I need help. I have an Events database for 6 colleges in our metro area. On the homepage I...
0
by: sedefo | last post by:
I ran into this Microsoft Patterns & Practices Enterprise Library while i was researching how i can write a database independent data access layer. In my company we already use Data Access...
13
by: Jeff Pritchard | last post by:
I have an MDB that contains a single table. Checkweigher data is being continuously written to this MDB from a dedicated workstation over a network into the MDB on the server at the rate of about...
3
by: Marius Rus | last post by:
I have a project in C# that do the followings: From an csv text file it is taking datas and inserted into an paradox database. My problem it is that when writing into the paradox database it is...
12
by: Chris Springer | last post by:
I'd like to get some feedback on the issue of storing data out to disk and where to store it. I've never been in a production environment in programming so you'll have to bear with me... My...
7
by: John Pote | last post by:
Hello, help/advice appreciated. Background: I am writing some web scripts in python to receive small amounts of data from remote sensors and store the data in a file. 50 to 100 bytes every 5 or...
2
by: bazzer | last post by:
can anyone tell me please how i write to an access database from a webform? i can fill listboxes and textboxes and so forth with data from my tables in my database no problem. but i dont have a...
20
by: Vincent Delporte | last post by:
Hello I'm about to write a prototype for a business application, but since this my first real web application, I'm looking for a good book or article that sums up the different issues web...
30
by: Cramer | last post by:
I've finally gotton board with TDD (test driven development) and wow is it effective! I went from sceptic to True Believer with my first effort. My question: According to the various books and...
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
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...
1
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...
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
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...
0
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...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.