function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
vagishvagish 

OpportunitySplit Sobject Type and apex code in managed package

Hi,
Use case: I have a JS button on opportunity detail page. It opens a visualforce page. On VF page load, it runs a check on OpportunitySplit object type (runs a SOQL on OpportunitySplit and checks for records). Problem is, I can't deploy this code into the SF account where Opportunity Split feature is not enabled, and I have to add this JS button, VF page and controller into package.
Any suggestion how I can achieve that? I don't want to do this validation (query) in js button.
I tried to make this post smaller, can provide more info if needed.
Thanks,