473,729 Members | 2,371 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

master / detail datagrid...

Hi all

I'm almost braindead on this one, but how can I create a master/detail
datagrid
in this format :

CatA
subcatA1
subcatA2
subcatA3
CatB
subcatB1

etc

I've been studying this datagrid for hours now and I can't figure it out.
The main idea is to have the CatA & CatB having a full colspan, and having
those subcats as normal datagrid/datalist rows...
Lastly, I need to be able to Page the main CatA, etc.

I tried nesting, but I don't get any wiser from that.
Would filling my dataset with 2 tables from a stored proc work the best way
for this ?
This is because the main Categories and the Subcategories are taken from two
related tables in my database.
Thanks in advance


Nov 18 '05 #1
6 1793
well you said you tried nesting !! i think that is the most appropriate
solution for Parent Child relations.

one of the columns there will be another datarid..

say dgParent has a template column which is a datagrid. dgChild.
onDataBound event... get the categoryid.. using that either fetch or filter
correct records for child and bind it to that row's dgChild.

i have done this a lot of times... infact i had a Parent >> Child >> Child
relationship and after a bit of tweaking it all worked :)

--

Regards,

Hermit Dave
(http://hdave.blogspot.com)
"Beren" <be***@angband. me> wrote in message
news:vU******** *************** @phobos.telenet-ops.be...
Hi all

I'm almost braindead on this one, but how can I create a master/detail
datagrid
in this format :

CatA
subcatA1
subcatA2
subcatA3
CatB
subcatB1

etc

I've been studying this datagrid for hours now and I can't figure it out.
The main idea is to have the CatA & CatB having a full colspan, and having
those subcats as normal datagrid/datalist rows...
Lastly, I need to be able to Page the main CatA, etc.

I tried nesting, but I don't get any wiser from that.
Would filling my dataset with 2 tables from a stored proc work the best way for this ?
This is because the main Categories and the Subcategories are taken from two related tables in my database.
Thanks in advance

Nov 18 '05 #2
Nesting one "repeating control" such as a Datagrid or Repeater within
another is the way to go. There are several ways you can do it, and there's
a bunch of examples with a [view source] link at:
http://www.daveandal.net/books/6744/samples.aspx
"Beren" <be***@angband. me> wrote in message
news:vU******** *************** @phobos.telenet-ops.be...
Hi all

I'm almost braindead on this one, but how can I create a master/detail
datagrid
in this format :

CatA
subcatA1
subcatA2
subcatA3
CatB
subcatB1

etc

I've been studying this datagrid for hours now and I can't figure it out.
The main idea is to have the CatA & CatB having a full colspan, and having
those subcats as normal datagrid/datalist rows...
Lastly, I need to be able to Page the main CatA, etc.

I tried nesting, but I don't get any wiser from that.
Would filling my dataset with 2 tables from a stored proc work the best way for this ?
This is because the main Categories and the Subcategories are taken from two related tables in my database.
Thanks in advance

Nov 18 '05 #3
Thanks for the advice guys. Another step in the right direction :)
Nov 18 '05 #4
Thanks for pointing that out Alex.
Having access to "ASP.NET 1.1 Insider Solutions" is a real treat.

If you are feeling up to a bit of controversy I would ask you if you
were interested in discussing how XML namespaces may or may not
result in copyright issues associated with their use.

The highbrows building the markup languages do not want to speak
about this but since you are a working man with a job I figure you
probably have had reason to formulate an opinion or to have been
involved with publishers who have become aware of the considerations
involved.

--
<%= Clinton Gallagher, "Twice the Results -- Half the Cost"
Architectural & e-Business Consulting -- Software Development
NET cs*********@REM OVETHISTEXTmetr omilwaukee.com
URL http://www.metromilwaukee.com/clintongallagher/


"Alex Homer" <al**@stonebroo m.com> wrote in message
news:OQ******** ******@tk2msftn gp13.phx.gbl...
Nesting one "repeating control" such as a Datagrid or Repeater within
another is the way to go. There are several ways you can do it, and there's a bunch of examples with a [view source] link at:
http://www.daveandal.net/books/6744/samples.aspx
"Beren" <be***@angband. me> wrote in message
news:vU******** *************** @phobos.telenet-ops.be...
Hi all

I'm almost braindead on this one, but how can I create a master/detail
datagrid
in this format :

