Link to home
Start Free TrialLog in
Avatar of sny23vpb
sny23vpb

asked on

SQL 2008 (10) Not Supported vb.net Commands

I have a vb.net app designed to automaticlly deploy table/stored procedure scripts to a designated SQL Server 2000 database  that worked great with SQL 2000 but now gives the following error message when trying to run on SQL Server 2008:

This SQL Server version (10 0) is not supported

The code is:

Imports Microsoft.SqlServer.Management.Smo

Dim server As New Microsoft.SqlServer.Management.Common.ServerConnection(connection)

Me.CurrentTask.Text = reader(0).ToString

strFileContents = My.Computer.FileSystem.ReadAllText(reader(0).ToString)
             
server.ExecuteNonQuery(strFileContents)

It gives the error on the line above at: server.ExecuteNonQuery(strFileContents)

I've tried to do searches; but haven't found any solution that seems to work - please let me know if I've overlooked the solution here.

Thanks for any help.

ASKER CERTIFIED SOLUTION
Avatar of ProjectChampion
ProjectChampion
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of sny23vpb
sny23vpb

ASKER

Thanks.  I'll try that and advise