Quantcast
Channel: VBForums - Visual Basic .NET
Viewing all articles
Browse latest Browse all 27329

VS 2010 Registry: How to Change Multiple Values in Subfolders?

$
0
0
Hi everyone. I started with searching in the forum If I could find a sulotion, but nothing helpfull.

I am trying to Change Value-Data in All the Subfolders in my Registry. I know a bit new to Registry in vBNET and I already have a simple code that Changes only a single Value-Data of Value names in registru

Here is a Screenshot of the 3 Sub folders (I want to change the Data (1) in in valuename showads) in all the folders:




The Value-Name is "showads", and I want to use a Textbox to change the Value-Data of the "showads" which can be from Diggits 1 to 10. But thats what I want to use the TextBox for. How can I possbily change all the Value-Data for "showads" in all the subfolders using a Textbox and by a single click button click.

So far I managed to have this Code below that Changes 1 Value at a time:
Code:

       
Dim Reg = My.Computer.Registry.CurrentUser.OpenSubKey("Software\Movies", True)
Reg.SetValue("showads", TextBox1.Text)
Reg.Close()

I tried using "FOR EACH" and different methods, but Kept failing.. I really hope could get some help to fix this code...

Thank you very much in advance..

Viewing all articles
Browse latest Browse all 27329

Trending Articles