开发者

mvc3 load dynamic properties into javascript using razor view engine

<script type="text/javascript" charset="utf-8">
var plug = new $.myPlugin({
    icon: "@ConfigurationManager.ApplicationIcon"
});
</script>
开发者_开发百科

ConfigurationManager.ApplicationIcon - this method is returning a a path (string) this is firing a compilation error - can you please help?

Compilation Error Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately. Compiler Error Message: CS1502: The best overloaded method match for 'System.Web.WebPages.WebPageExecutingBase.Write(System.Web.WebPages.HelperResult)' has some invalid arguments


missing () - sry guys - im still new to mvc 3

var plug = new $.myPlugin({ icon: "@ConfigurationManager.ApplicationIcon()" });
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