当前位置: 代码迷 >> ASP.NET >> 怎么实现随机数脚本语言用c
  详细解决方案

怎么实现随机数脚本语言用c

热度:9294   发布时间:2013-02-25 00:00:00.0
如何实现随机数脚本语言用c#
如何实现随机数脚本语言用c#

------解决方案--------------------------------------------------------
http://blog.csdn.net/holym/archive/2006/05/16/741074.aspx

http://www.cnblogs.com/virusswb/articles/1238807
------解决方案--------------------------------------------------------
你是说用C#
生成一段js获取随机数的代码??
如果是可以这样
C# code
protected void page_load(){   regrandom();}protected void regrandom()        {            Page.ClientScript.RegisterStartupScript(typeof(string), "random", "function JSRanDom(){return Math.random();}", true);        }下面的也可以Response.Write("<script>function JSRanDom(){return Math.random();}</script>")