cancel
Showing results for 
Search instead for 
Did you mean: 

Apply template through action

mchernecki
Champ in-the-making
Champ in-the-making
I have a template that I want applied when a user chooses to do so. Rather than having the user select  'Preview in Template -> select a template from list'. I want to setup an item in the action menu that when selected will automatically apply my template to the document details. I want to avaid having the user do a 2 step process and select from a list of templates. How can this be done?

Thanks
1 REPLY 1

rafaelscg
Champ on-the-rise
Champ on-the-rise
The code for who's still looking for:


var template = companyhome.childByNamePath("Data Dictionary/Presentation Templates/viewer.ftl");
document.properties["cm:template"]=template;
document.save();