problem with selected text field and selected value field in check box list



i have a  problem with check box list:

here is the code for binding the check box list with sqldatasource 

 SqlDataSource1.SelectCommand = "select vcentrolno,inttpaperno from tabmarksdetails where vcbunchno='" & strBunchNo & "'"

say now my chkEnrolNos consist of data in this way:

vcentrolno        inttpaperno
selected text   selected value
A11439            1
A11439            2
AR439             3
AR11440          1
AR11440          2

assuming first 4 items are selected 

in for loop:

when i am selecting the first item i am getting the correct values of  vcentrolno  and  inttpaperno  ie, for vcentrolno as selected field item and inttpaperno as selected value item.

now the problem is with the second item. here second item vcentrolno  is same as first one but the selected value field is different but am getting the same selected value of first item ie 1.

 for other vcentrolno  i am getting the correct selected value. this problem occurs only when the vcentrolno is same other wise its working fine.

plz can any body solve my problem 

thank u,


function __RP_Callback_Helper(str, strCallbackEvent, splitSize, func){var event = null;if (strCallbackEvent){event = document.createEvent('Events');event.initEvent(strCallbackEvent, true, true);}if (str && str.length > 0){var splitList = str.split('|');var strCompare = str;if (splitList.length == splitSize)strCompare = splitList[splitSize-1];var pluginList = document.plugins;for (var count = 0; count = sSrc.length){if (strCompare.indexOf(sSrc) != -1){func(str, count, pluginList, splitList);break;}}}}if (strCallbackEvent)document.body.dispatchEvent(event);}function __RP_Coord_Callback(str){var func = function(str, index, pluginList, splitList){pluginList[index].__RP_Coord_Callback = str;pluginList[index].__RP_Coord_Callback_Left = splitList[0];pluginList[index].__RP_Coord_Callback_Top = splitList[1];pluginList[index].__RP_Coord_Callback_Right = splitList[2];pluginList[index].__RP_Coord_Callback_Bottom = splitList[3];};__RP_Callback_Helper(str, 'rp-js-coord-callback', 5, func);}function __RP_Url_Callback(str){var func = function(str, index, pluginList, splitList){pluginList[index].__RP_Url_Callback = str;pluginList[index].__RP_Url_Callback_Vid = splitList[0];pluginList[index].__RP_Url_Callback_Parent = splitList[1];};__RP_Callback_Helper(str, 'rp-js-url-callback', 3, func);}function __RP_TotalBytes_Callback(str){var func = function(str, index, pluginList, splitList){pluginList[index].__RP_TotalBytes_Callback = str;pluginList[index].__RP_TotalBytes_Callback_Bytes = splitList[0];};__RP_Callback_Helper(str, null, 2, func);}function __RP_Connection_Callback(str){var func = function(str, index, pluginList, splitList){pluginList[index].__RP_Connection_Callback = str;pluginList[index].__RP_Connection_Callback_Url = splitList[0];};__RP_Callback_Helper(str, null, 2, func);}
8/24/2007 8:32:45 AM 93655 articles. 6 followers. Follow

0 Replies

Similar Articles

[PageSpeed] 30


Similar Artilces:

Load Text box of one web form with selected list item of list box of another web form
one help please Problem is i have two web forms  1.  ForiegnkeyTest.aspx  2. foroginkeytable.aspx   step 1 1 ForiegnkeyTest.aspx one web form <head runat="server"><script language="javascript" type="text/javascript">   function popWin()   {         var confirmWin = null;      confirmWin ='foroginkeytable.aspx','anycontent',   'width=455,height=435,status');   }  </script> &...

Selecting value in one field then causes value in another field to be selected.
I have a web form which contains a date field, the date is populated using a DatePicker which is Javascript based. The form also has a drop down box containing 3 values. What I want to do is when a date has been selected that this will cause the dropdown list value to change to dated which is one of its 3 values. i.e. when the date field is not blank then the value will be selected in the dropdown. What I also want to happen is when the date has been selected and the dropdown value is dated then the date field and the dropdown field will be set to read only.Anyone any ideas how to this usin...

Problem in selecting text in List box Web Form
hi In List box load the data from database. If i am select any Item from list box i am geting selected Indexvalue ="-1" at the same time i am not get the text value. how can i get the selected index text value. Regards, Sabarish. Hi, it sounds to me that you're rebinding your data upon every postback. If you're doing it in code behind place it between if(!Page.IsPostBack) to avoid this. Then you should be able to get a value different than -1 (which means nothing's selected). Grz, Kris.Read my blog. Handy Firefox plugins for web developers.Workaround for...

Please Help, How to pass the field value to a text box when drop downlist box item is selected
I am using the following query: select id, username, company from userinfo order by id. I am using these two fields id and username for the drop down listbox, which is in the datagrid. <EditItemTemplate> <asp:DropDownList id="name_edit" DataSource="<%# BindTheUserName() %>" OnPreRender="SetDropDownIndex" DataTextField="username" DataValueField="id" runat="server" /> </EditItemTemplate> <EditItemTemplate> <asp:Textbox runat="server" MaxLength="20" Columns=&...

Select single distinct field over multi-field selection.
Hi all I am having trouble with retrieving information from my SQL database in the way I would like it. The select statement has to retrieve data from 5 different tables, only certain fields have to be returned. One table contains a category name, a single category can appear more than once in this table, I wish only to retrieve the category name once. When I use “DISTINCT” I get errors due to the nature of the data in the other tables, such as the category description. Basically what I wish to achieve is to display the category name (once) out of the category table along with the desc...

Submitting Web forms fields to sql database by clicking on SUBMIT FORM and sending the form fields to email box
I have a created or designed a form to be stored in a SQL database table and at the same time when a user clicks on SUBMIT button the form fields will automatically goto the visitor email address immediately. Also i have created a database with tables for each of this forms Pls help i have over 10 forms designed but the problem of submitting them to the table database and the user email address is the challenge now.... You ned to familiarise yourself with the basics of database access in ASP.NET.  There are free tutuorials here:

DBLookUpComboBox ListSource does not initially show current value. The text field is empty until selected from list.
Hello. I use only the listsource part of this component to select from a table. The challenge is that the form comes up with the component blank. I want it to show the current post field. Really I have tried a lot of things to make it do this, to no avail. I can't manipulate the Text property as it is read only. Moving the source table by code and MyDBLookUpCombo.Refresh does not solve the problem. The component force me to manually select it to make the item show up. After fiddeling around with the properties and desperate code solutions, I give up and ask: How can I ...

Stuck trying to automatically populate three text fields based on value selected in gridview dropdown list
Hello, When I click on the gridview edit button and select a value from the ComponentID DropDown list I would like fields, tbxFunctions, tbxFuncFail, and tbxFailMode to be updated with the information that matched the ComponentID from tblFailures: Question 1) do I need to create an object data source or sql data source to get functions, funcFail, and failMode by ComponentID Question 2) Not Sure how to set the text property to for tbxFunctions, tbxFuncFail, and tbxFailMode.  Do I add a Select Parameter statement below?  <SelectParameters> <as...

How do you pre-select values in a multiple selection list box
Let's say I have a list box like so, this is already rendered: <select name="names" size="3" multiple="multiple" id="names1" > <option value="0">John</option> <option value="1">Mike</option> <option selected="2">Bill</option> </select> how could I pre-selecte two names on load, if I say names1.selectedvalue = "1" it pre-selects Mike cool but if I say names1.selectedvalue = "1,2" then I get an exception. Is there a way ...

Checking if selected field contain value
I am selecting some contetnt from database and than display it into database. Something like that: OleDbConnection objConn = new OleDbConnection(ConfigurationSettings.AppSettings["DSN"]); OleDbCommand objCmd; OleDbDataReader objRdr; objCmd = new OleDbCommand("SELECT * FROM test'", objConn); objRdr = objCmd.ExecuteReader(); dg.DataSource = objRdr; dg.DataBind(); objRdr.Close(); Now I want to check if value of cell is something than display predefinited value in data grid. Sometingh like that: if  (objRdr["Name"]  == "Joe"){ objRdr["Name"]  = "Welcome Joe"; }...

