+ Start a Discussion
billkbillk 

Future of "snippet" S-Controls and INCLUDE() function?

With S-Controls soon to be deprecated, we're in the process of converting all of the S-Control content in our AppExchange package to Visualforce.  The only question is what to do with "snippet" S-Controls.  In particular, we have one snippet that contains the URL of a web application that we link to.  Then, in a custom button or link, we can use the INCLUDE() function to reference the URL, e.g.

 

https://{!INCLUDE($SControl.My_URL)}/Command.aspx?ServerID={!$Api.Partner_Server_URL_130}&SessionID={!$Api.Session_ID}

 
If we need to change the URL for any reason -- typically, when moving from a test/prerelease version of the external app to production, and vice-versa -- we update the Snippet and all of our links update automatically.
 
What's the best practice here?  Will "snippet" S-Controls and the INCLUDE() function be deprecated, or live on?  Is there a different approach?
Ispita_NavatarIspita_Navatar

S-Controls and the INCLUDE() function will be deprecated or will have issues , I am telling you from personal experience.


So the best approach will be to store the code which you have to reuse in a static resource and include it in the visual force page you are using.


Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved.