aspose file tools
The moose likes Java in General and the fly likes How to add key to windows registry?? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Java in General
Reply Bookmark "How to add key to windows registry??" Watch "How to add key to windows registry??" New topic
Author

How to add key to windows registry??

Supun Lakshan Dissanayake
Ranch Hand

Joined: Oct 26, 2012
Posts: 53

I want to read or write registry key to windows registry using a java programme.
registry key is like "HKEY_LOCAL_MACHINE\SOFTWARE\KasperskyLab\protected\AVP12" // this registry key is a SAMPLE
How to do it?

Regards!!


Try and Try one day you can FLY.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35256
    
    7
The http://www.coderanch.com/how-to/java/JavaIoFaq links to the solution.


Android appsImageJ pluginsJava web charts
Greg Charles
Bartender

Joined: Oct 01, 2001
Posts: 2542
    
  10

I've never used it myself, but I believe the Java API class java.util.prefs.Preferences uses the Windows registry as its store when running on Windows. Its abilities to read and write registry keys would be limited, but depending on your requirements might be enough. If you need more flexibility, then you'll need to write (or find to download) a JNI interface for this job. Here another thread that might point you in the right direction: http://www.coderanch.com/t/517229/java/java/Editing-reading-windows-registry-java
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to add key to windows registry??
 
Similar Threads
How to read an entry from Windows registry?
Java Application, MS Access database
Compiler Gremlin
Registry
could not find java.dll how do I fix this?