This is a migrated thread and some comments may be shown as answers.

Debug or View more info on Client template errors

1 Answer 99 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bruce
Top achievements
Rank 1
Bruce asked on 08 May 2019, 01:28 PM

Hi,

 

Is there a simple way to view more detail around what is causing an issue with a client template?

 

I have a situation where I have a grid, and I want a child grid in the detail, but when i call render all i get is an error in Chrome saying "Invalid Template" and a bunch of gumpf after that.

 

Thanks,

Bruce

1 Answer, 1 is accepted

Sort by
1
Bruce
Top achievements
Rank 1
answered on 08 May 2019, 01:48 PM

Fixed it.

I was missing this believe it or not: .ToClientTemplate()

:face_palm:

Perhaps the error message "Invalid Template" was fairly descriptive after all.

 

Thanks,

Bruce

Vince
Top achievements
Rank 1
commented on 21 Sep 2022, 01:32 PM

It was the about same for me :

Copied over grids from original view into another view inside a script template block, but I did not add the .ToClientTemplate() to the grid definition in the script block, I received the same "Invalid template" error in console.

At first I thought it was my template that had incorrect html, so it took me a while of determining it was not my html before I started googling and found this. +1
Yanislav
Telerik team
commented on 23 Sep 2022, 07:34 AM

Hello Vince,

Thank you for sharing with the community how you've resolved the issue. I'm sure it will be helpful in the future if anyone else runs into a similar problem.

Tags
General Discussions
Asked by
Bruce
Top achievements
Rank 1
Answers by
Bruce
Top achievements
Rank 1
Share this question
or