1

I'd like to edit the Job Listings VisualForce page included with Volunteers For Salesforce (V4S). Because the page is part of a managed package I can't edit it directly and instead need to make a copy. If I make a copy and paste the code I get the following error...

Error: Unknown property '$ObjectType.Contact.fields.Volunteer_Skills__c'

Why is this? I'm simply duplicating the page and pasting the code from the old page into the new page without making any edits of my own.

  • I resolved this error by including the namespace when referring to the object. I now have a new error referring to a protected component.... Cannot Reference Protected Component gw_volunteers__labeleventinthepast I'm not sure how to resolve that one. This is the offending line... {!$Label.gw_volunteers__labelexternalsignupurl} Two lines earlier this similar line works... {!$Label.gw_volunteers__labelbuttonsignup} For some reason I don't have access to this and a couple of other specific values. – Tom Benbow Mar 5 at 21:22
  • I was able to successfully create my own copy of this page after fixing a number of name spacing issues and replacing the protected labels with hardcoded values. I'm not sure why the original page was able to work without these edits though. – Tom Benbow Mar 5 at 21:50
0

Most managed package components do not need a namespace. The compiler automatically assumes the namespace for anything that is in the managed package preferentially. This makes development easier for ISVs. However, when referencing those same namespace-prefixed elements in your own code, you must include the namespace. This is true for objects, fields, Visualforce, Lightning components, Apex Code, and so on.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.