asp 树,c# 查找 指定节点
using System;
using System.Data;
using System.Configuration;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
namespace WA.IBMS.FindTreeNode //lxh 2008-9-16
{
/// <summary>
///SelectTreeNode 的摘要说明
/// </summary>
public class SelectTreeNode
{
public SelectTreeNode()
{
//
//TODO: 在此处添加构造函数逻辑
//
}
/// <summary>
/// 查找指定节点
/// </summary>
/// <param name="tnParent">节点</param>
/// <param name="strValue">值</param>
/// <returns></returns>
public TreeNode Find_Node(TreeNode tnParent, string strValue)
{
TreeNode treeNode2 = new TreeNode();
string venueCode = "";
if (tnParent == null) return null;
if (tnParent.Value == strValue) return tnParent;
&
相关文档:
今天在公司服务器上看一个老掉牙的asp程序,发现竟然调用了自定义com组件,是vb写的,封装了数据库连接与操作,文档上写这样做是为什么用户到服务器也看不到数据库的用户名与密码,也对啊,这个是财务的服务器,当然不能让我们it随便看了,呵呵!(it忽悠finance,让finance相信it看不到数据库用户名与密码,my god)由于, ......
/*
本段代码在公司项目中实际远程调用第三方公司提供的C#开发WebService的示例
*/
/**
* 登录游戏
*
* @param paramPN
* @param paramTerraceID
* @param paramSvrID
*/
private String loginGame(String paramPN, HttpServletRequest req){
&n ......
<%
'true=是邮件;false=不是;
Function validate(ByVal str)
Dim temp,reg
Set reg = new regexp
reg.ignorecase=true
reg.global=true
reg.pattern = "^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$"
validate = reg.test(Trim(str))
Set reg = Nothing
End Function
'************************ ......
程序代码
public static string GetRealIP()
{
string ip;
try
{
HttpRequest request = HttpContext.Current.Request;
if (request.ServerVariables["HTTP_VIA"] != null)
{
ip = request.ServerVariables["HTTP_X_FORWARDED_FOR"].ToString().Split(',')[0].Trim();
}
else
{
ip = requ ......
<%
SQL1 = "update table1 set a=b where id=1"
Conn.ExeCute SQL1
SQL2 = "update table2 set a=b where id=2"
Conn.ExeCute SQL2
SQL3 = "update table3 set a=b where id=3"
Conn.ExeCute SQL3
%>
&nb ......