Click here to Skip to main content
15,891,657 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi everyone.
there is a solution for encrypt connection string in this link.[^]
i,m trying to encrypt below connection, but error ocured:
XML
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<connectionStrings>
<add name="LoginDBConnectionString" connectionString="Provider=Microsoft.ACE.OLEDB.12.0;Data Source=|DataDirectory|\Database.accdb;Jet OLEDB:Database Password=******"/>
</connectionStrings>
</configuration>

what's the problem?
thanks.
Posted
Updated 6-Sep-15 2:50am
v2
Comments
Wendelius 6-Sep-15 5:40am    
And what is the error you get?

Few probable causes:
- the |DataDirectory| isn't replaced with an actual directory name. Try using a fixed directory
- you have extra space after Microsoft.ACE.OLEDB.12. before 0
 
Share this answer
 
thanks.
I'm so sorry about spaces. this is my fault. but about |DataDirectory|, I'm heared it is reserved statement and refer to app.path?
isn't it?
 
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