Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Invalid procedure call or argument

Status
Not open for further replies.

egodette

Technical User
Jun 12, 2002
222
US
I just cant make sense of this.

if I use this code: msgbox = left(s_Line,pos-1)
I get the value that I want

if I use this code: rating = left(s_Line,pos-1)
I get an error message Invalid procedure call or argument:'left'

Any ideas?
 
You should have name collision. First, you must have dim a variable named msgbox. (It is already a very bad idea to name a variable "msgbox".) Second, you should have some function or sub named rating. Why you do that, I have no idea! Do you feel a short of choice in naming thing?
 
Invalid procedure call or argument:'left' implies that "pos-1" evaluates to 0 or a negative.

But you would really need to show more code to get any help here. Let's just say that this line:
Code:
msgbox = left(s_Line,pos-1)
is, ummmm, unusual.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top