当前位置: 首页>>代码示例>>C#>>正文


C# UInt32.ToString方法代码示例

本文整理汇总了C#中System.UInt32.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# UInt32.ToString方法的具体用法?C# UInt32.ToString怎么用?C# UInt32.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在System.UInt32的用法示例。


在下文中一共展示了UInt32.ToString方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: AddNode

        public static INode AddNode(this IGraph myIGraph, UInt32 myUInt32Id)
        {
            if (myIGraph == null)
                throw new ArgumentNullException("myIGraph must not be null!");

            return myIGraph.AddNode(myUInt32Id.ToString());
        }
开发者ID:subbuballa,项目名称:Walkyr,代码行数:7,代码来源:IGraphExtensions.cs

示例2: createNewCharacter

        public UInt32 createNewCharacter(string handle, UInt32 userid, UInt32 worldId)
        {
            conn.Open();
            UInt32 charId = 0;
            //TODO: Complete with real data from a hashtable (or something to do it faster);
            //TODO: find values for uria starting place
            string sqlInsertQuery="INSERT INTO characters SET userid = '" + userid.ToString() + "', worldid='" + worldId.ToString() + "', status='0', handle = '" + handle + "', created=NOW() ";
            queryExecuter= conn.CreateCommand();
            queryExecuter.CommandText = sqlInsertQuery;
            queryExecuter.ExecuteNonQuery();

            //As i didnt find a solution for "last_insert_id" in C# we must fetch the last row by a normal query
            string sqlQuery = "SELECT charId FROM characters WHERE userId='" + userid.ToString() + "' AND worldId='" + worldId.ToString() + "' AND is_deleted='0' ORDER BY charId DESC LIMIT 1";
            queryExecuter = conn.CreateCommand();
            queryExecuter.CommandText = sqlQuery;
            dr = queryExecuter.ExecuteReader();

            while (dr.Read())
            {
                charId = (UInt32)dr.GetDecimal(0);
            }

            conn.Close();

            // Create RSI Entry
            conn.Open();
            string sqlRSIQuery = "INSERT INTO rsivalues SET charid='" + charId.ToString() + "' ";
            queryExecuter = conn.CreateCommand();
            queryExecuter.CommandText = sqlRSIQuery;
            queryExecuter.ExecuteNonQuery();

            conn.Close();

            return charId;
        }
开发者ID:hdneo,项目名称:mxo-hd,代码行数:35,代码来源:MyMarginDBAccess.cs

示例3: getSampleName

 public static string getSampleName(UInt32 val)
 {
     try{
         string temp = "0x" + val.ToString("X");
         sampleNames.TryGetValue(val, out temp);
         if (temp == null) return "0x" + val.ToString("X");
         return temp;
     }catch{
         return "0x" + val.ToString("X");
     }
 }
开发者ID:ronolaw,项目名称:IMAADPCMEncoder,代码行数:11,代码来源:Utils.cs

示例4: getMessageById

		public Message getMessageById( UInt32 id )
		{
			string sql = "`SELECT " +
			             "messages`.`id`, " +
			             "`messages`.`nuberReceiver`, " +
			             "`messages`.`message`, " +
			             "`messages`.`sendAt`, " +
			             "`messages`.`contactId` " +
			             "FROM SmsApplicatie.messages " +
			             "WHERE id=:id";

			MySqlCommand statement = this.databaseConnection.CreateCommand ();
			statement.CommandText = sql;
			statement.Parameters.AddWithValue ("id", id.ToString ());

			MySqlDataReader reader = statement.ExecuteReader ();

			if (reader.Read ()) 
			{
				Message message = new Message ( 
					Convert.ToUInt32( reader["id"] ),
					Convert.ToString( reader["nuberReceiver"] ),
					Convert.ToString( reader["message"] ),
					Convert.ToDateTime( reader["sendAt"] ),
					Convert.ToUInt32( reader["contactId"] )
				);
				return new Message ();
			}
			return null;
		}
开发者ID:jorisrietveld,项目名称:SmsApp,代码行数:30,代码来源:MysqlMessagesRepository.cs

示例5: getChunk

        public Chunk_Base getChunk(UInt32 chunkID, bool error = true)
        {
            Chunk_Base chunk = getChunksByID(chunkID).FirstOrDefault();
            if (chunk == null && error)
                throw new WMOException(string.Format("File does not contain chunk 0x{0}.", chunkID.ToString("X")));

            return chunk;
        }
开发者ID:Kruithne,项目名称:W3DT,代码行数:8,代码来源:WMOFile.cs

示例6: btnOK_Click

 private void btnOK_Click(object sender, EventArgs e)
 {
     Nmin = Convert.ToUInt32(numNmin.Value);
     Nmax = Convert.ToUInt32(numNmax.Value);
     Tsay = Convert.ToUInt32(numTsayMinute.Value * 60 + numTsaySecond.Value);
     Tnguoi = Convert.ToUInt32(numTnguoiMinute.Value * 60 + numTnguoiSecond.Value);
     ret = Nmin.ToString() + "," + Nmax.ToString() + "," + Tsay.ToString() + "," + Tnguoi.ToString();
     this.Close();
 }
开发者ID:quoctuanuit,项目名称:DryingCoffee,代码行数:9,代码来源:ConfigFile.cs

示例7: addItemToInventory

        public void addItemToInventory(UInt16 slotId, UInt32 itemGoID)
        {
            UInt32 charID = Store.currentClient.playerData.getCharID();

            string sqlQuery = "INSERT INTO inventory SET charId = '" + charID.ToString() + "' , goid = '" + itemGoID.ToString() + "', slot = '" + slotId.ToString() + "', created = NOW() ";
            queryExecuter = conn.CreateCommand();
            queryExecuter.CommandText = sqlQuery;
            queryExecuter.ExecuteNonQuery();
        }
开发者ID:hdneo,项目名称:mxo-hd,代码行数:9,代码来源:MyWorldDbAccess.cs

示例8: addAbility

 public void addAbility(Int32 abilityID, UInt16 slotID, UInt32 charID, UInt16 level, UInt16 is_loaded)
 {
     string theQuery = "INSERT INTO char_abilities SET char_id='" + charID.ToString()  + "', slot='" + slotID.ToString() + "', ability_id='" + abilityID.ToString() + "', level='" + level.ToString() + "', is_loaded='" + is_loaded.ToString() + "', added=NOW() ";
     conn.Open();
     queryExecuter = conn.CreateCommand();
     queryExecuter.CommandText = theQuery;
     queryExecuter.ExecuteNonQuery();
     conn.Close();
 }
开发者ID:hdneo,项目名称:mxo-hd,代码行数:9,代码来源:MyMarginDBAccess.cs

示例9: AVM2Method

        /// <summary>
        /// 
        /// </summary>
        /// <param name="index"></param>
        /// <param name="abc"></param>
        public AVM2Method( UInt32 index, AbcFile abc )
        {
            if ( abc.Methods.Count <= index )
            {
                ArgumentException ae = new ArgumentException( "Method " + index.ToString( "d" ) + " not in ABC file" );
                Log.Error(this,  ae );
                throw ae;
            }

            _Abc = abc;
            _MethodID = index;
        }
开发者ID:rtezli,项目名称:Blitzableiter,代码行数:17,代码来源:AVM2Method.cs

示例10: FetchCardPage

        public static RunnerResult FetchCardPage(UInt32 mid)
        {
            HttpWebResponse resp;
            String respBody;

            _RunHttpRequest(_CardDetailsUrlPath + mid.ToString(), out resp, out respBody);

            if (resp.StatusCode != HttpStatusCode.OK)
                return new RunnerResult(ResultType.UnknownCard, null);
            else
                return new RunnerResult(ResultType.CardResult, respBody);
        }
开发者ID:lux01,项目名称:LibGatherer,代码行数:12,代码来源:Runner.cs

示例11: SelectTask

        // ITDLUIExtension ------------------------------------------------------------------

        public bool SelectTask(UInt32 dwTaskID)
        {
            SampleListItem item = new SampleListItem();

            item.Value = dwTaskID.ToString();
            item.Type = "Selection";

            m_Items.Add(item);
            m_ListView.Items.Refresh();

            return true;
        }
开发者ID:xenoinc,项目名称:TDL-Pomodoro,代码行数:14,代码来源:SampleUIExtensionCore.cs

示例12: TextureListObject

        public TextureListObject(UInt32 imageHeaderOffset, TextureNode node)
        {
            name = "Texture " + (DatFile.textureList.Items.Count +1) + " (" + imageHeaderOffset.ToString("x8") + ")";
            this.node = node;
            imageHeader = node.imageHeader;
            paletteHeader = node.paletteHeader;
            imageBitmap = TPL.ConvertFromTextureMelee(imageHeader, paletteHeader, out imageSize);





        }
开发者ID:astenTX,项目名称:melee-toolkit,代码行数:13,代码来源:TextureListObject.cs

