Click here to Skip to main content
15,894,180 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi Peeps

I created a project and published it with click once, but got errors because sql express was not installed on the client's pc.

I'm calling the sqlexpress.exe file to install when my form loads - it goes on with the installation and finishes successfully but when I login to my program I get errors, when I go into the folder where the exe file is and I install from there my program works...

Is there an easier way of doing this or am I doing something wrong?

Here is my code :
C#
Process myProcess = new Process();
myProcess.StartInfo.FileName = @"C:\Folder\sqlexpr32.exe";
myProcess.StartInfo.Arguments = "start /wait " + vlNew_SQLExpressFilePath.ToString() + " /qn username=test companyname=testany addlocal=ALL  disablenetworkprotocols=0 instancename=MyInstance SECURITYMODE=SQL SAPWD=test123";
myProcess.StartInfo.UseShellExecute = false;
myProcess.Start();

Thanks in advance
Posted
Updated 11-Aug-10 3:42am
v2
Comments
Sandeep Mewara 11-Aug-10 9:42am    
Use PRE tags to format code part. It makes the question readable.
kornakar 12-Aug-10 1:17am    
Why don't you install the SQL server on the same server where the ClickOnce is installed?
lourensG 12-Aug-10 3:16am    
How can I install sql when they install the app?

1 solution

you might have not created datasets properly, configure your database adapter and bind it properly.Hope it works.

:-D prasad
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900