We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now

x

In vb 6.0 how a declaration to a custom object is error

swansonplace
swansonplace asked
on
Medium Priority
256 Views
Last Modified: 2010-04-07
Dim objCurrency as New Currency

Error: Compile error
Expected Identifier

Any suggestions?
Comment
Watch Question

Commented:
This is because Currency itself is a reserved datatype for currency values.
Guy Hengel [angelIII / a3]Billing Engineer
CERTIFIED EXPERT
Most Valuable Expert 2014
Top Expert 2009

Commented:
this could be due to the library (dll) providing the Currency class not being properly added in the project references
please check the project references; and if you can browse (F2) the class library

Commented:
You can change the class name to another one.
Director, IT and Business Development
Commented:
Try using late binding

Dim objCurrency as Object

Set objCurrency = CreateObject("Currency")

If this doesn't work then make sure the dll is registered using regsvr32 "path to the DLL file"

Also check your registery if the dll is registered

Start reg edit ("Start->Run-> type regedit) and navigate to HKEY_CLASSES_ROOT\

Check in that list that your DLL component is registered and that the name of the component is the same as you expect.


Hope that helps,

Leo

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
Thank you all very much for your assistance!
Leo EikelmanDirector, IT and Business Development

Commented:
thank you  :)

Leo
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.