📄 numericupdown.cs
字号:
// (c) Copyright Microsoft Corporation.
// This source is subject to the Microsoft Permissive License.
// See http://www.microsoft.com/resources/sharedsource/licensingbasics/sharedsourcelicenses.mspx.
// All other rights reserved.
using System;
using System.Web.Services;
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[System.Web.Script.Services.ScriptService]
public class NumericUpDown : WebService
{
public NumericUpDown()
{
// Uncomment the following line if using designed components
//InitializeComponent();
}
[WebMethod]
public int NextValue(int current, string tag)
{
return new Random().Next(Math.Min(1000, Math.Max(0, current)), 1001);
}
[WebMethod]
public int PrevValue(int current, string tag)
{
return new Random().Next(0, Math.Min(1000, Math.Max(0, current)));
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -