Datagrids or Table Input

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Daxthecon
    New Member
    • Jul 2008
    • 63

    Datagrids or Table Input

    I recently got a job where I would be working with vb and ASP.NET Well the ASP.NET expert got a new job not much after I just started. So I am forecfully learning ASP on my own.

    To the matter at hand. I want to create a page based off of an existing page that is built on tables. One particular table looks to just be a data grid. It's really good and I don't feel that I'll be able to do that well so early in the game. It's flawlessly put into the table and extends another row when the "Add another Row" button is clicked. What it's supposed to do is Auto Number the beginning Column and then you have to put in an item's name. Then a description of what it is. Then How many, then how much, and then the last column tells you the total of the item(s). After that if you need more you click "Add another Row" and it drops the table down for another row and you do it again. I know how to force the numbers to add and fit format so that the user knows how much and doen't have to hastle with decimals unless needed. I also know how to make them write to a database via VB. Where I am lost as is this...

    1. Do I create a datagrid and have it right to a SQL database OR do I use forms on a table to create a database table to write too(There is a followup page to be able to see what was put it for the Dept. Head to approve the purchse but I'll ask about that another time)?

    2 After I select that if it is forms on a table that create a table in a SQL db will this cause a ton of tables to be created everytime there is one created and will they be editable if so?

    3. If it is a data grid. How do I get it to show and how do I get it to become usuable for the page to and read from including the use being able to see the grid(as of right now it doesn't want to show and I have spent 2 days on it. I feel like it was time to seek help)?

    4. Or am I doing it wrong. Which is completely possible as I am borderline beginner with ASP.NET?

    Need some guidance guys. Would appreciate the help. If there is anymore clarification needed please feel free to email me via my profile. :-)
  • DrBunchman
    Recognized Expert Contributor
    • Jan 2008
    • 979

    #2
    Hi Daxthecon,

    So you want to display a table based on some query to your database and be able to add new rows to it. Have I understood you correctly?

    The DataGrid control will certainly be the easiest way to implement this - how far have you got? Have you checked out any tutorials on using a DataGrid? This one by Scott Mitchell is excellent.

    I suggest you go through that from the beginning to get a good understanding of how the control works and come back here with any questions you might have. Some examples of your code would be useful when doing so.

    Hope this helps,

    Dr B

    Comment

    • Daxthecon
      New Member
      • Jul 2008
      • 63

      #3
      Originally posted by DrBunchman
      Hi Daxthecon,

      So you want to display a table based on some query to your database and be able to add new rows to it. Have I understood you correctly?

      The DataGrid control will certainly be the easiest way to implement this - how far have you got? Have you checked out any tutorials on using a DataGrid? This one by Scott Mitchell is excellent.

      I suggest you go through that from the beginning to get a good understanding of how the control works and come back here with any questions you might have. Some examples of your code would be useful when doing so.

      Hope this helps,

      Dr B

      Hey Thanks for a reply. I was beginning to think I'd never get one. But I will be sure to check them out. I have no issue with coding at the moment as it's just trying to make it look right so I know where everything is going what it should be doing. That way I can finally go to code without worring I'll have to add stuff later. I will check out the link and if you have any more links I would certainly be VERY interested in seeing them.

      Comment

      Working...