Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
ASP.NET 2.0 Basics If you are new to ASP or ASP.NET programming with version 2.0, this is the forum to begin asking questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 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
  #1 (permalink)  
Old September 30th, 2006, 11:31 PM
Registered User
 
Join Date: Sep 2006
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Displaying data in Datagrid

I'm trying to display data from a table in a gridview but instead of showing the 'ID' fields from this table(Table 'A'), I want to show related fields of these ID fileds from other tables. For example if I'm displaying the Vendor 'ID' from Table 'A' it doesn't really mean anything to anyone, so I want to show the Vendor name from the Vendor file whose key value is the Vendor ID field in the datagrid. Is this possible?

  #2 (permalink)  
Old October 2nd, 2006, 06:24 AM
Friend of Wrox
Points: 3,060, Level: 23
Points: 3,060, Level: 23 Points: 3,060, Level: 23 Points: 3,060, Level: 23
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Sep 2005
Location: , , .
Posts: 812
Thanks: 1
Thanked 53 Times in 49 Posts
Default

Use Join in your query to get the required fields and populate it in the GridView.

You can use Views or StoredProcedures to store the Join or you can use the Query directly as the SQLDataSource

http://www.vbadud.blogspot.com
  #3 (permalink)  
Old October 3rd, 2006, 10:00 AM
Registered User
 
Join Date: Oct 2006
Location: New Delhi, , .
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default

just hide the coloumn which consists the datafield "ID"........

Rishi
  #4 (permalink)  
Old October 6th, 2006, 11:12 PM
Authorized User
 
Join Date: May 2006
Location: New Delhi, Delhi, India.
Posts: 39
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes ,It is possible.
You can show custamized datagrid.

You can get full detail at

http://apnasaathi.blogspot.com/2006/09/datagrid.html

rajkumar sharma


Similar Threads
Thread Thread Starter Forum Replies Last Post
Error in displaying datagrid lamort ASP.NET 1.0 and 1.1 Basics 0 December 1st, 2006 01:02 PM
Displaying 2 datatables in 1 datagrid muskaanbajaj Classic ASP Databases 5 May 19th, 2005 11:36 AM
displaying data in datagrid from Access shazaduh Access 3 April 6th, 2005 12:26 AM





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