resources contain {0}

1):  In the SR.resx file, the item contain {0}

----------------------------------------------------------

in the SR.Designer.cs  file

        /// <summary>
        ///   Get information from the resx with the style as:  string information {0} 
        /// </summary>
        internal static string getvaluestr(string KKKD)
        {
            string UUU;           
            UUU = ResourceManager.GetString("getvaluestr", resourceCulture);
            return string.Format(UUU, KKKD);           
        }

 

In the application file

       SR.getvaluestr("test");    //

       //  output  ->    string information test

---------------------------------------------------------------

2):  in the SR.resx file, the item does not have {0}

---------------------------------------------------------------

in the SR.Designer.cs file

        /// <summary>
        ///  Get information from the resx with the style as:  best string information
        /// </summary>

       internal static string CategoryAttri {
            get {
                return ResourceManager.GetString("CategoryAttri", resourceCulture);
            }
        }

 

In the application file

       SR.CategoryAttri;    //

       // output ->     best  string information

 

 

 

   

  

posted @ 2010-04-13 23:30  greencolor  阅读(207)  评论(0编辑  收藏  举报