Article ID: 276560 - Last Review: October 15, 2002 - Revision: 1.0 BUG: Compiler Error with Left Function When Devshll.dll Is ReferencedThis article was previously published under Q276560 On This PageSYMPTOMS
When you use the Left string function in Visual Basic and your project contains a reference to Microsoft Visual C++ Shared Objects (Devshl.dll), you may receive the following compiler error message:
Wrong number of arguments or invalid property assignment
This does not occur when you use a form module, but may occur when you use a standard or class module. CAUSE
The compiler seems to resolve the Left function in Devshl.dll instead of in the VBA library. Because Left is a property of the Application and Window objects in Devshl.dll, you receive an error when you call Left as a function.
RESOLUTION
Fully qualify the call to the Left function, as in the following example:
STATUSMicrosoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article. MORE INFORMATIONSteps to Reproduce Problem
| Article Translations
|
Back to the top
