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

grdiview selectedindex & selectedvalue

I have the selectedindex of a gridview, but no value. How do I set the
selectedvalue of a gridview?

My scenario: I have 3 gridviews on a page, all of which use the same insert
record control. When the user inserts a record, everything works fine
because it is getting the selectedvalue of the gridview that is selected.
However once a record is inserted, the gridviews are rebound, but the
gv.SelectedIndex is saved from the gridview that the user selected. When a
user enters a second record, I have the SelectedIndex, but there is no
selectedvalue. So if I have the selectedindex, how do I get the
SelectedValue of that gridview. Hope that makes sense & thanks so much for
your help.

Feb 19 '08 #1
0 996

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

Similar topics

2
by: Alexandre Jaquet | last post by:
Hi, Under IE I could not point why I can't get the selected value from a function here the code function Lvl_P2P(url,closeIt,delay){ //ver1.0 4LevelWebs var fabricant_box; var...
0
by: jac | last post by:
Hey, this.CmbDataSource = SoortKwijtingList.Items; // Arraylist this.Cmb.DisplayMember = "Omschrijving"; this.Cmb.ValueMember = "Id"; this.Cmb.SelectedIndex = -1; (short description : I...
4
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...
6
by: Nathan Sokalski | last post by:
I am writing a User Control that uses 3 DropDownLists. When I attempt to access the SelectedIndex property it incorrectly reports the value selected by the user. Why is this? Here is my code,...
2
by: Stimp | last post by:
I'm getting the error: 'SelectedIndex' and 'SelectedValue' attributes are mutually exclusive when I try to populate a series of dropdowns... any idea what I could be doing wrong here? ...
5
by: Stimp | last post by:
Hi all, I've come back to this problem again and I've identified which part of my code is producing the error: "'SelectedIndex' and 'SelectedValue' attributes are mutually exclusive" I...
4
by: Mark L. Breen | last post by:
Hello All, I have a selected index for a combo, which I percieve to be the best value to use when programitically maniplating combos. What I want to be able to do is retrieve the Selected...
4
by: Dooman | last post by:
Hello, I am getting this error when binding a drop down list box to a dataset: The 'SelectedIndex' and 'SelectedValue' attributes are mutually exclusive I have looked at other posts and...
1
by: marcbb | last post by:
Hi all, I have a really strange problem working with Dropdownlists in a DataGrid. I'm trying to preselect some values from the DropDownlist for each row in the DataGrid, but it seems that...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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
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...
0
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,...
0
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...

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.