A few vb 2005 express questions

Post here about scripting and programming for HaloPC (audio, network, ai, etc.)
Post Reply
MattBot5000





Posts: 7
Joined: Thu Nov 03, 2005 1:36 pm

A few vb 2005 express questions

Post by MattBot5000 »

hey a couple of questions:

1. how do i link an object such as a web browser to a progress bar
2. when i make things such a color dialog, they don't show up, and option to make it visable in properties.
3. how do i get a button to do the edit commands (cut, paste, copy, etc.)
4. how do i get vb to create a *.txt file and read variables from it (like a cookie)
thx in advance
PlasmaGhost





Posts: 149
Joined: Wed Oct 05, 2005 12:23 pm

Re: A few vb 2005 express questions

Post by PlasmaGhost »

MattBot5000 wrote:hey a couple of questions:

1. how do i link an object such as a web browser to a progress bar
2. when i make things such a color dialog, they don't show up, and option to make it visable in properties.
3. how do i get a button to do the edit commands (cut, paste, copy, etc.)
4. how do i get vb to create a *.txt file and read variables from it (like a cookie)
thx in advance
1. im not so sure about this but i think its like

Code: Select all

Progressbar.Progress = WebBrowser.Progress
2. you need ColorDialog.ShowDialog() to show it

3.Make a button, double click it, in the sub type this:

Code: Select all

TextBox1.Copy() 'Copys selected text in TextBox1
TextBox1.Cut() 'This might work i haven't tried it
TextBox1.Paste() 'I've also never tried this lol
TextBox1.SelectAll() 'You can do this to select ALL text
4. Type this:

Code: Select all

Dim filename as String = "C:\WINDOWS\secretTextFile.txt" 'change to filename
Dim stext as String = "" 'change to what text to save
Dim rtext as String = "" 'leave blank
My.Computer.FileSystem.WriteText(filename,stext,false) 'saves file
rtext = My.Computer.FileSystem.ReadText(filename) 'read data to text
That code should work. If it's not ReadText and WriteText its just Read and Write. Good luck programming!

Be sure to check out my program called H2SV!

PlasmaGhost
Post Reply