admin 发表于 2023-3-2 19:25:44

ASP生成6位随机数字

<pre>
Dim zNum
Randomize Timer
zNum = CInt(899999 * Rnd + 100000)
</pre>
<p>如果使用<span style="color: #ff0000;"><strong>CInt</strong></span>提示溢出可以改为<strong><span style="color: #ff0000;">Int</span></strong></p>
<pre>
Dim zNum
Randomize Timer
zNum = Int(899999 * Rnd + 100000)
</pre>
                                        <p class="post-copyright">未经允许不得转载:<ahref="https://www.wangchao.info/">王超博客</a> &raquo; <ahref="https://www.wangchao.info/1428.html">ASP生成6位随机数字</a></p>
页: [1]
查看完整版本: ASP生成6位随机数字