CatA
subcatA1
subcatA2
subcatA3
CatB
subcatB1

etc

I've been studying this datagrid for hours now and I can't figure it out. The main idea is to have the CatA & CatB having a full colspan, and having those subcats as normal datagrid/datalist rows...
Lastly, I need to be able to Page the main CatA, etc.

I tried nesting, but I don't get any wiser from that.
Would filling my dataset with 2 tables from a stored proc work the best

way
for this ?
This is because the main Categories and the Subcategories are taken from

two
related tables in my database.
Thanks in advance


Nov 18 '05 #5
Interesting - I have to say I haven't considered this. You mean something
like MS might copyright "asp" as a namespace prefix for use with ASP.NET
controls? Can't say that I can see that coming, but I guess the past
performance of the US patent office might cause one to wonder...

As to a namespace itself (the URI bit) I always use my own domain name. But
I guess there's nothing to stop someone patenting a domain name they don't
own if it's not already copyrighted. Have you come up with a particular
example, or can you expose a little more of your thinking behind the issue?
I haven't heard any mention from publishers - we have enough problems
getting permission to shown screenshots of non-MS software!
"clintonG" <cs*********@RE MOVETHISTEXTmet romilwaukee.com > wrote in message
news:eb******** *****@TK2MSFTNG P15.phx.gbl...
Thanks for pointing that out Alex.
Having access to "ASP.NET 1.1 Insider Solutions" is a real treat.

If you are feeling up to a bit of controversy I would ask you if you
were interested in discussing how XML namespaces may or may not
result in copyright issues associated with their use.

The highbrows building the markup languages do not want to speak
about this but since you are a working man with a job I figure you
probably have had reason to formulate an opinion or to have been
involved with publishers who have become aware of the considerations
involved.

--
<%= Clinton Gallagher, "Twice the Results -- Half the Cost"
Architectural & e-Business Consulting -- Software Development
NET cs*********@REM OVETHISTEXTmetr omilwaukee.com
URL http://www.metromilwaukee.com/clintongallagher/


"Alex Homer" <al**@stonebroo m.com> wrote in message
news:OQ******** ******@tk2msftn gp13.phx.gbl...
Nesting one "repeating control" such as a Datagrid or Repeater within
another is the way to go. There are several ways you can do it, and

there's
a bunch of examples with a [view source] link at:
http://www.daveandal.net/books/6744/samples.aspx
"Beren" <be***@angband. me> wrote in message
news:vU******** *************** @phobos.telenet-ops.be...
Hi all

I'm almost braindead on this one, but how can I create a master/detail
datagrid
in this format :

CatA
subcatA1
subcatA2
subcatA3
CatB
subcatB1

etc

I've been studying this datagrid for hours now and I can't figure it out. The main idea is to have the CatA & CatB having a full colspan, and having those subcats as normal datagrid/datalist rows...
Lastly, I need to be able to Page the main CatA, etc.

I tried nesting, but I don't get any wiser from that.
Would filling my dataset with 2 tables from a stored proc work the
best way
for this ?
This is because the main Categories and the Subcategories are taken
from two
related tables in my database.
Thanks in advance



Nov 18 '05 #6
Aha. Curious huh? :-) Well thank you for replying Alex.
Its good to converse with you once again.

When viewing the source of any page generated by Macromedia's
tools you will see much of the source prefixed with MM_ which
Macromedia uses to 'brand' their source code noting that doing
so is secondary to other processing objectives but is a form
of branding regardless.

Macromedia uses their prefix in the exact same way an XML
Namespace is intended to be used: to resolve ambiguity and
allow two or more instances of similar code to coexist in the
same document.

I really don't know if Macromedia has used the law to ensure
the use of their prefix remains unique to them and them alone.
If I were Macromedia I would sure try to do so.

I have been working on an XML Web Services initiative and have
been using the root element and specific prefixed namespaces to
brand the initiative in the same manner as Macromedia uses their
prefix. It was Macromedia from whom I intuitively derived the idea
to do so in the first place. There is apparently nothing however that
prevents others from also doing so while using the same root element
and prefixed notation as I. Thus, a malicious or envious competitor
could compromise or destroy the viability of my services unless my
works can be protected.

