Click here to Skip to main content
15,908,166 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
in my project i am using text files as database (windows application) after setup project
c:programfiles/projectname/bin/debug/in that text files are visible to user
for data protection text files are not show to client

is there any way to textfile convert into .dll file
can any one help me.
Posted
Comments
ZurdoDev 21-Nov-13 7:44am    
I'm not sure how you would do that but perhaps you can just encrypt the data in the text files instead.
thatraja 21-Nov-13 7:57am    
what's the content of that text files? what details are you storing in those files?
No, I'm not your client. I'll give you better suggestion.
Raajkumar.b 22-Nov-13 1:13am    
text files consists of vacabulary words and meanings of it.
so users should not delete or modify the files
ZurdoDev 22-Nov-13 7:21am    
Lots of programs use external files for things like this. The Microsoft Office dictionary is an external file. If the user deletes them, that's their problem, the program will not work.

I would recommend encrypting the data; however, since you said it is just vocab words you can make the file a binary file and if the user deletes it, your program won't work. That's how Microsoft Office works so I don't see that as being an issue.
 
Share this answer
 
Comments
Raajkumar.b 22-Nov-13 7:32am    
thank u for reply.
hi RyanDev,
Is there any option for hiding textfiles?
ZurdoDev 22-Nov-13 7:41am    
No. Personally I think you are over thinking it. If your users mess it up, then the program won't work. Do you really have issues like that with your users?
Raajkumar.b 22-Nov-13 7:56am    
this is client requirement, already he faced this issue.so i want to hide the files.
ZurdoDev 22-Nov-13 7:59am    
You could hide them in a database. :)
You could use the file system attribute "Hidden". There are ways to see hidden files but it takes a bit of effort. I don't know of a way to hide a file so no one can see it.

See File.SetAttributes[^]

C#
File.SetAttributes(path, File.GetAttributes(path) | FileAttributes.Hidden);
 
Share this answer
 
v2
I want to talk a little bit more about solution hinted in Solution1: use the database. I would suggest SQLite. This is very simple file based database. Big advantage is that it will ensure integrity of your data. And of course you are getting powerful SQL to access and manipulate data. I think this is much better than just set of files. Give it a try.
 
Share this answer
 
Simple Is Put all You Txtfile in on folder and Set Password to open the file
 
Share this answer
 
Comments
Raajkumar.b 23-Nov-13 4:05am    
is it possible?
can u post any refferal links
Instead of hide text files, you should encrypt them, in my opinion.
Another option would be using a real database, of course.
 
Share this answer
 
Comments
Raajkumar.b 22-Nov-13 1:12am    
hi,
even am encrypting the text files also textfile will visible to user and he can delete content in it. so now i want to hide that files.
CPallini 22-Nov-13 1:55am    
You could make such file write-protected (unless the user has superpowers, like being administrator). On the other hand, if the user is the system administrator then you can do nothing against his/her destruction will.
Raajkumar.b 22-Nov-13 2:02am    
thank u for reply.
but for two text files i have to give write permission to user for insertion. so i need to hide the files that is my issue
CPallini 22-Nov-13 3:13am    
The application should have the permissions for updating the files, the user should not have it.

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