in reply to Re: format declaration in a class
in thread format declaration in a class
Hi and thanks for your help. The use vars seems to work fine, although when I tried our (in fact I tried it first before I posted to perlmonks.org), I got (and continue to get) these errors:
Variable "$sku" is not imported at lib/PurchaseOrder.pm line 206
Global symbol "$sku" requires explicit package name at lib/PurchaseOrder.pm line 206.
So my only solution (I guess?) is to use vars. I'm going to do more research to figure out exactly what that does. Thanks a lot!
Update: Well I was mistaken, I need to put the our declarations external to a sub. In which case it works perfectly. Thanks again!