Does a Table Belong to a DataSet


Author
Message
Terry Bottorff
Terry Bottorff
Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)Advanced StrataFrame User (770 reputation)
Group: Forum Members
Posts: 448, Visits: 12K
Dim ds2 As New DataSet
  
ds2.Tables.Add(MyBO.CurrentDataTable)

I use the above statements in conjunction with XrtraReports to print one of my reports. I run the same code again and MyBO.CurrentdataTable may be the same or it may be a different table (This depends on User Selection). If it is a different table the above code works again but if it is the same table I get an error stating the currenttable already belongs to the dataset. Is there some way around this?
I have tried using ds2=nothing but that does not help.
Is there a way to find out if ds2 exists? 
Is there a way to find out if MyBO.currentdatatable belongs to ds2?
Is there a way to remove all the tables in ds2?
I know I can use ds2.tables.remove(MyBo.CurrentDatatable).
Thanks in Advance.

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search