473,608 Members | 2,412 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to select an inserted row ina datagrid?

Do i have to loop trough a datagrid in order to find and select a row just
being inserted? is there any event i can capture in the datagrid to obtain
the inserted row? I need to obtain its position in the datagrid...

Any help is very welcome.
Nov 16 '05 #1
2 1521
hi juan,

am not able to get your question, what do u mean by inserting a row in a
datagrid.
and r u talking about the datagrid in windows or web.
If am right in saying that inserting a row in a webforms datagrid is none
other than adding a new row to the dataset and rebinding it to the grid.

Might be able to help you better if i can get exactly what you wanted....

Regds,
Kannan.V

"Juan" wrote:
Do i have to loop trough a datagrid in order to find and select a row just
being inserted? is there any event i can capture in the datagrid to obtain
the inserted row? I need to obtain its position in the datagrid...

Any help is very welcome.

Nov 16 '05 #2
Thanks Kannan,

I insert the row but afther that i immediately need to select it, the
datagrid doesn´t select the new inserted row by default, it continues to be
at the row it was before the insert... it is a windows form.

Best,
Juan.
"Kannan.V [MCAD.net]" <Ka************ @discussions.mi crosoft.com> escribió en
el mensaje news:6B******** *************** ***********@mic rosoft.com...
hi juan,

am not able to get your question, what do u mean by inserting a row in a
datagrid.
and r u talking about the datagrid in windows or web.
If am right in saying that inserting a row in a webforms datagrid is none
other than adding a new row to the dataset and rebinding it to the grid.

Might be able to help you better if i can get exactly what you wanted....

Regds,
Kannan.V

"Juan" wrote:
Do i have to loop trough a datagrid in order to find and select a row just being inserted? is there any event i can capture in the datagrid to obtain the inserted row? I need to obtain its position in the datagrid...

Any help is very welcome.

Nov 16 '05 #3

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

Similar topics

2
3110
by: M Wells | last post by:
Hi All, I need to change a column value in several thousand records in a table and output a list of the record ids of the records I've updated into another table. The table, however, is being used by other users via a website, so I need to make certain that website requests don't touch on the records I'm selecting / updating.
0
1070
by: Juan | last post by:
Do i have to loop trough a datagrid in order to find and select a row just being inserted in the dataset connected to the data grid? is there any event i can capture in the datagrid to obtain the inserted row? I need to obtain its position in the datagrid... Any help is really welcome.
0
1051
by: Juan | last post by:
I built a form with two datagrid representing a master-detal relationship, everything works fine except fot the first row inserted in the dataset (in the detail table), it is not displayed after being inserted in the dataset's table (I have to reload the form), after that every row is displayed correctly after being inserted. Best Regards, Juan.
2
9917
by: Chris Plowman | last post by:
Hi all, I was wondering if anyone can help me with a really annoying problem I have been having. I made a derived datagrid class that will select the row when a user clicks anywhere on a cell (multi-select without modifier keys). I got that working fine, but I also wanted to keep rows selected after a sort, which I do by storing the row's id in an arraylist. The idea was to do the sort and then go back and re-select the rows with that...
5
6544
by: Vik | last post by:
If there are a few Select buttons in a datagrid, is there a way to distinguish in code which button was clicked? Thanks.
8
12982
by: Malc | last post by:
Can somebody please tell me whether the following syntax is supported or whether it's a "feature" that will someday stop working. It works in both SQL Server 2000 and 2005 at the moment. declare @var varchar(1000) set @var = '' select @var = @var + colx from some_table where col1 = some_value colx is a varchar or at least is cast to one as part of the select statement. If the where clause would normally return more than one row,
1
2321
by: new | last post by:
I am building an effective dated file that shows results to date. In part 1 of the select I I process a larges set of input and genrate records for each date in the processing period for which there has been activity In part II I then want to select the most recent effective dated record (if any and whether it existed before this run or was generated by an earlier insert) and sum it with the record for this date
13
5776
by: PinkBishop | last post by:
I am using VS 2005 with a formview control trying to insert a record to my access db. The data is submitted to the main table no problem, but I need to carry the catID to the bridge table CatalogImage where imgID also needs to be placed. Below is my code behind to carry the catID using the Select @@Identity and insert imgID to the bridge table. No data is being entered into the bridge table.
0
8010
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,...
0
8501
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
8157
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
8349
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
6820
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
3967
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...
1
2477
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
1607
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1336
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.