Find Code:
All Words
Any of the Words
Exact Phrase
Home
:
Code
:
Forums
:
Submit
:
Mailing List
:
About
:
Contact
Code
All
VB.NET
ASP.NET
C#
VB Classic
ASP Classic
Snippets
Popular
Resources
Submit Code
Forums
Articles
Tips
Links
Books
Contest
Link to us
Read registry separate char
Author:
[IBT]-Hitman
E-mail:
Click to e-mail author
Submitted:
2/18/2010
Version:
VB 2008
Compatibility:
VB.NET 2003, VB 2005, VB 2008
Category:
Windows Registry
Views:
9606
How to read from registry and separate the result to different text boxes.
Declarations:
Imports Microsoft.Win32 Imports System.IO
Code:
'This is an example but works for Call of Duty 4 running in x32 OS Public Class Form1 'Versão 32 bits Private Sub Form1_Load(ByVal sender As System.Object, ByVal e _ As System.EventArgs) Handles MyBase.Load Dim readValue1 As String readValue1 = My.Computer.Registry.GetValue _ ("HKEY_LOCAL_MACHINE\Software\Activision\Call of Duty 4", "codkey", "ErroErroErroErroErro") ' this will get the value contained in HKEY_LOCAL_MACHINE\Software\Activision\Call of Duty 4 in the key codkey t1.Text = readValue1.Substring(0, 4) t2.Text = readValue1.Substring(4, 4) t3.Text = readValue1.Substring(8, 4) t4.Text = readValue1.Substring(12, 4) t5.Text = readValue1.Substring(16, 4) 't1 = TextBox1 and so on ' That Code will separate 4 char in single textbox... try yourself to see! you can go to erg edit and create and registry to test de code 'To teste this specific code in value put this key! DL2J8PY44Q22GE4888D2
Home
|
Forums
|
Submit
|
Books
|
Mailing List
|
Advertising
|
About
|
Contact
© 2023 A1VBCode. All rights reserved.
Legal disclaimer & terms of use
Privacy statement