This question is locked. New answers and comments are not allowed.
Hi. I can't seem to figure out the VB.NET syntax for using ScriptRegistrar.OnDocumentReady. Can someone please translate this snippet from the Demo to VB.NET please?
Also, is it possible to call OnDocumentReady from code-behind? Specifically, I want to make a simple HtmlHelper extension method, and I can't figure out what the syntax must be. The following compiles but doesn't appear to do a thing:
Thanks!
.OnDocumentReady(() => { %>prettyPrint();<% }) |
Also, is it possible to call OnDocumentReady from code-behind? Specifically, I want to make a simple HtmlHelper extension method, and I can't figure out what the syntax must be. The following compiles but doesn't appear to do a thing:
<Extension()> _ |
Public Sub SetDefaultFocusedTextbox(ByVal html As HtmlHelper, ByVal id As String) |
html.Telerik.ScriptRegistrar.OnDocumentReady(Function() String.Format("$(""#{0}"").focus();", id)) |
End Sub |
Thanks!