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

Use @<text> syntax in a Template in VB

4 Answers 205 Views
Grid
This is a migrated thread and some comments may be shown as answers.
YY
Top achievements
Rank 1
YY asked on 01 Oct 2013, 04:42 PM
I've seen scattered throughout the Kendo docs examples of using @<text> for template methods.  For example in this SO question it's used both inside a Content call on a TabStrip and in a Template call on a Grid Column.

In VB however, this does not seem to work:

        @(Html.Kendo().Grid(Of MyModel) _
            .Columns(Sub(config)
                         config.Template(@<text>
                                             <b>Test rendering inline markup</b>
                                         </text>)
                     End Sub)
        )

4 Answers, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 02 Oct 2013, 10:49 AM
Hi Byron,

Please refer to

http://docs.kendoui.com/getting-started/using-kendo-with/aspnet-mvc/vb#grid

Regards,
Dimo
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Alex
Top achievements
Rank 1
answered on 29 Jun 2015, 11:56 AM

Dimo,

 As Byron said - it doesn't work. I too have the same problem. Answering a question by linking to documentation that doesn't work doesn't solve the problem.

 

Byron, were you able to resolve this issue?

0
Alex
Top achievements
Rank 1
answered on 29 Jun 2015, 12:01 PM

Byron, 

 I was able to get it to work using the following syntax.

c.Template(Function(f)
     Return "<a href='" & Url.Action("EditUser") & "=" & f.UserID & "'>Edit User</a>"
End Function)

 

Hope that helps

0
Stu
Top achievements
Rank 1
answered on 16 Feb 2016, 02:04 PM
Bless you Alex!  I'm stuck with a legacy VB.NET site now with MVC and Telerik.  I've had the hardest time with the lambda stuff for VB and have been looking for how to do the template stuff.  The Telerik documentation has helped some, but I have been struggling with the toolbar template.  Thank you so much for posting this.
Tags
Grid
Asked by
YY
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Alex
Top achievements
Rank 1
Stu
Top achievements
Rank 1
Share this question
or