在设计时如何在网格视图中全局分配资源 [英] how to global resources for grid view in design time
本文介绍了在设计时如何在网格视图中全局分配资源的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好,
如何在设计时为网格视图全局化资源.
我使用label --- Text =<%$ Resources:Filename,label1%>.
我想像这样的网格视图请引导我.
Hi All,
how to global resources for grid view in design time.
i use for label---Text="<%$ Resources:Filename,label1 %>.
i want same like this for grid view pls guid me. its very urgent.
推荐答案
资源:文件名,标签1%>.
我想像这样的网格视图请引导我.非常紧急.
Resources:Filename,label1 %>.
i want same like this for grid view pls guid me. its very urgent.
您可以使用下一个方法:
You can use the next method:
public string GetResourceString(string key)
{
Object obj = HttpContext.GetGlobalResourceObject("YourResourceFileName", key);
if (obj == null)
return key;
return obj.ToString();
}
这篇关于在设计时如何在网格视图中全局分配资源的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文