Okay, here's the deal. Code tags are the tags you should surround your code with so that it formats correctly on this forum. Has nothing to do with your code per se. See the [ C O D E ] thing in the "Post Reply" editing area? Click that and it will give you your code tags. Paste your code in between the two tags.
Next, I didn't notice this before, but you're passing text into your function as parameters, then turning right around and changing them to numbers. Bad technique. It will work but you should be using separate local variables inside your function for calculations.
Next, (and also for @Capritarius21), in order to return a value from a function in VB6, you set the name of the function equal to the return value. That will pass the value back to wherever it was called from. So, in the interest of complete disclosure, here is some (corrected) sample code.
Private Sub Form_Load()
' Here is where you declare the variable to hold the return value of your function
Dim myResistor As Double
' Here is where you call your function
myResistor = Resistor("black", "blue", "silver")
' Here is where you display the return value
Me.Caption = CStr(myResistor)
End Sub
Function Resistor(color1 As String, color2 As String, color3 As String) As Double
' Here is where you declare the variables you use to do calculations
Dim dblColor1 As Double
Dim dblColor2 As Double
Dim dblColor3 As Double
' Here is where you convert your parameter to a number
Select Case color1
Case "black", "Black"
dblColor1 = 0
Case "brown", "Brown"
dblColor1 = 1
Case "Red", "red"
dblColor1 = 2
Case "Orange", "orange"
dblColor1 = 3
Case "Yellow", "yellow"
dblColor1 = 4
Case "Green", "green"
dblColor1 = 5
Case "Blue", "blue"
dblColor1 = 6
Case "Violet", "violet", "Purple", "purple"
dblColor1 = 7
Case "Grey", "grey", "Gray", "gray"
dblColor1 = 8
Case "White", "white"
dblColor1 = 9
Case "Gold", "gold"
color1 = 0.1
Case "Silver", "silver"
dblColor1 = 0.001
End Select
' Here is where you convert your next parameter to a number
Select Case color2
Case "black", "Black"
dblColor2 = 0
Case "brown", "Brown"
dblColor2 = 1
Case "Red", "red"
dblColor2 = 2
Case "Orange", "orange"
dblColor2 = 3
Case "Yellow", "yellow"
dblColor2 = 4
Case "Green", "green"
dblColor2 = 5
Case "Blue", "blue"
dblColor2 = 6
Case "Violet", "violet", "Purple", "purple"
dblColor2 = 7
Case "Grey", "grey", "Gray", "gray"
dblColor2 = 8
Case "White", "white"
dblColor2 = 9
Case "Gold", "gold"
dblColor2 = 0.1
Case "Silver", "silver"
dblColor2 = 0.001
End Select
' Here is where you convert your last parameter to a number
Select Case color3
Case "black", "Black"
dblColor3 = 0
Case "brown", "Brown"
dblColor3 = 1
Case "Red", "red"
dblColor3 = 2
Case "Orange", "orange"
dblColor3 = 3
Case "Yellow", "yellow"
dblColor3 = 4
Case "Green", "green"
dblColor3 = 5
Case "Blue", "blue"
dblColor3 = 6
Case "Violet", "violet", "Purple", "purple"
dblColor3 = 7
Case "Grey", "grey", "Gray", "gray"
dblColor3 = 8
Case "White", "white"
dblColor3 = 9
Case "Gold", "gold"
dblColor3 = 0.1
Case "Silver", "silver"
dblColor3 = 0.001
End Select
' Here is where you do your calculation, and set the return value
Resistor = (dblColor1 * 10 + dblColor2) * (10 ^ dblColor3)
End Function
Just an aside, you may also want to experiment with some indenting so that your code is a little more readable.