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
Rodolfo CalvoRodolfo Calvo 

Hide code in packages

Hello Team, 

I packaged a visualforce page and its controller but the code is still able to be seen. How can I hide my code?
Thanks in advance. 
Swayam@SalesforceGuySwayam@SalesforceGuy
Hi,

You need to create manage package, Altough there are some implication

Implications of Managed Packages on Source Code

If someone installs a managed package, they don't get access to all the source code of that package. For example, if the package installs an Apex class, they will not be able to view the source code of that Apex class. Here is a list of factors that should be considered:
  • Apex class source code is completely hidden; unless the Apex class is a global class in which case the global method signatures and variables are exposed.
  • The source of Visualforce pages is not hidden. However, the source cannot be edited.
  • The source of Visualforce Components is hidden.
  • Trigger source code is also hidden.

Please refer (https://developer.salesforce.com/page/An_Introduction_to_Packaging)

Hope this helps

--
Thanks,
Swayam
 
Rodolfo CalvoRodolfo Calvo
Unmanaged Only
This is what salesforce shows me in the package section. 
Swayam@SalesforceGuySwayam@SalesforceGuy
You can edit that, Click on Edit -->  you need to create a name space  

Once you created that you would be able to see managed check box 

User-added image

Hope this helps
--
Thanks,
Swayam
Rodolfo CalvoRodolfo Calvo
User-added image
I have no such option. 
What could it be?