惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

腾讯CDC
Schneier on Security
Schneier on Security
B
Blog RSS Feed
aimingoo的专栏
aimingoo的专栏
P
Proofpoint News Feed
A
About on SuperTechFans
Recorded Future
Recorded Future
Recent Announcements
Recent Announcements
Microsoft Security Blog
Microsoft Security Blog
L
LangChain Blog
Hugging Face - Blog
Hugging Face - Blog
The GitHub Blog
The GitHub Blog
Google DeepMind News
Google DeepMind News
T
Tailwind CSS Blog
Vercel News
Vercel News
H
Hackread – Cybersecurity News, Data Breaches, AI and More
MyScale Blog
MyScale Blog
V2EX - 技术
V2EX - 技术
N
Netflix TechBlog - Medium
F
Fortinet All Blogs
V
Visual Studio Blog
Martin Fowler
Martin Fowler
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
博客园 - Franky
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
T
The Exploit Database - CXSecurity.com
F
Full Disclosure
Scott Helme
Scott Helme
H
Heimdal Security Blog
博客园 - 叶小钗
Google DeepMind News
Google DeepMind News
Cyberwarzone
Cyberwarzone
Application and Cybersecurity Blog
Application and Cybersecurity Blog
V
Vulnerabilities – Threatpost
Blog — PlanetScale
Blog — PlanetScale
Security Latest
Security Latest
WordPress大学
WordPress大学
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
T
Troy Hunt's Blog
S
SegmentFault 最新的问题
Forbes - Security
Forbes - Security
Jina AI
Jina AI
S
Securelist
小众软件
小众软件
Simon Willison's Weblog
Simon Willison's Weblog
J
Java Code Geeks
AWS News Blog
AWS News Blog
N
News and Events Feed by Topic
博客园 - 三生石上(FineUI控件)
量子位

博客园 - 守兔待猪

几年没有写了,今天再来。。。 最近做了一个项目! 今天搬家啦! 值得收藏的精华代码!! DataGridXP终于出来了!!! DataGridXP基本思路已经有点头绪。 调查模板动态生成 今天周末了:) 服务器控件开发!! 周末没来 今天状态不错。 新建几个编码对照表 InstallShield For .Net制作.Net项目安装包之完整代码 成功抢救文档 Disk I/O error ……的处理方法 刚才她打电话来了。。。 Display Skin 当.NET遇到SYBASE 今天开通了我的博客园啦,先自己恭喜一下子。。。
如何确定某页面是否存在某控件的方法
守兔待猪 · 2004-10-13 · via 博客园 - 守兔待猪

此功能使用递归算法实现,根据控件的ID,在页面空间集合中递归查找:代码中两个break不能缺少。

  private System.Boolean FindControls(System.Web.UI.Control myPage,string ID)
  {
   System.Boolean ReturnStr = false;
   for (int i = 0; i < myPage.Controls.Count; i++)
   {
    if (myPage.Controls[i].ID == ID)
    {
     ReturnStr = true;
     break;
    }
    else
    {
     if (FindControls(myPage.Controls[i],ID))
     {
      ReturnStr = true;
      break;
     }
    }
   }
   return ReturnStr;
  }