473,498 Members | 1,776 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Multiple datatables in a datagrid

I have a datagrid in windows form bound to a dataset which has list of tables
.. So, when the form is run I see + sign which could be expandable to range of
table names in the grid. How do I find out which table has been selected from
the list on the datagrid?
Nov 16 '05 #1
1 3439
I figured it out and thought let me post the solution.
// add naviagtion event to see which table is being navigated
dataGrid.Navigate += new NavigateEventHandler(Grid_Navigate);

protected void GridGradMap_Navigate(object sender, NavigateEventArgs e)
{
// s will get the table name
string s = ((DataGrid)sender).DataMember.ToString();
MessageBox.Show(s, "Table navigation information");
}

"berullus" wrote:
I have a datagrid in windows form bound to a dataset which has list of tables
. So, when the form is run I see + sign which could be expandable to range of
table names in the grid. How do I find out which table has been selected from
the list on the datagrid?

Nov 16 '05 #2

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

Similar topics

0
1618
by: | last post by:
Hi, I have an app that uses a typed dataset to persist user data. The dataset has a multiple tables with multiple table relations. The problem I am running into is that the user data is...
1
2224
by: Jay | last post by:
Hi All, My users are complaining about the page refreshing when they are selecting multiple rows in a datagrid. Has anyone tried to manage this using javascript? I tried smartnavigation but that...
1
1267
by: Jim Heavey | last post by:
Can I bind 3 controls to 3 different datatables? I have a datagrid with a databound column and 2 DropDownList. I set the datasource for the datagrid to Table1 and the DataBoundColumn to...
0
1279
by: John Bailey | last post by:
I have a dataset with multiple data tables. I need to bind this to a wizard interface, where each portion of the wizard udates the information in one of the datatables. I am using formviews in...
8
10361
by: Jason L James | last post by:
Hi all, does anyone know if I can create a dataview from multiple datatables. My dataset is constructed from four separate tables and then the relationships are added that link the tables...
2
1334
by: Thomas Beyerlein | last post by:
Is it possible to have different columns of a datagrid bound to different datatables? I am working on a project and the specks have suddenly changed. Now a item can have multiple reports/...
3
5130
by: Joe Kovac | last post by:
Hi! I have got a very complex database schema. For example a customer is constructed within a Customer table and a Person table. I have both tables as DataTables in a DataSet. When I want to...
0
972
by: Bauhaus | last post by:
I made a database (http://users.skynet.be/fc042048/Pizza.jpg) in Access which I want to use via typed datasets on my website. Problem is, if I i.e. want to edit the datatable "Pizza" in a gridview,...
0
1511
by: StefanPienaar | last post by:
Hi Guys Is there any way in c# (or vb.net) to extract a datatable of data from a dataset with multiple datatables which has relationships set up (containing combined data from the datatables)? ...
0
7125
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
7208
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...
1
6890
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...
0
7379
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...
0
5464
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,...
1
4915
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...
0
4593
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...
0
3095
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...
0
1423
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 ...

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.