I happen to be much more adept at trend analysis than software
development and I can virtually guarantee that this issue will become
a matter of contention with regard to trademark, copyright, and/or
patent law as the use of XML and web services continue to evolve
as the defacto text and document processing methodology which I
believe you know and I believe you will agree are fundamental to
a Service Oriented Architecture that must by its nature function
semantically for both man and machine.

Registering a copyright in the U.S. is dirt cheap which makes
it the perfect type of protection for small potatos. A regsistration
is required to enter the courts to litigate the use of the property.
It is defending the property in court where the larger costs accrue.
As a mater of fact, most infringers stop infringing after receiving
a 'cease and desist' letter from one's lawyer as it is widely known
that penalties for copyright infringment are quite substantial if the
infringer proceeds to court and loses.

A patent on the other hand can be obtained but unlike the paltry
$30 or so for copyright registration a patent registration can easily
cost more than $5,000 making the acquisition of a patent a costly
and non-trivial process.

Despite the recognized problems we have with an archaic U.S.
government that continues to approve the assingment of 'business
process' patents for processes that are obvious as implemented
I think we could all agree that we all have a right to at least
preserve and protect our work by name.

We may all be what those of us from across the pond call
"sh!t out of luck" though. After weeks and weeks of calling around
I finally found a lawyer who specializes in intellectual property,
has a degree in electrical engineering, and claimed to have had
actually developed some time ago allowing me to consider
him credibly conversant.

The lawyer explained that U.S. copyright applies to the 'entire'
expression. That is, the entire XML file. A copyright could not
apply to just the namespaces and their respective prefixed notation.
He stated the courts would consider XML and any fragment thereof
to be a 'file structure' and used an example to explain.

It seems file structures can not be copyrighted which is why a word
processing application can be made to open and read the files of a
word processor from a competing vendor.

So, regardless of the lawyer's opinions I may be in denial as I
continue to argue that XML is analogous to musical composition
and an XML Namespace is the equivalent of a short musical
passage such as a jingle. If it is a fact that composers who write
jingles can have their work copyrighted -- which it is -- I see no
reason why the copyright office and the courts should disallow
copyright for XML Namespaces an avenue of consideration
I am compelled to continue to persue until such time as they
grant me a copyright or they lock me up for trying.

By the way, in case you are not familiar with the jargon, a 'jingle'
is a short musical passage that is played as background music
during a radio or television advertisement.

Sing along with me now...

"You get more for your money when you eat at Bunny's
so drop on in for a bite at Bunny's greasy spoon."

Did you 'hear' that melody? :-)

--
<%= Clinton Gallagher, "Twice the Results -- Half the Cost"
Architectural & e-Business Consulting -- Software Development
NET cs*********@REM OVETHISTEXTmetr omilwaukee.com
URL http://www.metromilwaukee.com/clintongallagher/

"Alex Homer" <al**@stonebroo m.com> wrote in message
news:ey******** ********@TK2MSF TNGP15.phx.gbl. ..
Interesting - I have to say I haven't considered this. You mean something
like MS might copyright "asp" as a namespace prefix for use with ASP.NET
controls? Can't say that I can see that coming, but I guess the past
performance of the US patent office might cause one to wonder...

As to a namespace itself (the URI bit) I always use my own domain name. But I guess there's nothing to stop someone patenting a domain name they don't
own if it's not already copyrighted. Have you come up with a particular
example, or can you expose a little more of your thinking behind the issue? I haven't heard any mention from publishers - we have enough problems
getting permission to shown screenshots of non-MS software!
"clintonG" <cs*********@RE MOVETHISTEXTmet romilwaukee.com > wrote in message
news:eb******** *****@TK2MSFTNG P15.phx.gbl...
Thanks for pointing that out Alex.
Having access to "ASP.NET 1.1 Insider Solutions" is a real treat.

If you are feeling up to a bit of controversy I would ask you if you
were interested in discussing how XML namespaces may or may not
result in copyright issues associated with their use.

The highbrows building the markup languages do not want to speak
about this but since you are a working man with a job I figure you
probably have had reason to formulate an opinion or to have been
involved with publishers who have become aware of the considerations
involved.

--
<%= Clinton Gallagher, "Twice the Results -- Half the Cost"
Architectural & e-Business Consulting -- Software Development
NET cs*********@REM OVETHISTEXTmetr omilwaukee.com
URL http://www.metromilwaukee.com/clintongallagher/


