473,796 Members | 2,728 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How can I enter value based on Selected item



hii

i created a form like this
<html>
<head>
<title>ACCOUN T EXAMPLE</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>

<body bgcolor="#FFFFF F" text="#000000">

<p>&nbsp;</p>
<p>&nbsp;</p>
<form name="form1" method="post" action="">
<table width="821" border="0" cellspacing="0" cellpadding="0" >
<tr>
<td width="239">
<div align="center"> <font size="2"><b>DAT E :</b></font>
<input type="text" name="txtDate">
</div>
</td>
<td width="312"> <font size="2"><b>DET AILS :</b></font>
<textarea name="txtDetail s" rows="2" cols="30">SALAR Y PAID
</textarea>
</td>
<td width="85">
<div align="center">
<select name="select">
<option>DEBIT </option>
<option>CREDI T</option>
</select>
</div>
</td>
<td width="102">
<div align="left">
<input type="text" name="txtAmount " value="RS 5000">
</div>
</td>
<td width="11">
<input type="submit" name="Submit" value="INSERT">
</td>
</tr>
</table>
</form>
<p>&nbsp;</p>
</body>
</html>
when the user selects debit I want the amount to go into the debit field
of the accounts table and when he users selects credit it should go into
the credit field(colum) of the accounts table

how can I do this in ULTRADEV or UD

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 19 '05 #1
1 1269
What table are you talking about? In a database? If so, you'll use a
if-then, or a select-case, like so:
Dim sType
sType = Request.Form("Y ouNeedToNameYou rSELECTandPutTh eNameHere")
'You also need to give values to the options

Select Case sType
Case "CREDIT"
sSQL = "your appropriate sql string"
Case "DEBIT"
sSQL = "your appropriate sql string"
End Select

Ray at home

"techy techno" <an**********@h otmail.com> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..


hii


when the user selects debit I want the amount to go into the debit field
of the accounts table and when he users selects credit it should go into
the credit field(colum) of the accounts table

how can I do this in ULTRADEV or UD

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Jul 19 '05 #2

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

Similar topics

0
2149
by: Kannan.M.R | last post by:
Hi, I have a problem in assigning the selected value in the dropdown to a hidden control. It goes like this. I have a repeater control. In the repeater control’s item template, I have a hidden control and a placeholder control. I must generate the required number of dropdowns and the buttons dynamically based on a field value in my dataset. So I do the same in my code behind and add the generated controls to the place holder in the...
4
9668
by: Emil | last post by:
Can somebody tell me what would be the syntax for having an if statement and setting the selected index of a radiobuttonlist? This is my first project using ASP.net and I use C#. I have a repeater with like a table layout and in the last column I want to have three radio buttons (for each row in repeater). The value of the radio button should be calculated from a value from the dataset. How can I do that? When I try to use a variable...
3
1841
by: markaelkins | last post by:
Hi. I am trying to enter a variable in the treenodesrc of a treenode. I am basically trying to send an ID variable into sql to return different records. I've searched everywhere and cannot find the answer. I'd appreciate and help. Thanks. What I'm doing is creating a treeview with the structure as follows (this is the expanded view): - Item Status - Item Status Details
2
2129
by: Billy | last post by:
Change DataGrid EditControl On Data Value Hi, I have a datagrid, and on editing, I want to change the control in the third colunm based on the value of the first column. The value in the first column can only be either "Text" or "Image", which is selcted in a dropdown list.
1
2171
by: savas_karaduman | last post by:
There is a subform embedded into a Main Form... Subform is standing for entering data into a table... There is a combobox on the Main Form... How Combo Box value can be added into table to which we enter data from subform? I mean, when you enter 10 new items in the subform, combo box value should take place for a specific column ot that table for every new 10 item... Am I clear?
0
1007
by: divyabhasin | last post by:
HI I want to assign a specific value to an item in combobox and want that value to be entered in database instead of the selected item. For Ex- In the Combobox I have selected "PlayFile" ,Now I want to enter "arg" in the database instead of " PlayFile". Please help its really urgent.
6
5556
by: Brandon McCombs | last post by:
Hello, I have a form that contains a listview on the left side and a column of buttons on the right side. Only some of the buttons do I want enabled all the time. The other buttons should be enabled only if something is selected in the listview. That part specifically works but not very well. It seems that I can only get the buttons to disable if I click off the text of the items in the listview but still within about 10-20 pixels of...
1
5078
by: waltnixon | last post by:
I've got an MS Access query which runs fine when double clicked and returns all of the rows in a test database I'm building. I've set up a multi group report based on the query. I immediately began getting the "Enter Parameter Value" dialog and it was asking for the query by its name "sel_report_data" whenever I tried to run or preview the report. To troubleshoot the problem, I selected the query in the database window, hit the "New...
1
4256
by: Andrus | last post by:
I need to enter null value from combobox to business object property. My combobox datasource does not contain ValueMember with null value. So I tried to create combobox which stores null to bound object when text is deleted. However bound object contains old value in this case. To reproduce: 1. Run code
0
11618
by: JosAH | last post by:
A Simple Text-Based Menu System Read this this post; there are numerous posts like that: a newbie struggling with some sort of menu implementation. They want nested menus of course and an option to quit the entire thing. Of course they tie their 'business rules' tight together with their (feeble) attempts of their individual menu items and get heavily entangled in complicated control structures. The post (see the link above) made me write...
0
9685
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, 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...
0
10467
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10201
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,...
0
10021
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 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...
0
9061
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, 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...
0
6802
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5582
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4130
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 we have to send another system
3
2931
bsmnconsultancy
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...

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.