示例13: SettingParams

    //生成请求
    public void SettingParams()
    {
        SystemOptions so = new SystemOptions();

        //请求网关
        requestUrl = so["MemberSharing_Tencent_Gateway"].ToString("").Trim();

        //签名类型
        sign_type = "md5";

        //签名
        key = so["MemberSharing_Tencent_MD5"].ToString("").Trim();

        //对于商户:使用和支付时一样的key,可以登录财付通商户系统修改。
        sign_encrypt_keyid = "0";

        //字符编码格式
        input_charset = "GBK";

        //服务名称
        service = "login";

        //商户编号
        chnid = so["MemberSharing_Tencent_UserNumber"].ToString("").Trim();

        //chnid类型
        chtype = "0";

        //服务器通知返回接口
        redirect_url = Shove._Web.Utility.GetUrl() + "/Home/Room/TencentReceive.aspx";

        //自定义参数
        attach =redirect_url;

        //时间戳
        tmstamp = GetTmstamp();
        Dictionary<string, string> dict = new Dictionary<string, string>();
        dict.Add("sign_type", sign_type);
        dict.Add("sign_encrypt_keyid", sign_encrypt_keyid);
        dict.Add("input_charset", input_charset);
        dict.Add("service", service);
        dict.Add("chnid", chnid);
        dict.Add("chtype", chtype);
        dict.Add("redirect_url", redirect_url);
        dict.Add("attach", attach);
        dict.Add("tmstamp", tmstamp.ToString());
        sign=GetSign(key, input_charset,dict);
    }
开发者ID:ichari,项目名称:ichari,代码行数:49,代码来源:TencentLogin.aspx.cs

示例14: Parse

        /// <summary>
        /// 
        /// </summary>
        /// <param name="sourceStream"></param>
        protected override void Parse(BinaryReader sourceStream)
        {
            _DebugType = AVM2.Static.VariableLengthInteger.ReadU8(sourceStream);
            _Index = AVM2.Static.VariableLengthInteger.ReadU30(sourceStream);
            _Reg = AVM2.Static.VariableLengthInteger.ReadU8(sourceStream);
            _Extra = AVM2.Static.VariableLengthInteger.ReadU30(sourceStream);

            if (0 != _Extra)
            {
                // Of course, Adobe Flash CS4 makes use of this field
                AbcFormatException abcfe = new AbcFormatException("Extra (reserved) field in Debug instruction used: 0x" + _Extra.ToString("X"));
                Log.Warn(this, abcfe);
                //throw abcfe;
                //Log.Warn(this, "Extra (reserved) field in Debug instruction used: 0x" + _Extra.ToString("X"));
            }
        }
开发者ID:rtezli,项目名称:Blitzableiter,代码行数:20,代码来源:OP_debug.cs

示例15: AddMessageData

        // Allows the thread to place data in the RichEditBox control.
        private void AddMessageData(Int32 chNum, UInt32 msgId, UInt32 dlc, Byte [] msgData,
            UInt32 flags, Linlib.LinMessageInfo msgInfo)
        {
            if ((flags & Linlib.LIN_RX) != 0)
             {
            OutputRTB.AppendText("  RX   " + chNum.ToString("00") + "   ");
             }
             else
             {
            OutputRTB.AppendText("  TX   " + chNum.ToString("00") + "   ");
             }
             OutputRTB.AppendText(msgId.ToString("X8") + "   ");

             OutputRTB.AppendText(
            (((flags & Linlib.LIN_BIT_ERROR) != 0) ? "B" : " ") +
            (((flags & Linlib.LIN_SYNCH_ERROR) != 0) ? "S" : " ") +
            (((flags & Linlib.LIN_PARITY_ERROR) != 0) ? "P" : " ") +
            (((flags & Linlib.LIN_CSUM_ERROR) != 0) ? "C" : " ") +
            (((flags & Linlib.LIN_NODATA) != 0) ? "H" : " ") +
            (((flags & Linlib.LIN_WAKEUP_FRAME) != 0) ? "W" : " ") + "   ");

             OutputRTB.AppendText(dlc.ToString("D") + "     " +
                              msgInfo.checkSum.ToString("X2") + "     " +
                              msgInfo.idPar.ToString("X2") +
                              "         ");
             for (int i = 0; i < 8; i++)
             {
            if (i < dlc)
            {
               OutputRTB.AppendText(msgData[i].ToString("X2") + "  ");
            }
            else
            {
               OutputRTB.AppendText("    ");
            }
             }
             // time stamp
             double modifiedTime;
             modifiedTime = ((double)(msgInfo.timestamp)) / 1000.0;
             OutputRTB.AppendText(modifiedTime.ToString(" " + "000000.000") + "\n");

             // Need scroll bar to move down as data is added.
             // qqq - Something needs to be fixed here so scroll bar prevents this call.
             OutputRTB.ScrollToCaret();
        }
开发者ID:mc01104,项目名称:CTR,代码行数:46,代码来源:OutputView.cs


注:本文中的System.UInt32.ToString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。