• .Net 如何用一个随机数保存多个参数的值


    #region 返回List页面资料

    //将数据资料保存在一个随机数据里面       

    public void SetPreviewSession(string random, string PICNo, string areaNoStr, string fileNo, string readyonly, string Tilefg, string ShootingTime, string ApplyStatus, string ISPhotographers, string langid, string POINoStr)         {    

    //将资料保存在键值对里面    

    Dictionary<string, string> list = new Dictionary<string, string>();         

    list.Add("PICNo", PICNo);            

    list.Add("areaNoStr", areaNoStr);            

    list.Add("fileNo", fileNo);            

    list.Add("readyonly", readyonly);            

    list.Add("ShootingTime", ShootingTime);            

    list.Add("ISPhotographers", ISPhotographers);            

    list.Add("langid", langid);            

    list.Add("POINoStr", POINoStr);           

     list.Add("Tilefg", Tilefg);            

    list.Add("ApplyStatus", ApplyStatus);            

    Session[random] = list;

     }       

      #endregion

    //将随机数里面保存的资料解析出来

      Dictionary<string, string> list = Session[PICsessionName] as Dictionary<string, string>;
                if (list != null)
                {

          //获取键值对里面的值
                    PVM.PICNo = list["PICNo"];//键值对里面主键PICNo的值

          ............

        }

  • 相关阅读:
    杯具的流浪狗
    数据加密与数据压缩后加密的效率
    XMPP协议自定义消息类型扩展
    have a try
    linux修改网卡名称的方法
    WARNING: old character encoding and/or character set解决办法
    extern用法总结
    linux下的c++线程池实现
    32位linux系统操作大于2G文件方法
    eclipse中gdb调试输出stl容器的内容
  • 原文地址:https://www.cnblogs.com/qhy1277/p/6369835.html
Copyright © 2020-2023  润新知