Pressing Ctrl & H will allow you to replace certain text with new text. Very useful when re-naming variables or correcting spelling mistakes. eg. Changing all 'armor' to 'armour'.
Pressing F2 will bring up the Object Browser. In here, you can find out all the different data types, VB6 constants and things like that, and if you click on them you get a brief description and a simple syntax example. You can also find a specific description by right-clicking it in the code, and selecting 'Definition'.
F8 and Shift+F8 allow you to step into, and step over whilst debugging your code. Very useful when you need to go through some code step-by-step whilst it's running.
Click on the left margin next to your code, you can add a little red dot. If you run the program now, whenever this line of code is executed, the program will pause and highlight the line. Another good debug tool.
Have 'Option Explicit' at the top of
every module/form/class you create. Most
decent programming languages force you to explicitely declare variables before you use them. VB6 allows you to just ignore this. Some people see it as an advantage of VB6... but it's not! Not only does this make memory management a nightmare, as everything will be created as a variant (Which has it's uses, don't get me wrong), it creates a new variable every time it sees a new variable name in the code. If you misspell something, it'll just create another variable. This makes debugging incredibly hard.
ByRef and ByVal both have their uses. ByVal copies the memory across, making an entirely new value within the subroutine/function for you to use. ByRef simply acts as a referencer, and lets you edit the variable directly. Example. Imagine I'm calling the subroutine with my 'globalString' value for the sString.
Code:
Sub AddRobinToString(byval sString as string)
sString = sString & "Robin"
globalString = sString
end sub
Code:
Sub AddRobinToString(byref sString as string)
sString = sString & "Robin"
end sub
As you can see, the first subroutine is very limited. I can only hardcode it to have one string which adds 'Robin' to it. The second subroutine will handle any string sent to it, because all it did was reference the original variable.