0

i successfully edited windows registry using java API...

BUT THE PROBLEM IS whether i need to reboot os or not...

because after editing it has no effect...

if i need to reboot then how can i skip it(i strictly dont like to reboot...)...

any java snippet available,,


plz....

2
Contributors
1
Reply
2
Views
7 Years
Discussion Span
Last Post by kdkanishka
0

You can use
Runtime.getRuntime().exec(" command ") statement to run external command. We can use this functionality to edit windows.
You can use REG command to edit windows registry. You can see more info on how to edit registry using REG command on microsoft support website.
http://technet.microsoft.com/en-us/library/cc742162%28WS.10%29.aspx

code:

class test
{
 public static void main(String args[])
 {
	try
	{
		Runtime.getRuntime().exec("REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\your soft\key");
	}
	catch(Exception e)
	{
		System.out.println("Error ocured!");
	}
	
 }
}
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.