doubletalkin3
Programmer
Hi,
I'm trying to create item headings on a contacts datagrid to group it by Department. For example -
Accounts
Person A - Phone Number - Email etc
Person B - Phone Number - Email etc
Person C - Phone Number - Email etc
Sales
Person A - Phone Number - Email etc
Person B - Phone Number - Email etc
Person C - Phone Number - Email etc
Looking around the internet, I've found lots of summary rows, which calculates totals, sub totals, and groupings by date and integers. I've also seen this done through a data repeater, but I would like the department name to be displayed in a row of the datagrid.
I've put the group by clause in the SQL statement.
I think the code would be put in the ItemDataBound function and determine when the department name changes - insert a summary row displaying the department name as text (As a lot of people here query the database directly, we store the department name in the contacts table, not the ID)
Any ideas what the ItemDataBound code would look like for a string? Thanks
I'm trying to create item headings on a contacts datagrid to group it by Department. For example -
Accounts
Person A - Phone Number - Email etc
Person B - Phone Number - Email etc
Person C - Phone Number - Email etc
Sales
Person A - Phone Number - Email etc
Person B - Phone Number - Email etc
Person C - Phone Number - Email etc
Looking around the internet, I've found lots of summary rows, which calculates totals, sub totals, and groupings by date and integers. I've also seen this done through a data repeater, but I would like the department name to be displayed in a row of the datagrid.
I've put the group by clause in the SQL statement.
I think the code would be put in the ItemDataBound function and determine when the department name changes - insert a summary row displaying the department name as text (As a lot of people here query the database directly, we store the department name in the contacts table, not the ID)
Any ideas what the ItemDataBound code would look like for a string? Thanks