0

When I publish a Component, I am getting the following error:

JScriptException: Expression 'RenderComponentPresentation()' had error 'JScriptException: Expression 'RenderComponentPresentation("tcm:119-6186", GetTcmUriWebDavURI(GetValueOfResourceComponent("WebDavPath","solution_promo_box_component_template")))' had error 'RenderComponentPresentation: If a component is specified, a template must be specified also''

I tried searching but unable to find the solution

  • looks like, GetTcmUriWebDavURI(GetValueOfResourceComponent("WebDavPath","solution_promo_box_component_template") not returning template . check it – Raj Kumar Jan 18 '16 at 12:32
  • Sounds like solution_promo_box_component_template is a variable that should have been resolved to a URI before this. You might be missing a TBB before the DWT. – Nuno Linhares Jan 18 '16 at 12:39
  • When i am trying this component template , then to same error is coming JScriptException: Expression 'RenderComponentPresentation()' had error 'JScriptException: Expression 'RenderComponentPresentation("tcm:119-6186", GetTcmUriWebDavURI(GetValueOfResourceComponent("WebDavPath","solution_promo_box_component_template")))' had error 'RenderComponentPresentation: If a component is specified, a template must be specified also'' – swap_Pg Jan 18 '16 at 12:43
  • GetValueOfResourceComponent where is this method written? – Raj Kumar Jan 18 '16 at 12:45
  • Hi Raj, not knowing where exactly this GetValueOfResourceComponent function is written, I have just started using Tridion new to it – swap_Pg Jan 18 '16 at 13:00
1

The error message gives us a clue that it cannot find the template to render the Component with.

I would suggest to debug this function GetValueOfResourceComponent("WebDavPath","solution_promo_box_component_template")

My guess is that it is returning null. Maybe the "WebDavPath" should be the WebDavURL of the actual Component? I also assume the template 'solution_promo_box_component_template' is mapped somewhere in a config file. The return result should be a component template that the RenderComponentPresentation method can be rendered with.

| improve this answer | |

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.