Results 1 to 3 of 3

Thread: Copy one datatable to subclass of a datatable...

  1. #1

    Thread Starter
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091

    Copy one datatable to subclass of a datatable...

    Okay, so I have a generic DataTable object coming from somewhere, and a class that inherits from DataTable. What is the quickest, easiest, most generic way to copy the rows and columns from the DataTable object to the subclass?

    Thank you for your pity.

    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  2. #2

    Thread Starter
    The Devil crptcblade's Avatar
    Join Date
    Aug 2000
    Location
    Quetzalshacatenango
    Posts
    9,091
    *slurp*

    Basically, I know I can't downcast, and apparently there is no way (as I see it) to copy the column info from one to the other.

    What gives?
    Laugh, and the world laughs with you. Cry, and you just water down your vodka.


    Take credit, not responsibility

  3. #3
    Lively Member
    Join Date
    Apr 2004
    Posts
    95
    Wait, if you have created a custom class that inherits from a datatable, why would you ever need to use a regular datatable at any point in your program? Can't you use the custom one you created? then you wouldn't have to move rows or columns around.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width