• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

cannot find symbol

 
Ranch Hand
Posts: 129
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
These are supposed to work together. I get a bunch of "cannot find symbol" errors when working with currencyType from class Money. What am I doing wrong?


[ February 12, 2006: Message edited by: Jesse Crockett ]
 
Ranch Hand
Posts: 2412
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In your first class definition, you cannot reference a variable defined in the class Money, without using a reference to a Money object.
 
Ranch Hand
Posts: 311
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Could I kindly suggest that you try to narrow down the problem ?
Please don't take this the wrong way - I'm really trying to help, but I've had trouble following all the code, which wasn't necessarily relevant to the question. Shorter code is likely to bring you much more replies.

In your case, if you're having a linking problem (one class can't use the other), can you please try post a version with shorter classes ? You could probably reproduce the error message, even if each class has just 3-4 lines of code (with some "hello world" method instead of the complicated currency calculations)...

It will also help if you quote the exact error message, and which line of code it's referring to.

Good luck.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic