connection string path dynamically in vb.net -


i made desktop application in vb.net. give reference path of connection string through .udl. problem when place folder in location path string not change , hence results in error. kindly suggest. connection details follows

_connstr = system.io.file.readalltext("c:\users\avt\desktop\new folder\a.udl") con = new oledbconnection(_connstr) 

first of all, why using text file save connection string ?

go project properties -> settings , create connectionstring setting save connection string. that'll solve problem. using text file connectionstring not valid way.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

c# - Retrieve google contact -

javascript - How to insert selected radio button value into table cell -