使用C#.net保护Access数据库 [英] Protect Access Database in C#.net
问题描述
大家好
我用C#.net编写3层项目,我的数据库访问2010
我想保护Access数据库具有访问级别(显示,写入,更改)。我在网上搜索,并没有找到这个主题的好解决方案。
例如:
解决方案之一是在访问数据库上设置密码但我可以用程序删除密码或禁用访问数据库这种解决方案并不好,因为这很容易受到影响。
有最好的解决方案吗? ,或者将数据库更改为SQL服务器
非常感谢。
var dbe = new DBEngine();
var databaseFile = @ C:\\ \\Users\x339\Documents\Test.accdb跨度>;
var password = abc123跨度>;
数据库db = dbe.OpenDatabase(databaseFile,False,False, string .Format( MS Access; PWD = {0},密码));
http://www.java2s.com/Tutorial/CSharp/0560__ADO.Net/ConnectingtoaPasswordProtectedMicrosoftAccessDatabase.htm [ ^ ]
Hi all
I write 3 layer project in C#.net and my database is access 2010
I want to protect Access database With access level (show,write,change). and I very search in web and don't find good solution for this topic.
for example :
the one of solution is set password on the access database but I can remove password with program or disable access database that this solution don't good way because this is vulnerable.
Is there a best solution ? , or change database to SQL server
thanks a lot.
var dbe = new DBEngine(); var databaseFile = @"C:\Users\x339\Documents\Test.accdb"; var password = "abc123"; Database db = dbe.OpenDatabase(databaseFile, False, False, string.Format("MS Access;PWD={0}", password));
http://www.java2s.com/Tutorial/CSharp/0560__ADO.Net/ConnectingtoaPasswordProtectedMicrosoftAccessDatabase.htm[^]
这篇关于使用C#.net保护Access数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!