none
How to generate table with tableAdapter RRS feed

  • Question

  • Hi, I have BillingDataSet with a table 'Diagnosis'.

     

    I have a form and I want to open a 'copy' of 'Diagnosis' in it's code using:

    BillingDataSet.DiagnosisDataTable myDiagnosisTbl;

     

    myDiagnosisTbl =

    this.diagnosisTableAdapter.GetData();

    I get 'invalid token'  "(" at GetData. I just can't see what the problem could be. Can anyone see the (probably obvious... <sigh>) mistake?

    Thanks to all.


    JohnCFowler
    • Moved by KJian_ Thursday, September 29, 2011 8:14 AM (From:SQL Server Data Access)
    Tuesday, September 27, 2011 4:56 AM

All replies

  • Hi johnof,

    I am not sure that this thread is in the correct forum , i will search and move this thread towards the most suitable forum.While waiting for a new "home" for your thread ( which is not related to SQl Server Data Access , but more DataSets or Visual Studio tools ), i give you a link about TableAdapter ( for .Net Framework 4.0 )

    http://msdn.microsoft.com/en-us/library/bz9tthwx.aspx

    invalid token is usually caused by mismatch for (,{,[ or ; like explained in this link :

    http://stackoverflow.com/questions/397019/invalid-token-while-in-class-struct-or-interface-member-declaration-in-very-s

    Please, could you post your more developped code ? Please, use the Insert code block and set the language to VC# . After having done search, it's more surely a problem of syntax VC# ( so a VC# forum )

    Could you explain if you have used the management datasource/datasets from Visual Studio ( Which edition and version ) to generate automatically strong typed datasets/datatables ? ( i prefer to rely on my own code that i have to write rather than to use automatically generated code which is impossible to modify in a simple way , it is said that i should gain time but upto now  i gained only headaches to understand how to introduice modifications , my code is running more quicklier and i understand it )

    Have a nice day

     


    Mark Post as helpful if it provides any help.Otherwise,leave it as it is.
    Tuesday, September 27, 2011 8:43 PM
  •  Hi johnof,

    I agree with Papy.  Could you please share us with more sample codes and explain your detailed scenario?  I will do the best to help.   If you have any demo project, please feel free to send it to me via misun@microsoft.com

    Have a nice weekend!

    Thanks


    Michael Sun [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Friday, September 30, 2011 1:29 AM
    Moderator
  • Hi johnof,

    Could you please let me know how's the problem now?   If you need any further assistance, please feel free to let me know.

    Have a nice day!

    Thanks


    Michael Sun [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Monday, October 10, 2011 2:16 AM
    Moderator