If I have say 10 fixed variables, how can I set their values = to that
of a form that is built dynamically?
column1 column2
email = formvalue(0)
fname = formvalue(1)
lname = formvalue(2)
etc..
lastvar = formvalue(9) 10 2114
What do you mean? <input type="text" value="<%=varia bleName%>">
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. .. If I have say 10 fixed variables, how can I set their values = to that of a form that is built dynamically?
column1 column2 email = formvalue(0) fname = formvalue(1) lname = formvalue(2)
etc..
lastvar = formvalue(9)
No, I would need to loop though the values of a drop down list and
assign value1 to email, value2 to fname...
Ray at <%=sLocation% > [MVP] wrote: What do you mean? <input type="text" value="<%=varia bleName%>">
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
If I have say 10 fixed variables, how can I set their values = to that of a form that is built dynamically?
column1 column2 email = formvalue(0) fname = formvalue(1) lname = formvalue(2)
etc..
lastvar = formvalue(9)
When, when the page is submitted? When it is loaded? Can you explain this
in a little more detail?
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. .. No, I would need to loop though the values of a drop down list and assign value1 to email, value2 to fname...
Ray at <%=sLocation% > [MVP] wrote:
What do you mean? <input type="text" value="<%=varia bleName%>">
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
If I have say 10 fixed variables, how can I set their values = to that of a form that is built dynamically?
column1 column2 email = formvalue(0) fname = formvalue(1) lname = formvalue(2)
etc..
lastvar = formvalue(9)
> No, I would need to loop though the values of a drop down list and assign value1 to email, value2 to fname...
When you have a drop-down box only the selected item is submitted with the
form, the non-selected values are "lost"
A user will fill out the dropdown list and hit submit - a form will then
map the constants to the form values to build a SQL string that will
be passed to a stored procedure.
Ray at <%=sLocation% > [MVP] wrote: When, when the page is submitted? When it is loaded? Can you explain this in a little more detail?
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
No, I would need to loop though the values of a drop down list and assign value1 to email, value2 to fname...
Ray at <%=sLocation% > [MVP] wrote:
What do you mean? <input type="text" value="<%=varia bleName%>">
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2***** ***********@TK2 MSFTNGP09.phx.g bl...
If I have say 10 fixed variables, how can I set their values = to that of a form that is built dynamically?
column1 column2 email = formvalue(0) fname = formvalue(1) lname = formvalue(2)
etc..
lastvar = formvalue(9)
Yes, I don't want the non-selected values.
The form is built dynamically from an uploaded .csv -- the first line of
the .csv is loaded into a drop down list. There is another, static list
that matches up with those values.
Adrian Forbes [ASP MVP] wrote: No, I would need to loop though the values of a drop down list and assign value1 to email, value2 to fname...
When you have a drop-down box only the selected item is submitted with the form, the non-selected values are "lost"
So, you'll have an unknown number of values to assign to an unknown number
of variables? What about putting them in an array? If I fill out your
form, and I enter these terms in your select box:
cat
bird
ferret
what is the ultimate goal as far as what your SQL string will look like?
Ray at home
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message
news:eq******** ******@TK2MSFTN GP09.phx.gbl... A user will fill out the dropdown list and hit submit - a form will then map the constants to the form values to build a SQL string that will be passed to a stored procedure.
Ray at <%=sLocation% > [MVP] wrote:
When, when the page is submitted? When it is loaded? Can you explain
this in a little more detail?
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
No, I would need to loop though the values of a drop down list and assign value1 to email, value2 to fname...
Ray at <%=sLocation% > [MVP] wrote:
What do you mean? <input type="text" value="<%=varia bleName%>">
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2***** ***********@TK2 MSFTNGP09.phx.g bl...
>If I have say 10 fixed variables, how can I set their values = to that >of a form that is built dynamically? > >column1 column2 >email = formvalue(0) >fname = formvalue(1) >lname = formvalue(2) > >etc.. > >lastvar = formvalue(9)
Hey Ray, thanks for sticking in...
I'll have an unknown number of values loaded from the .CSV, but no more
than 10. There will also be a fixed number of variables to assign them
to. If there is only 7 loaded the rest will be set to "".
The .csv might have user user_email, first_name, last_name so they would
map those to the fixed values email, fname, lname.
The SQL string is a very simple insert:
insert into tbl_test (email, fname, lname)
values ('"&user_email& "','"&first_nam e&"','"&last_na me&"')
This is the basic idea:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Untitl ed Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<table width="300">
<tr>
<td>Fixed List</td>
<td>CSV List</td>
</tr>
<tr>
<td>Email</td>
<td><select name="flds">
<option name="none" value="none">no ne</option>
<option name="user_emai l" value="user_ema il">user_emai l</option>
<option name="user_fnam e" value="user_fna me">user_fnam e</option>
<option name="user_lnam e" value="user_lna me">user_lnam e</option>
</select></td>
</tr>
<tr>
<td>First Name</td>
<td><select name="flds">
<option name="none" value="none">no ne</option>
<option name="user_emai l" value="user_ema il">user_emai l</option>
<option name="user_fnam e" value="user_fna me">user_fnam e</option>
<option name="user_lnam e" value="user_lna me">user_lnam e</option>
</select></td>
</tr>
<tr>
<td>Last Name</td>
<td><select name="flds">
<option name="none" value="none">no ne</option>
<option name="user_emai l" value="user_ema il">user_emai l</option>
<option name="user_fnam e" value="user_fna me">user_fnam e</option>
<option name="user_lnam e" value="user_lna me">user_lnam e</option>
</select></td>
</tr>
</table>
</body>
</html>
Ray at <%=sLocation% > [MVP] wrote: So, you'll have an unknown number of values to assign to an unknown number of variables? What about putting them in an array? If I fill out your form, and I enter these terms in your select box:
cat bird ferret
what is the ultimate goal as far as what your SQL string will look like?
Ray at home
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:eq******** ******@TK2MSFTN GP09.phx.gbl...
A user will fill out the dropdown list and hit submit - a form will then map the constants to the form values to build a SQL string that will be passed to a stored procedure.
Ray at <%=sLocation% > [MVP] wrote:
When, when the page is submitted? When it is loaded? Can you explain this in a little more detail?
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2***** ***********@TK2 MSFTNGP09.phx.g bl...
No, I would need to loop though the values of a drop down list and assign value1 to email, value2 to fname...
Ray at <%=sLocation% > [MVP] wrote: >What do you mean? <input type="text" value="<%=varia bleName%>"> > >Ray at work > >"Dave Karmens" <sp************ *@yahoo.ca> wrote in message >news:%2*** *************@T K2MSFTNGP09.phx .gbl... > > > >>If I have say 10 fixed variables, how can I set their values = to that >>of a form that is built dynamically? >> >>column1 column2 >>email = formvalue(0) >>fname = formvalue(1) >>lname = formvalue(2) >> >>etc.. >> >>lastvar = formvalue(9) > > >
In that case, split your select value and assign the values to your
variables, like:
On Error Resume Next
firstvar = Request.Form("s elect")(1)
secondvar = Request.Form("s elect")(2)
thirdvar = Request.Form("s elect")(3)
fourthvar = Request.Form("s elect")(4)
fifthvar = Request.Form("s elect")(5)
sixthvar = Request.Form("s elect")(6)
seventhvar = Request.Form("s elect")(7)
eighthvar = Request.Form("s elect")(8)
ninthvar = Request.Form("s elect")(9)
tenthvar = Request.Form("s elect")(10)
On Error Goto 0
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message
news:Oz******** ******@TK2MSFTN GP12.phx.gbl... Hey Ray, thanks for sticking in...
I'll have an unknown number of values loaded from the .CSV, but no more than 10. There will also be a fixed number of variables to assign them to. If there is only 7 loaded the rest will be set to "".
The .csv might have user user_email, first_name, last_name so they would map those to the fixed values email, fname, lname.
The SQL string is a very simple insert:
insert into tbl_test (email, fname, lname) values ('"&user_email& "','"&first_nam e&"','"&last_na me&"')
This is the basic idea:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>Untitl ed Document</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body> <table width="300"> <tr> <td>Fixed List</td> <td>CSV List</td> </tr> <tr> <td>Email</td> <td><select name="flds"> <option name="none" value="none">no ne</option> <option name="user_emai l" value="user_ema il">user_emai l</option> <option name="user_fnam e" value="user_fna me">user_fnam e</option> <option name="user_lnam e" value="user_lna me">user_lnam e</option> </select></td> </tr> <tr> <td>First Name</td> <td><select name="flds"> <option name="none" value="none">no ne</option> <option name="user_emai l" value="user_ema il">user_emai l</option> <option name="user_fnam e" value="user_fna me">user_fnam e</option> <option name="user_lnam e" value="user_lna me">user_lnam e</option> </select></td> </tr> <tr> <td>Last Name</td> <td><select name="flds"> <option name="none" value="none">no ne</option> <option name="user_emai l" value="user_ema il">user_emai l</option> <option name="user_fnam e" value="user_fna me">user_fnam e</option> <option name="user_lnam e" value="user_lna me">user_lnam e</option> </select></td> </tr> </table> </body> </html>
Ray at <%=sLocation% > [MVP] wrote: So, you'll have an unknown number of values to assign to an unknown
number of variables? What about putting them in an array? If I fill out your form, and I enter these terms in your select box:
cat bird ferret
what is the ultimate goal as far as what your SQL string will look like?
Ray at home
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:eq******** ******@TK2MSFTN GP09.phx.gbl...
A user will fill out the dropdown list and hit submit - a form will then map the constants to the form values to build a SQL string that will be passed to a stored procedure.
Ray at <%=sLocation% > [MVP] wrote:
When, when the page is submitted? When it is loaded? Can you explain
this
in a little more detail?
Ray at work
"Dave Karmens" <sp************ *@yahoo.ca> wrote in message news:%2***** ***********@TK2 MSFTNGP09.phx.g bl...
>No, I would need to loop though the values of a drop down list and >assign value1 to email, value2 to fname... > >Ray at <%=sLocation% > [MVP] wrote: > > > >>What do you mean? <input type="text" value="<%=varia bleName%>"> >> >>Ray at work >> >>"Dave Karmens" <sp************ *@yahoo.ca> wrote in message >>news:%2*** *************@T K2MSFTNGP09.phx .gbl... >> >> >> >>>If I have say 10 fixed variables, how can I set their values = to
that>>>of a form that is built dynamically? >>> >>>column1 column2 >>>email = formvalue(0) >>>fname = formvalue(1) >>>lname = formvalue(2) >>> >>>etc.. >>> >>>lastvar = formvalue(9) >> >> >>
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: propizzy |
last post by:
Appreciate any help!!!
PROBLEM: I have this form that allows the user to dynamically create
additional fields (see javascript code bellow). I am trying to retrieve
the values entered into these fields from my php script. I ultimatly
need to pick out the variables and place the values into my php script
page. I have worked with a little code I found on php.net (see php code
below), but I wan unable to grasp the knowledge on how to...
|
by: Nick |
last post by:
Loop to create an array from a dynamic form.
I'm having trouble with an application, and I'll try to explain it as
clearly as possible:
1. I have a form with two fields, say Apples and Oranges. The user
selects from a drop down menu, between 1-10 of each and clicks submit.
The resulting page will display a NEW form, with rows and a list of
fields for the amount of each items selected.
|
by: Jack |
last post by:
Hi,
I am trying to test a sql statement in Access which gives me
the error as stated in the heading.
The sql statement is built as a part of asp login verification,
where the userid and password are input in login screen.
The password in the database is a number field.
I am writing the dynamic sql statement as follows below. I believe
I am going wrong in the password section of the code. I
appreciate any help. Thanks. Regards.
|
by: Nathan Bloomfield |
last post by:
Does anyone know if there is any documentation which relates to Access2k + ?
or can anyone help adjust the code?
I am having trouble converting the DAO references.
TITLE :INF: How to Create a Dynamic Crosstab Report
PRODUCT :Microsoft Access
PROD/VER:1.00 1.10
OPER/SYS:WINDOWS
|
by: deejayquai |
last post by:
Hi
I'm trying to produce a report based on a dynamic crosstab. Ultimately
i'd like the report to actually become a sub report within a student
end of year record of achievement. The dynamic sub-report will capture
what grades the student has achieved in a list of different subjects
and the reason I need it to be dynamic is that students take different
subjects.
Basically I've been trying to doctor the KB article on dynamic
| |
by: cindy |
last post by:
I have a dynamic datagrid. I have custom classes for the controls
public class CreateEditItemTemplateDDL : ITemplate {
DataTable dtBind;
string strddlName;
string strSelectedID;
string strDataValueField;
string strDataTextField;
public CreateEditItemTemplateDDL(string DDLName,string DataValueField,string
|
by: assgar |
last post by:
Hi
Developemnt on win2003 server. Final server will be linux
Apache,Mysql and PHP is being used.
I use 2 scripts(form and process).
The form displays multiple dynamic rows with chechboxs, input box for units of service, description of the service and each row has its own dropdown list of unit fees that apply.
Each dynamically created row will return 3 values fee1_choice, fee1_unit and fee1_money.
Note The above informaton is...
|
by: englishman69 |
last post by:
Hello,
I have been banging my head against this one for a while... Searches online have revealed many different proposals for correcting my issue but none that I can follow! My basic situation is this, I have a page which uses multiple postbacks to generate a list of dynamic text boxes with appropriate labels. However, when I do the final postback to enter the values in the dynamic textboxes into the database the values seem to become...
|
by: =?Utf-8?B?RHlsYW5TbWl0aA==?= |
last post by:
I have a WebForm where I'm dynamically creating some controls and I'm having
difficulty understanding how the state is being persisted and how to work
with it.
I've created a simplified example to demonstrate my issues. Lets say I have
a WebForm with a DropDownList where the user selects a number from 1 to 10
(the DropDownList is not dynamically created). I also have a button on there
that I use to trigger a PostBack.
Based on the...
|
by: jmartmem |
last post by:
Greetings,
I have a nagging problem with client-side dynamic dependent list boxes that perhaps someone can help me troubleshoot.
I have a form with a series of dynamic dependent list boxes. Making a selection from list/box A (Qtr) selects a fiscal quarter, which then refreshes the values in list/box B (Mth), which shows the 3 months in that fiscal quarter, which then refreshes the values in list/box C (MthDate), which returns the date...
|
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...
| |
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
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,...
|
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
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...
|
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...
| |
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
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...
| |