Click here to Skip to main content
15,895,256 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
C#
i am trying to build application for convert sql database  to pdf 
i get server name in combo-box but i can not get database name from selected server name  .


What I have tried:

i try to connection like this String cnnStr = "Data Source = ['"+ cmbserver.SelectedItem +"']; Initial Catalog = Northwind; Integrated Security = SSPI";
Posted
Updated 7-Jun-16 1:18am
Comments
Simon_Whale 7-Jun-16 9:59am    
Can I ask why your are trying to convert a database to a PDF?
Kumbhani Bhavesh 7-Jun-16 11:39am    
ya i am freelancer and it is my job.
Simon_Whale 8-Jun-16 4:18am    
The reason I asked is that if your a looking at point all table definitions into the PDF, then I would also have a look at SQL SMO more than just using SQL Statements.
Kumbhani Bhavesh 8-Jun-16 7:54am    
what is solution for this?

1 solution

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