C# 遍历枚举

Type enumType = typeof(Domain.Models.Entitys.PermissionEntity.PermissionTypeEnum);
                    Array values = Enum.GetValues(enumType);
                    if (values.Length > 0)
                    {
                        foreach (int item in values)
                        {
                            <option value="@item.ToString()">@Enum.GetName(enumType, item)</option>
                        }
                    }

C# 遍历枚举

上一篇:TextBox自动补全邮箱 c#


下一篇:windows打开telnet,查看断开是否通