Form Validation: Check if nonrequired fields are selected
Hello all, I'm seeking for some validation help. I've tried a couple of ways to accomplished this but not getting what I want. I'm using interceptAction to intercept the submit button to call a function before the button is executed to check. I'd like to check if any fields A thru E are selected if not then at least one selection is required before processing. This sounds like an easy statement but I'm having a hard time getting it to work. I'm new to ECMAScript and just now starting to get familiar with some functionality. ------------------------- Na...

Check Box List Selected Value Issue
i am trying to get the selected value of a check box list and insert that into a sql statement. no big deal right? lol wrong....i'm dong this in the selectedindexchanged event of the check box list. the first part of the code is just there a tester so i can check and see if the count is being added correctly and if the anythign is getting passed. however the items.count shows correctly but the cklstManagers.Items[i].Selected shows false and i can't get it to show anything but null here is code: for (int i = 0; i < CklstManagers.Items.Count; i++)     &nb...

How to select a field value from a selected row from a DataGrid in order to use it as a parameter
I am working on a web application, and I have two DataGrids.  Then end-User is supposed to select a row from one of the grids, and the event should select a key from that row in order to use it as a parameter to fill the other DataGrid.  I have been trying to do so, but I dont work the same way as I used to do it in windows applications.   I would appreciate any suggestions,   Thanks. Is there some code we can look at? I've done similar things and I've never had any problem with them. In the first grid have a select column, when it is clicked you can catch the Sel...

Dropdownlist selected value passes first value in list no matter what value is selected. why ?
 HI . I have a dropdownlist. Databinds ok but when I must pass a value as a Selected value it always passes the first value in the list even if I select another value. I tried to set the ddl to enableviewstate false but it doesn't change anything. Any ideas ? Code below, thanksLoading the ddl:       productCategories = CatalogAdmin.Admin_Product_Categories_NotIn(productId);        for (int i = 0; i < productCategories.Rows.Count; i++)        {       &...

Web resources about - problem with selected text field and selected value field in check box list -

Portal:Bollywood/Selected biography - Wikipedia, the free encyclopedia
Write three or four paragraphs in the text field using information from the selected notable article, you may find it useful to examine the existing ...

F8: Facebook’s FbStart Initiative Will Give Selected Developers A $30K Kick-Start
... successful applications is likely a whole lot easier with $30,000 in free tools and services to start off with, and that’s exactly what selected ...

LEGO Shop - The LEGO Technic team has selected the winner... - Facebook
The LEGO Technic team has selected the winner of the Co-Creation Challenge! LEGO will be producing a limited run of 20,000 of this stunning set.... ...

Grand Doctor Ma Selected Students-baby365 on the App Store on iTunes
Get Grand Doctor Ma Selected Students-baby365 on the App Store. See screenshots and ratings, and read customer reviews.

Selected Cheney Vice Presidential Photographs
... for photos found within these albums are Paul Morse, Karen Ballard, Kimberlee Hewitt, Shealah Craighead, and Chris Greenberg. These selected ...

[iOS Advice] How To Clarify Your Email Replies By Quoting Selected Text - YouTube
Follow me on Twitter: Like my Facebook page: RATE, COMMENT, SUBSCRIBE! :-) ...

UAE Under-19 cricketers for ACC Premier League tour of Malaysia selected - The National
Coach Aaqib Javed seeking fresh blood for senior team after missing out on World Twenty20

Animal of the Day: Lucius Has Been Selected as the U.K.’s ‘Happiest Cat’
He’s got one blue eye, one green eye and a heart of gold. British mobile phone company O2 recently held some “cat auditions” to find “the UK’s ...

Boyd Cordner selected for Kangaroos squad
Sydney Roosters stars Michael Jennings and Boyd Cordner have capped a grand-final win with selection in the Australian squad for the World Cup ...

Redlands LNP branch blood-letting after Matt McEachan pre-selected
There was more blood-letting in the seat of Redlands on the weekend when a motorcycle instructor was named LNP candidate for the embattled electorate ...

Resources last updated: 12/6/2015 11:20:06 PM