473,790 Members | 3,265 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Need an Example Modifying Remote Registry

Hi:

I'm looking for an example of modifying the registry of a remote system.

Thanks much!
Charles
Jul 29 '08 #1
3 2401
Charles,

Any example in the documentation will do. The only thing you have to do
differently is call the static OpenRemoteBaseK ey to get the hive on the
remote system you want to work with, and proceed from there.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"Charles" <Ch*****@discus sions.microsoft .comwrote in message
news:66******** *************** ***********@mic rosoft.com...
Hi:

I'm looking for an example of modifying the registry of a remote system.

Thanks much!
Charles

Jul 30 '08 #2
I get, "Use the new keyword to create an object instance". And we I do use
new I get
"Microsoft.Win3 2.RegistryKey.O penRemoteBaseKe y(Microsoft.Win 32.RegistryHive ,
string) is a mathod but is used like a type".

This is what I'm trying to get to work:

RegistryKey Tb2Key =
RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
textBox4.Text). OpenSubKey("Sof tware\\Netopia\ \Timbuktu Pro\\TimbuktuNa me");
Tb2Key.SetValue ("StringValu e", textBox4.Text);

RegistryKey RoKey =
RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
textBox4.Text). OpenSubKey("Sof tware\\Microsof t\\Windows
NT\\CurrentVers ion\\Registered Owner");
RoKey.SetValue( "StringValu e", textBox3.Text);

RegistryKey CNameKey =
RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
textBox4.Text). OpenSubKey("Sof tware\\Microsof t\\Windows
NT\\CurrentVers ionRegisteredOr ganization");
CNameKey.SetVal ue("StringValue ", "NeuStar Inc");

Tb2Key.Close();
RoKey.Close();
CNameKey.Close( );

"Nicholas Paldino [.NET/C# MVP]" wrote:
Charles,

Any example in the documentation will do. The only thing you have to do
differently is call the static OpenRemoteBaseK ey to get the hive on the
remote system you want to work with, and proceed from there.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"Charles" <Ch*****@discus sions.microsoft .comwrote in message
news:66******** *************** ***********@mic rosoft.com...
Hi:

I'm looking for an example of modifying the registry of a remote system.

Thanks much!
Charles


Jul 30 '08 #3
I made a change and I think I'm close. It's now telling me that I don't have
permissions to the remote system. The remote system is a virtual machine in
my domain and I do have permissions as I am running the program as an admin
of the domain.

RegistryKey CNameKey =
RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
textBox4.Text). OpenSubKey("Sof tware").OpenSub Key("Microsoft" ).OpenSubKey("W indows NT").OpenSubKey ("CurrentVersio n");

CNameKey.SetVal ue("RegisteredO rganization", "Company Inc",
RegistryValueKi nd.String);

Thanks!
"Charles" wrote:
I get, "Use the new keyword to create an object instance". And we I do use
new I get
"Microsoft.Win3 2.RegistryKey.O penRemoteBaseKe y(Microsoft.Win 32.RegistryHive ,
string) is a mathod but is used like a type".

This is what I'm trying to get to work:

RegistryKey Tb2Key =
RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
textBox4.Text). OpenSubKey("Sof tware\\Netopia\ \Timbuktu Pro\\TimbuktuNa me");
Tb2Key.SetValue ("StringValu e", textBox4.Text);

RegistryKey RoKey =
RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
textBox4.Text). OpenSubKey("Sof tware\\Microsof t\\Windows
NT\\CurrentVers ion\\Registered Owner");
RoKey.SetValue( "StringValu e", textBox3.Text);

RegistryKey CNameKey =
RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
textBox4.Text). OpenSubKey("Sof tware\\Microsof t\\Windows
NT\\CurrentVers ionRegisteredOr ganization");
CNameKey.SetVal ue("StringValue ", "NeuStar Inc");

Tb2Key.Close();
RoKey.Close();
CNameKey.Close( );

"Nicholas Paldino [.NET/C# MVP]" wrote:
Charles,

Any example in the documentation will do. The only thing you have to do
differently is call the static OpenRemoteBaseK ey to get the hive on the
remote system you want to work with, and proceed from there.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"Charles" <Ch*****@discus sions.microsoft .comwrote in message
news:66******** *************** ***********@mic rosoft.com...
Hi:
>
I'm looking for an example of modifying the registry of a remote system.
>
Thanks much!
Charles
Jul 30 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1809
by: Cherry | last post by:
Hi, can I access the registry of a remote machine using VB.NET? While connecting to the remote machine I would be using the admin login of that machine. Thanks.
2
1861
by: Mothish | last post by:
hi guys, is there any where i can access remote registry through c#. im new on this can any one help me on this. thanks mothish
5
7959
by: Parv | last post by:
I am working in a domain environment. I am on a client machine and wants to edit registery of domain server. I am currently in a Domain user account and member of Domain administrators on the domain controller. I am able to open registry manully by connecting the remote registry. While doing the same programatically i am getting the following exception : CODE : RegistryKey baseKey =
3
4601
by: Geoff McElhanon | last post by:
I have been struggling with a security issue that occurs under .NET 2.0, but does not occur under .NET 1.1. Essentially I am trying to open up a performance counter on a remote server and monitor its value. In .NET 1.1 this worked fine, however under .NET 2.0 it fails when I am not an administrator on the remote server. To provide a lean demonstration of the issue, I created the following class: ============================
3
2300
by: CAIBird | last post by:
hi, i'm wondering how to reader or write registry of a remote host. are there any classes help? Thanks in advance -Zhilin
5
6976
by: Sin Jeong-hun | last post by:
I need to read some registry keys of a remote computer. The key will be any key users provide. (For example : HKEY_CURRENT_USER\SOFTWARE \MyGame) I found that there was a handy method called RegistryKey.OpenRemoteBaseKey(); I tried But everytime I execute it, an UnauthorizedAccessException occurred at the OpenRemoteBaseKey method. Both computer (the one that ran the C# application, and the remote computer) are Windows XP Professional,...
8
6674
by: Hayato Iriumi | last post by:
Hello, folks. I have a need to get the value of %windir% on a remote machine. Is it possible to get this value using C#?
4
2433
by: Kerem Gümrükcü | last post by:
Hi, is it possible to get the Information that comes from OperatingSystem Class from a Remote Comupter. Is there a remote information supporting OperatingSystem Class or can i get this information another way, e.g. from opening remote registry? The target Systems are strictly Windows.
6
3688
tlhintoq
by: tlhintoq | last post by:
I pride myself on being able to Google just about anything but... I have fought, tried, searched and fought some more on this one. I am using VMware, and am able to debug from Visual Studio to the VMware virtual machine... Right up until the application being debugged tries to write to the registry. Then it fails due to lack of security permissions. It writes to the Host PC registry just fine. This is only happening when remote...
0
9666
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9512
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10201
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9023
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7531
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6770
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5424
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5552
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4100
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.