Is there a way to load the java runtime environment programmatically?

I need to write a small app that does this on a users login, so when they try to open a page that contains java, they don't go crazy waiting for it to load.