if I open my protected database with database password by input password with my hand (generally) or I open it by your method in runtime
which of them has more secureity :
a: with my hand b: your method c: equal
If the database password is not stored anywhere, but remains solely in your head until you enter it in response to a prompt, then I don't think it matters whether the prompt comes directly from Access when the protected database is opend, or from the code that
automates the opening of the protected database. Under those conditions, my answer would be (c).
If, however, you store the password somewhere on your computer, either in the code itself or in some table or file where you can read it when automating the protected database, and so not have to prompt the user at all, then clearly (a) is the correct answer.
Stored data can always be read by anyone who has access to the device on which it resides -- though higher levels of encryption can make that hard enough not to be worth the trouble.