ASP, Vista and SQL-2005

Miscellaneous Forums/General Discussion/ASP, Vista and SQL-2005

Hello.

I've just bought a laptop with vista home premium, set up IIS, installed SQL 2005 and tried to connect via ASP to the database.

The way I've worked previously is something like:
set cn = Server.CreateObject("ADODB.Connection")
cn.ConnectionString = "blahblahblah"
cn.open
cn.close


No bleedin' joy there, let me tell you.

I've tried all manner of connection strings and googled trying to find the solution but to no avail - and I'm pretty convinced that it's my connection string that's the problem.

Can anyone help here?

The server (should) be 'jes-pc'
The database is 'dissertation'
Username is 'jes'

If anyone can tell me what the correct connection string is I'd be grateful.

Goodbye.

You can always try Microsoft Application Blocks.
They support sqlserver and other fine stuff.

Do a Google search for Microsoft Application Blocks

user id=jes;data source="jes-pc";persist security info=False;initial catalog=dissertation;password=

You can also change jes-pc to (local) and if you have a password, put it at the end there without quotes.

There's no point trying application blocks until you know the connection / application will work.

Do you have ASP error messages turned on in IIS? (Right-click site, Properties, Configuration)

And has the site got 'Execute permission' set to 'Scripts only'? Do other ASP statements work ok (e.g. response.write "Hello")

Hello.

I'm pretty sure everything is set up ok, it's just there's such a difference between sql2000 & IIS6(5?) on XP and sql2005 & IIS7 on Vista. Especially without any documentation/training/tutorials/etc. Lots of books on order, however.

I've had two errors so far, one about wrong connection string format and one about user not being set up for trusted connection. I'm glad MS have made things easier in this new version ;o)

I'll try Why0Why's suggestion and see how it goes - in work at the moment, so can't try.

Thanks for the suggestions.

Goodbye.