How to change table name at runtime

  • Thread starter Thread starter Necqui Teja
  • Start date Start date
N

Necqui Teja

I'm using an .xsd file in my windows application using VS2005 Beta2.
Can I change the table name at runtime to another table name with the same
schema in the same database?
 
Hi Necqui,

Thanks for your post.

Can you tell me how you change the table name? Because when compiling the
project, VS.net actually invokes XSD.exe to compile generate the .xsd into
a DataSet.cs file. So if you just use XML classes to change the .xsd file
at runtime, it will not effect the resulting dataset schema at all, and of
no use. However, if you use DataTable.TableName to change it to another
name, it should be OK. Note: what you changed is the table name in the
DataTable, it has nothing to do with the database. I f you want to change
the database table name, you should use SQL statement to change it.Thanks

Hope this helps.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
Hi Necqui,

Does my reply make sense to you? Please feel free to tell me, thanks

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
Back
Top