简体   繁体   English

Telerik股票代码在Razor Views ASP.NET MVC中不起作用

[英]Telerik ticker tags not working in Razor Views ASP.NET MVC

I have gone through some Telerik Ticker's demos On these pages - demo1 , demo2 and demo3 . 我已经通过一些Telerik的股票代码的演示了在这些网页上- demo1的DEMO2demo3 These demos do not include their code for Razor (cshtml) Views and if I skip all the ASP.NET Tags and only choose Telerik Tags Like below in my razor views it does not show any output 这些演示不包含其Razor(cshtml)视图的代码,并且如果我跳过所有ASP.NET标签并仅在剃须刀视图中选择如下所示的Telerik标签,则不会显示任何输出

<telerik:RadTicker ID="RadTicker1" AutoStart="true" Width="300px">
    <items>
        <telerik:RadTickerItem ID="RadTickerItem1" Text="Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.">
        </telerik:RadTickerItem>
    </items>
</telerik:RadTicker>

It does not work in Razor . 它在Razor中不起作用。 Any reason , solution or alternative will be appreciatable . 任何理由,解决方案或替代方案都是可理解的。

Note 注意
code of aspx pages is included in the demos linked in the question .I'm working on VS2013 mvc5 问题链接的演示中包含了aspx页面的代码。我正在使用VS2013 mvc5

<telerik:RadTicker> will only work for web forms because it will need a designer.cs code. <telerik:RadTicker>仅适用于Web表单,因为它需要designer.cs代码。 It is not design for you to use in MVC razor views. 它不是为在MVC剃刀视图中使用而设计的。 cshtml can only accept HTML elements combined with Razor commands, no ASP.NET controls. cshtml只能接受与Razor命令结合使用的HTML元素,而不能接受ASP.NET控件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM