Exemple #1
0
 private string GetResourceName(ControlResourceType p_type)
 {
     string sResourceExtension = p_type.ToString().ToLower();
       return string.Format("{0}.{1}.{2}", Assembly.GetExecutingAssembly().GetName().Name,
                    m_ctlOwner.GetType().Name, sResourceExtension);
 }
Exemple #2
0
 public string GetControlResource(ControlResourceType p_type)
 {
     string sResource = string.Empty;
       try
       {
     using (StreamReader sr =
     new StreamReader(Assembly.GetExecutingAssembly().GetManifestResourceStream(
                          GetResourceName(p_type))))
     {
       sResource = sr.ReadToEnd();
     }
       }
       catch
       {
       }
       return sResource;
 }