MichaelRed
Programmer
What don't I understand here? (note - all of theis in the "immediate"/DeBug window in VB6.
PubSrch = "PWD"
PubTyp = "": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
1 1
PubTyp = "W": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
W 1 2
PubTyp = "P": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
P 1 1
PubTyp = "D": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
D 1 3
PubTyp = "Q": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
Q 1 0
Why does the InStr("PWD" ....) ALWAYS return 1,
While InStr(Var, Var2) return the 'right answer?
MichaelRed
mred@duvallgroup.com
There is never time to do it right but there is always time to do it over
PubSrch = "PWD"
PubTyp = "": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
1 1
PubTyp = "W": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
W 1 2
PubTyp = "P": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
P 1 1
PubTyp = "D": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
D 1 3
PubTyp = "Q": ? PubTyp, InStr("PWD", PubType), Instr(PubSrch, PubTyp)
Q 1 0
Why does the InStr("PWD" ....) ALWAYS return 1,
While InStr(Var, Var2) return the 'right answer?
MichaelRed
mred@duvallgroup.com
There is never time to do it right but there is always time to do it over