I could be wrong, but there's no a "clean solution" for this - up to now DbForms is configured by the dbforms-config.xml during startup; DbConnection class relies on those data to retrieve JDBC connections.
Anyway, from a JSP page, you could try to get the DbConnection object with:
DbFormsConfig config = (DbFormsConfig) pageContext.getServletContext().getAttribute(DbFormsConfig.CONFIG);
then:
DbConnection = DbFormsConfig.getDbConnection();
DbConnection class contains all the fields related to database access;
but I never tried to change the properties values during the application lifetime. *Note* also that the DbConnection class is shared with users (it's a "global class"), so I suppose your changes will be global to all users...
Regards, Luca
I do not want to hardcode the username/password values into the dbforms-config.xml. The user has to enter the right database username/password from a login.jsp.
How do I access the dbconnection properties from my login page?
thanks
Isabelle
------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ DbForms Mailing List
http://www.wap-force.net/dbforms
