get registry key how do i:

Posted on 2004-10-22
Last Modified: 2012-05-05
i have the registry of
"Program Path"="c:\\Program Files\\ArGo Software Design\\Mail Server\\"
how do i get Program Path="c:\Program Files\ArGo Software Design\Mail Server\" ???

aka Pern
Question by:Johnny
    LVL 14

    Accepted Solution

    Hey Pern.

    Try something like this:

    This code assumes you have this line at the top of your file:

    Imports Microsoft.Win32

    Dim RegKey As RegistryKey = Registry.LocalMachine.OpenSubKey("SOFTWARE\ArGoSoft\Mail Server\Setup")
    Dim val As String = RegKey.GetValue("Program Path")


    Author Comment

    thx you works great my problemw as putting inports outside of subs


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Article by: Kraeven
    Introduction Remote Share is a simple remote sharing tool, enabling you to see, add and remove remote or local shares. The application is written in VB.NET targeting the .NET framework 2.0. The source code and the compiled programs have been in…
    I think the Typed DataTable and Typed DataSet are very good options when working with data, but I don't like auto-generated code. First, I create an Abstract Class for my DataTables Common Code.  This class Inherits from DataTable. Also, it can …
    To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

    845 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    7 Experts available now in Live!

    Get 1:1 Help Now