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

ASP.NET 1.1: How to dynamically create data entry form?

I am converting an old ASP data entry form to ASP.NET 1.1. The old form has
a script block that dynamically adds rows to a table that contain cells with
a textbox for quantity, product description, price, and total (which is
calculated after the form is submitted). The number of rows depends on how
many records were retrieved from a query.

<%
dim i: i = 0
with rs
do while .eof = false
i = i +1
response.write "<tr><td><input type=""text"" id=""" & "lineQty" &
cstr(i) & """ value=""" & cstr(order_array(i , 1)) & """></td><td id=""" &
"prodDesc_" & cstr(rs("prod_id")) & """>" & rs("prod_desc") & "</td><td
id=""" & "unitCost" & cstr(i)& """>" & cstr(rs("prod_unit_cost")) &
"</td><td id=""" & "lineTotal" & cstr(i) & """>" & cstr(order_array(i, 3)) &
"</td></tr>"
.movenext
loop
end with
%>

When the form is submitted, an array that contains the quantities, prices,
and totals are calculated from the values entered in the form. Piece of
cake in classic ASP. How on Earth do I do the same kind of thing in ASP.NET
1.1?

Can someone please point me to a *complete* example of the code to do this
(preferably in VB)? All I have come across in the newsgroups are vague,
philosophical discussions or partial snippets that don't explain it clearly
enough (or just don't work). I confess, I haven't gotten past the 30th page
or so in Google, but I need to figure this out in very short order now.

Thanks!

Gino
Oct 5 '06 #1
1 1910
http://msconline.maconstate.edu/tutorials/default.aspx
"Gino Perruti" <no*****@omgwtf.bbqwrote in message news:%2***************@TK2MSFTNGP06.phx.gbl...
>I am converting an old ASP data entry form to ASP.NET 1.1. The old form has a script block that dynamically adds rows to a table
that contain cells with a textbox for quantity, product description, price, and total (which is calculated after the form is
submitted). The number of rows depends on how many records were retrieved from a query.

<%
dim i: i = 0
with rs
do while .eof = false
i = i +1
response.write "<tr><td><input type=""text"" id=""" & "lineQty" & cstr(i) & """ value=""" & cstr(order_array(i , 1)) &
"""></td><td id=""" & "prodDesc_" & cstr(rs("prod_id")) & """>" & rs("prod_desc") & "</td><td id=""" & "unitCost" & cstr(i)& """>"
& cstr(rs("prod_unit_cost")) & "</td><td id=""" & "lineTotal" & cstr(i) & """>" & cstr(order_array(i, 3)) & "</td></tr>"
.movenext
loop
end with
%>

When the form is submitted, an array that contains the quantities, prices, and totals are calculated from the values entered in
the form. Piece of cake in classic ASP. How on Earth do I do the same kind of thing in ASP.NET 1.1?

Can someone please point me to a *complete* example of the code to do this (preferably in VB)? All I have come across in the
newsgroups are vague, philosophical discussions or partial snippets that don't explain it clearly enough (or just don't work). I
confess, I haven't gotten past the 30th page or so in Google, but I need to figure this out in very short order now.

Thanks!

Gino


Oct 5 '06 #2

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

Similar topics

2
by: Wee Bubba | last post by:
the lower part of my page consists of a dataList along with other server controls and HTML markup. this is my data display section. the upper part of my page is a data entry section. what I want...
4
by: Bas Groeneveld | last post by:
I am developing an ASP.NET application part of which consists of a data entry wizard defined by entries in a data table - ie the controls on each page of the wizard are determined by definitions in...
2
by: Patrick | last post by:
I want to define a set of web-form templates in XML and render the equivalent web-form with ASP.NET, then process any input server controls on the form. Reading the XML file from Page_load is...
1
by: Marcus | last post by:
I have a problem maybe one of you could help me with. I've created a data entry screen with lots of dynamically-created client-side controls. I create HTML texboxes client-side by assigning a...
2
by: filbennett | last post by:
Hi Everyone, I'm generally unfamiliar with Access form design, but have programmed Cold Fusion applications for a couple of years. I'd like to build a data entry form in Access that allows the...
2
by: Sethos | last post by:
I am sure that this has been covered, hashed, and rehashed, but a search on the group did not produce the answer, so forgive me if this seems like a "newbie" type question... Besically, I have a...
9
by: Suman | last post by:
Happy Friday everyone!!! I am working on a windows service and a C# application and needed some help with certain functionality. Please read through my issue below. Thanks! I have a windows...
0
by: lianaent | last post by:
Hi All, I'm brand new to asp.net 2.0, and have a simple task of just creating a quick and dirty data entry form with SQL Server 2005 on the back end. I added a gridview to my form, and I can...
30
ADezii
by: ADezii | last post by:
This week’s Tip of the Week will clearly demonstrate how you can dynamically set the Drop Down List Width of a Combo Box to the length of the longest item in its Row Source. The inspiration for this...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
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:
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
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...

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.