Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
See more: C# ASP.NET SQL-Server
            Status_1	Status_2	Status_3	Status_4	Status_5	Status_6
Status_1								
Status_2							
Status_4									
Status_6									
i want to create a dynamic datagrid as above. All status are in table in my database.
Status value will be my column in datagrid and first column of the grid as above.
Checkbox will appear on each cell of grid where user can check/uncheck value
and save in database.
can anyone help me how to design my datagrid. Thanks in advance.
Posted 3-Apr-13 23:09pm
Edited 4-Apr-13 20:45pm
Maciej Los at 4-Apr-13 8:20am
What have you done till now?
Chinmaya_Champatiray at 5-Apr-13 4:05am
As per my understanding, you need to create DataSource dynamically based on your requirement and bind that to the grid.
V. at 5-Apr-13 4:10am
What did you do? If you're stuck with a big problem, try breaking it down into smaller problems:
1: Can you build a grid from code? Create a prototype solution and start with hardcoded values, then strip as much as you can to dynamic values
2: Can you read data from a database? Can you write to it? Create a prototype solution and start with selecting, updating and deleting values.
3: before jumping to merging 1 and 2. THINK. What does it need to do and what will it need to do next year, the year after that? What data needs to be in the database, what types and how will I structure it ? From the database design start coding the access to it (step 2). Once you have the data, create a "grid builder" that handles the translation from objects to a grid (step 1). Then go backward again: grid to object to database.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Advertise | Privacy | Mobile
Web03 | 2.8.150326.1 | Last Updated 5 Apr 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100