Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB.NET 1.0 > VB.NET 2002/2003 Basics
|
VB.NET 2002/2003 Basics For coders who are new to Visual Basic, working in .NET versions 2002 or 2003 (1.0 and 1.1).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB.NET 2002/2003 Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 15th, 2003, 02:52 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 428
Thanks: 57
Thanked 2 Times in 2 Posts
Default Displaying Xref-Tables in Datagrid in VB.NET

I have two tables in different SQL Server databases I wish to cross-reference. I want to display all the fields from the first table along with the cross-referenced field from the second table on ONE LINE in a datagrid:

Table 1 record:
Field1 Code1

Table 2 record:
Code1 Value1

Datagrid results after join:
Field1 Value1

I've got the tables in the same dataset and defined a relationship between the tables. Now, how do I get the datagrid to display a field from table 1 and a field from table 2 on the same line in the datagrid (I do not think the master/detail binding applies in this instance, because it's a one-to-one relationship)? It feels like I need to create a view of some sort inside the dataset, but I don't know how to do so. Clues, anyone?





Similar Threads
Thread Thread Starter Forum Replies Last Post
loop through tables inside .mdb file using VB.NET remya1000 General .NET 3 September 24th, 2007 12:45 PM
Displaying Image in RSS Feed with Vb.Net [email protected] VB.NET 0 July 9th, 2007 09:09 PM
Tables migration from Access to SQL Server-VB.NET ayazhoda VB.NET 2002/2003 Basics 2 May 3rd, 2007 05:59 AM
vb.net asp.net DataGrid krantips VS.NET 2002/2003 0 June 28th, 2006 01:22 AM
DataGrid in VB.Net soccers_guy10 Pro VB.NET 2002/2003 0 September 8th, 2003 11:47 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.