"Alex Homer" <al**@stonebroo m.com> wrote in message
news:OQ******** ******@tk2msftn gp13.phx.gbl...
Nesting one "repeating control" such as a Datagrid or Repeater within
another is the way to go. There are several ways you can do it, and

there's
a bunch of examples with a [view source] link at:
http://www.daveandal.net/books/6744/samples.aspx
"Beren" <be***@angband. me> wrote in message
news:vU******** *************** @phobos.telenet-ops.be...
> Hi all
>
> I'm almost braindead on this one, but how can I create a master/detail > datagrid
> in this format :
>
> CatA
> subcatA1
> subcatA2
> subcatA3
> CatB
> subcatB1
>
> etc
>
> I've been studying this datagrid for hours now and I can't figure it

out.
> The main idea is to have the CatA & CatB having a full colspan, and

having
> those subcats as normal datagrid/datalist rows...
> Lastly, I need to be able to Page the main CatA, etc.
>
> I tried nesting, but I don't get any wiser from that.
> Would filling my dataset with 2 tables from a stored proc work the best way
> for this ?
> This is because the main Categories and the Subcategories are taken from two
> related tables in my database.
>
>
> Thanks in advance
>
>
>
>



Nov 18 '05 #7

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

Similar topics

0
1165
by: Hari | last post by:
I have got a master detail datagrid in my application. When i select a row in a master table if there are no rows in detail table for the selected row in the master table then i want to give a message that there are no rows in the detail table ? How can i do that? Thank you
1
459
by: Juan | last post by:
I built a form that displays a master-detail relation ship, now i need to add a column to the datagrid displaying the master data, this column corresponds to the text name of a column stored in the master table as an integer (the foreign key, i need to display the text name of the foreign key stored in the third table). Do i have to create another datatable in the dataset im using that includes all the information I need? Change the Sql...
8
2051
by: Christopher Weaver | last post by:
I'm having the hardest time doing the simplest thing. I have a DataGrid bound to a table in a master detail DataRelation within a DataSet relTaskActivities = new DataRelation("TaskActivities", parentCol, childCol); dsTaskActivities.Relations.Add(relTaskActivities); dgActivity.SetDataBinding(dsTaskActivities, "Tasks.TaskActivities"); This works fine. I have a properly behaving master detail relationship.
0
1066
by: Serge Poirier | last post by:
Good Day Folks, I found the following code here on MSDN illustrating master/detail. You can see the original at the following URL. http://msdn.microsoft.com/library/default.asp? url=/library/en- us/cpref/html/frlrfsystemdatadatatableclasstopic.asp
2
1466
by: Marcel | last post by:
Hi, I'm new to VS and ASP.NET and have a question about master/detail datagrids. I have a master datagrid filled with data via a component that contains a SQL adapter. Now I would like to fill a detail datagrid (which will contain a number of detail records) based on the selected master. Is it possible to
2
423
by: ruca | last post by:
Hi, I have a master and a detail datagrid. I put detail grid showing insise of a column of master grid. The problem is that it's not what I really want. What I really want would be that the detail grid appears between rows of master grid, i.e., when I select one record in master grid that detail grid appears between the selected row and next row. I know that the reason why my detail grid is show in one master column it's because I...
4
1453
by: M | last post by:
Hy, I would like to create a master /detail datagrid, that is a datagrid that (when I click on an item) shows some other item's details expanding the rows under the selected grid Can someone help me with this? Thanks!
7
1519
by: erniej | last post by:
as per instructions in the walkthrough, I have managed to create a master/detail relationship between two datagrids. However I have a requirement to apply this to three datagrids and the third datagrid does not seem to reflect the selected row on the second datagrid using this method. The relevant lines of code are as follows. ' binding on master table dgTables.SetDataBinding(CurrentViewDS,"ALL_TABLES")
1
1528
by: Gary200 | last post by:
Hello All, I bind two datagrids in a master-detail relationship successfully. What I want is to set allowNew and allowDelete disabled in both datagrid using dataview. The code like this: Dim masterGrid As DataGrid Dim detailGrid As DataGrid
1
1450
by: Shalini Bhalla | last post by:
i have 2 tables one is master and another is detail having Ins-no common and iwant that when master recordset is moved then detail recordset pointershould filter detail records correspondint to master records datagrid .
0
8921
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8763
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
9284
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9202
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
9148
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...
1
6722
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6022
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4796
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3238
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

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.