Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. VS03 and VS05 registry editing

VS03 and VS05 registry editing

Scheduled Pinned Locked Moved Visual Basic
visual-studiowindows-adminquestion
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    medicenpringles
    wrote on last edited by
    #1

    i'm writing a small app to change the windows mouse in VS'05, to change a key i do this: Imports Microsoft.Win32 . .. Dim key as RegistryKey = Registry.CurrentUser.OpenSubKey("Control Panel\\Cursors",True) key.SetValue("Arrow","%SYSTEMROOT%\NewCursor.cur",RegistryValueKind.ExpandString) i would like to do this same thing in VS'03, but it does not facilitate the last parameter where i use the RegistryValueKind class (or enum, whatever it is). does anyone know the vb03 equivalent to the line: key.SetValue("Arrow","%SYSTEMROOT%\NewCursor.cur",RegistryValueKind.ExpandString) ?

    D 1 Reply Last reply
    0
    • M medicenpringles

      i'm writing a small app to change the windows mouse in VS'05, to change a key i do this: Imports Microsoft.Win32 . .. Dim key as RegistryKey = Registry.CurrentUser.OpenSubKey("Control Panel\\Cursors",True) key.SetValue("Arrow","%SYSTEMROOT%\NewCursor.cur",RegistryValueKind.ExpandString) i would like to do this same thing in VS'03, but it does not facilitate the last parameter where i use the RegistryValueKind class (or enum, whatever it is). does anyone know the vb03 equivalent to the line: key.SetValue("Arrow","%SYSTEMROOT%\NewCursor.cur",RegistryValueKind.ExpandString) ?

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      From the MSDN Gospel: Note: When setting a value, the way in which the value being passed is stored in the registry is interpreted. There is no way to control whether the information being passed is stored as an sz, or an expanded_sz string, and therefore, all string values are interpreted as standard sz values. If the .SetValue method call will not set the value properly, then you'll have to P/Invoke the Registry API calls yourself to do it correctly. Check out http://www.pinvoke.net[^] for more information. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

      M 1 Reply Last reply
      0
      • D Dave Kreskowiak

        From the MSDN Gospel: Note: When setting a value, the way in which the value being passed is stored in the registry is interpreted. There is no way to control whether the information being passed is stored as an sz, or an expanded_sz string, and therefore, all string values are interpreted as standard sz values. If the .SetValue method call will not set the value properly, then you'll have to P/Invoke the Registry API calls yourself to do it correctly. Check out http://www.pinvoke.net[^] for more information. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

        M Offline
        M Offline
        medicenpringles
        wrote on last edited by
        #3

        well it would seem that the the site you gave me only lists API functions that retrieve the datatype, not change it. am i wrong?

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups