473,586 Members | 2,817 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

HtmlRadioButton Datagrid Postback

Hi,

I've been working for about a week to solve this problem, but have'nt
found a solution, i'm not a .NET professional so maybe someone here may have
a solution.

Here's my problem.

I have a datagrid with a list of product, with checkbox on each line to
select witch product we want. But on one product row i need to add a Radio
Button list so the user can select if he want To Buy, Lease or if he always
have it at home. But on some other product i have a AutoPostback = True, so
my Radiobutton lose it's status after the postback. Is there a way to solve
this ?

I use this to add the Radio buttons :

divmodem = <div id='modeminfo' runat='server'> MAC: <input type=text
name='modemMac' </div>"

dr = dt.NewRow
dr(0) = "Modem option<br><inpu t type=radio checked name=omodem
value=buy>99.95 $<br><input type=radio name=omodem value=location> Location
15$/month<br><input type=radio name=omodem value=haveit
onclick=""modem Details('haveit ');"">Already" + divmodem
dt.Rows.Add(dr)

If the user click on the "haveit" RadioButton the a display a text box
to enter is Modem Mac Address.

I cut some code, so if you need more details i can post another message.

Thank you.
Nov 19 '05 #1
1 1283
Problem solved, using some Javascript.

Tnx
"Andre" <we*******@cabl evision.qc.ca> a écrit dans le message de
news:OE******** ******@tk2msftn gp13.phx.gbl...
Hi,

I've been working for about a week to solve this problem, but have'nt
found a solution, i'm not a .NET professional so maybe someone here may have a solution.

Here's my problem.

I have a datagrid with a list of product, with checkbox on each line to select witch product we want. But on one product row i need to add a Radio
Button list so the user can select if he want To Buy, Lease or if he always have it at home. But on some other product i have a AutoPostback = True, so my Radiobutton lose it's status after the postback. Is there a way to solve this ?

I use this to add the Radio buttons :

divmodem = <div id='modeminfo' runat='server'> MAC: <input type=text
name='modemMac' </div>"

dr = dt.NewRow
dr(0) = "Modem option<br><inpu t type=radio checked name=omodem
value=buy>99.95 $<br><input type=radio name=omodem value=location> Location
15$/month<br><input type=radio name=omodem value=haveit
onclick=""modem Details('haveit ');"">Already" + divmodem
dt.Rows.Add(dr)

If the user click on the "haveit" RadioButton the a display a text box
to enter is Modem Mac Address.

I cut some code, so if you need more details i can post another message.
Thank you.

Nov 19 '05 #2

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

Similar topics

2
945
by: DelphiBlue | last post by:
I have a Nested Datagrid that is using a data relations to tie the parent child datagrids together. All is working well with the display but I am having some issues trying to sort the child datagrid. HTML Datagrid1 TemplateColumn Table Header information Detail Information
7
3548
by: A.M | last post by:
Hi, I want to refresh my DataGrid data on every postback. I have following code in Page_Load event, but after first page load, the DataGrid never gets refresh. Here is the code i have in Page_load (it works at first page_load): Dim DS As DataSet Dim MyConnection As System.Data.SqlClient.SqlConnection
1
3426
by: Michelle Stone | last post by:
Hi all. I have an empty datagrid on my web form. And I add BoundDataColumn(s) to it through code. But after each postback, the columns and rows disappear. As a workabout, I tried to rebind the datagrid to the dataset (stored in a session variable) on the PageLoad function which works fine. But my datagrid has a button-column called EDIT...
2
2391
by: Bruce W.1 | last post by:
There's something I can't figure out. I added some javascript behavior to my datagrid, just like in this article, except in C# instead of VB: http://www.dotnetbips.com/displayarticle.aspx?id=205 If I bind the datagrid to the dataset at all times, whether Postback or not, then everything works fine. However if I only bind it when Page...
2
5920
by: Fluxray | last post by:
--Background: I have a webform including a datagrid. The datagrid is using template. Its ItemTemplate is used to display a look-up-table with labels. its EditItemTemplate is used to edit a row in the look-up-table with textboxes. I have a linkbutton in each row (causevalidation = false) named 'Edit' to post the page back such that the page is...
2
2210
by: Mark Rae | last post by:
I've inherited an ASP.NET app and have been asked to fix the following problem with a page which is used to display and/or delete records from a database. When the page loads, it displays a list of the 26 letters of the alphabet as hyperlinks which the users then click to return records beginning with that letter, displayed in a DataGrid. The...
2
1678
by: Jim Bancroft | last post by:
This may be a no-brainer, but I'm sure I follow what's happening here... I have a DataGrid with one DropDownList per row. If I select a few DropDown items and postback my page, I can't loop through the DataGridItems unless I rebind my DataGrid. By "can't loop," I mean it's a mighty quick run through-- zero iterations. I was...
1
1631
by: wh1974 | last post by:
I'm not sure if i'm heading in the right direction so would appreciate any comments on what I'm trying to do. Basically I have a DataGrid on a page which has columns whose width's I set in the DataGrid's ItemCreated event and which need to be remembered after a postback. I bind to the DataGrid in the Page_Load event when PostBack is...
6
2428
by: SkeanDu | last post by:
Ok, here is my problem. I have an aspx page that displays a databound datagrid and in one of the datagrid column headers I have an image that when clicked opens up a modal web dialog (another aspx page). >From this dialog I want the users to be able to select a filter item from a databound combobox and click on the apply button on the web...
0
7911
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...
0
7839
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...
0
8338
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7954
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...
1
5710
isladogs
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...
0
5390
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...
0
3864
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2345
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
1
1448
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.