Results 1 to 5 of 5

Thread: how to update a table using dataset

  1. #1
    Junior Member
    Join Date
    Sep 2007
    Answers
    7

    Exclamation please read this

    I am Currently working on a software which open any Database File (Access,SqlServer,Excel etc) and display any of its Table in a DataGrid View
    If you Edit the table i want changes to be made into the database Table
    but I am unable to do so. I know that i have to use Update Method of DataAdapter but I dont know how to configure InsertCommand ,UpdateCommand Properties of DataAdapter .
    Suggest me a way or give a idea ................................................

    Thanks in Advance for Reading.......................

    Last edited by deepakk87; 11-04-2007 at 01:27 AM.

  2. #2
    Junior Member
    Join Date
    Feb 2006
    Answers
    1

    Re: please read this

    Quote Originally Posted by deepakk87 View Post
    I am Currently working on a software which open any Database File (Access,SqlServer,Excel etc) and display any of its Table in a DataGrid View
    If you Edit the table i want changes to be made into the database Table
    but I am unable to do so. I know that i have to use Update Method of DataAdapter but I dont know how to configure InsertCommand ,UpdateCommand Properties of DataAdapter .
    Suggest me a way or give a idea ................................................

    Thanks in Advance for Reading.......................
    HIiiiiiiiiiiiiii


  3. #3
    Junior Member
    Join Date
    Dec 2007
    Answers
    5

    Cool Hi i have just joined so sorry for begin late :P

    Main concept : using the visual studio data environment to the fullest. Assumptions :
    1. you are able to connect to the database (sql,orcale or access)
    2. you are able to see the tables in server explorer
    solution elaborated : the visual studio 2005 environment has a wide range of features to make a good programmer very lazy . I will state these features and how to used them which will lead to the answer that you want to know. 1. The data environment in the menu data-> show datasource. When you see the datasource pane you will notice three icons in the top. Add datasource,edit datasource and refresh. In that click the add datasource. Then when you see the dialog. Follow the dialog and add the data source. And remember not to copy the database file in to the current directory. The application data is malformed. I think this is were you went wrong in your previous tries. 2.use the drag drop. When you completed the data source that is created in the data source pane then drag the table from the data source pane and then drop it in an empty form with no menu for safety reasons .. Hehe.... 3. Run the program press f5 and see what happens if you have followed what i have said it should probably work. i think that will give a solution to your problem if you have any doubt thread please.


  4. #4
    Junior Member
    Join Date
    Dec 2007
    Answers
    1

    Smile Re: please read this

    Ya Deepak
    U can do the upadation in the databsae using the adapter object.


  5. #5
    Junior Member
    Join Date
    Sep 2007
    Answers
    7

    Re: Hi i have just joined so sorry for begin late :P

    Thanks for replying but i have made it on my own. I use data provider factories for designing my software. It allows you to connect to any database server and allows you do many task. Although it is still in development I could send you a demo version. I have written around 2000 lines and still many more need to be written. I have redesigned the whole software twice. If you want a copy of my software mail me at deepakk87 @ gmail . com


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact