Darren Shaffer
The first thing I would do is make sure your instance of SQL Server is configured to accept connections.
Run the SQL Server Configuration Manager (Start->Microsoft SQL Server 2005->Configuration Tools->SQL Server Configuration Manager) and do two things:
1. make sure you understand the exact name of the SQL Server Instance you have installed. In your connection string, you are using MYSERVER and if there is more than one instance of SQL Server -or- you installed with a named instance, MYSERVER as the server name will not work. Again, I encourage you to use the IP address versus the server name when connecting from a device.
2. Open the SQL Server 2005 Network Configuration node and select the instance of SQL Server you are interested in your mobile app connecting to. Go ahead and for now, Enable all of the protocols except for VIA.
Now go back to your mobile device and try to connect. It is confusing to me where your mobile app is running - in an earlier post you indicated it was a Pocket PC app which I assume you have deployed to an actual device connected to your dev machine via ActiveSync. In this last post, you're saying the application is running on your development PC. Maybe we'd better clarify that:
a. this is a Compact Framework 2.0 app
b. you are deploying it to an actual device and then trying to connect via ActiveSync or WiFi. You can open Pocket IE on your device and hit a URL on your dev machine (a great test of the network path between device and server).
c. if you are deploying to an emulator, you have verified that the network connectivity on the emulator is correctly setup to talk to your PC. This usually means enabling the LAN adapter, using Device Emulator Manager to cradle the device, and setting up a proxy on the emulator to allow your Work Network to get to your dev machine.
d. your dev machine running SQL Server has an IP address and network connection as you are testing. If it does not, you need to have the MS Loopback adapter installed and active.
-Darren