自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

夏华成

jQuery .net wp7

  • 博客(57)
  • 收藏
  • 关注

原创 jQuery复习之---所有知识点总结

jQuery顶级对象 缩写$ window.jQuery window.$第一部分,找对像其本选择器 $("#id") $(".class") $("input") 复合选择器 $("#id,.class,input")层次选择器 $("div p") 包含选择器 div中所有的p 子元素 子子元素.. $("div > p") 子后代选择器 div中直接子后代

2012-08-26 17:28:10 1326

原创 jQuery复习之---常用代码

1.换肤。开关。追加样。文本框得到焦点,背景变红$(document.body).toggleClass("deng"); $(function () { $(":button[value=red]").click(function () { $("#css").attr("href", $(this).attr

2012-08-25 21:04:59 558

原创 js复习之-dom编程[常用代码]

刷新 function red() { window.location.reload(); }跑马灯,定时器 var trmid1; var trmid2; function lf() { if (trmid2) { clearInterval(t

2012-08-23 17:40:55 584

原创 js复习之-面向对像

函数就是对象,对象就是函数。 var Person = function (name, age) { this.name = name; this.age = age; this.sayHi = function () { return this.age + "-" + this.n

2012-08-23 15:25:36 350

原创 js复习之-函数

//================================得到参数 function add(num1) { //alert(arguments.length); var n = arguments[0]; for (var i = 1; i < arguments.length; i++) {

2012-08-23 15:07:57 459

转载 js复习之--Date对像

Date 对象Date 对象用于处理日期和时间。创建 Date 对象的语法:var myDate=new Date()注释:Date 对象会自动把当前日期和时间保存为其初始值。Date 对象属性FF: Firefox, IE: Internet Explorer属性描述FFIEconstructor

2012-08-23 14:57:39 371

原创 js复习之--String对像

var str = "asd我ADGSE我~爱.北京"; window.document.write(str.length + ""); window.document.write(str.charAt(1) + ""); window.document.write(str.indexOf("d我", 0) + ""); window

2012-08-23 14:02:17 535

原创 js复习之-Array对像

数组的四种申明方式 var arr = new Array(); arr[0] = "asdf"; arr[1] = "23"; arr[2] = "fds1"; alert(arr.length); var arr = ["asdf", "234234", "fsda"]; aler

2012-08-23 13:25:14 342

原创 js复习-数值处理和数学对像

// / % 求余数 (保留整数) //小数点后保留N位 var num = parseInt("21121.12"); alert(num); var numi = parseFloat("21313.14"); alert(numi); var num1 = new Number("12123.

2012-08-23 13:15:26 658

原创 js复习之-基本语法及数据类型

//流程控制-选择语句 var a = "123"; switch (a) { case 123: window.document.writeln("数字"); break; case "123": window.docum

2012-08-23 12:20:47 523

原创 treeView的一些常用用法

递归加载   这里有点不好理解。先写个函数得到父ID下的子节点        /// /// 根据pid获取所有的子类别 /// /// /// public List GetScriptsByParentId(int pid) { List list = ne

2012-06-27 13:52:18 622

原创 汉字转拼音。简繁体互转。ChnCharInfo.dll,ChineseConverter.dll

汉字转拼音using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using Micro

2012-06-25 23:24:44 3697

原创 FtpClient 类来操作FTP的上传和下载,带进度条

先给出FtpClient 类(还没有做完。明天继续)using System;using System.Collections.Generic;using System.Net;using System.IO;using System.Windows.Forms;namespace FTPXHC{ /// /// FTP客户端操作类 /// p

2012-06-25 22:46:25 4613

原创 通过WebClient操作ftp

#region 下载! //WebClient wc = new WebClient(); //wc.Credentials = new NetworkCredential("yzk", "1234"); //wc.DownloadFile("ftp://192.168.1.100/顶.gif", @"c:\a.gif");

2012-06-25 18:15:39 2714

原创 通过反射获取SqlConnection连接池中的连接字符串

string constr = "Data Source=.;Initial Catalog=xhc;Integrated Security=True"; //获取类型中的私有成员 PropertyInfo pInfo = typeof(SqlConnection).GetProperty("InnerConnection",

2012-06-25 18:12:57 955

原创 NPOI.dll 用法。单元格,样式,字体,颜色,行高,宽度。读写excel

我用的版本是1.25的。每个版本用法有一点不同using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows

2012-06-24 10:49:47 13873 6

原创 .net中MD5使用方法

using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Security.Cryptography;using System.IO;namespace MD5练习{ public static class MD5String {

2012-06-23 10:37:40 1365

原创 教你怎么使用sql游标

--1.将每个老师的工资更新为原来的工资+奖金--定义两个变量,用来存储ttid与rewarddeclare @tid intdeclare @reward money--1。建立一个基于奖金表的游标declare cur_reward cursor fast_forward for select ttid,reward from TblTeacherSalary--2.打开游标

2012-06-23 09:29:10 648

原创 2012.6.19.sql不常用函数总结,以及事务,增加,删除触发器

distinct 删除重复行declare @x 申明一个变量convert(varchar(20),tscore.tenglish) 类型转换 cast(xx as varchar(10)) 类型转换======================================================情况case   when  xxx  then xx

2012-06-19 19:22:34 1855 1

原创 多条件搜索,sql语句,决对经典的拼接写法

大家在做多条件的搜索时,最常用的办法是用ifelse 里面嵌套很多个。 当有五六个以上条件时,可以说写的直接崩溃了。 现在给大家介绍一个经典的拼接写法string sql = "select * from zhiyuan"; List listsql = new List();

2012-06-18 23:15:49 1503

原创 SqlDataAdapter;DataSet;DataTable;DataTableCollection 关联

SqlDataAdapter;DataSet;DataTable;DataTableCollection  SqlDataAdapter 一个桥梁用来从数据库获取数据 用来填充到 dataset 或 datatable中 dataset 就要当于一个数据库,也就是说可以包含多个表(datatable); datatable 就是一个表  也相当于 DataSet的

2012-06-17 15:03:58 2244

原创 .net隐式类型转换

class Program { static void Main(string[] args) { //显示转换 //Person p1 = (Person)10; //隐式类型转换 //Person p = 10; // Co

2012-06-15 20:10:10 776

原创 sql 不常用函数集合。mssql

--执行插入语句返回刚刚生成的自动编号insert into TblClass output inserted.tclassId values('xxx','..');--top 数字后加percent表示百分比,如果百分比最后计算出来的条数中有小数,则直接进位。select top 30 percent * from MyStudent order by fage desc--==

2012-06-14 19:16:03 1397 2

原创 数据库 基本sql应用

创建表create table x( id int identity(1,1) primary key,)drop table x创建数据库create database schoolon primary( name='school', size=10mb, filename='c:\school.mdf')log on( name='sch

2012-06-14 19:01:49 1232 3

原创 2012.6.12 .net自定义xml序列化及自定义特性

using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Xml.Linq;using System.IO;using System.Xml.Serialization;using System.Reflection;namespace 自定义xml序

2012-06-13 18:24:50 686

原创 2012.6.12 .net 反射

using System.Reflection;反射就是动态加载程序集的元数据 反射有两种方式第一种直接 把对像反射Type t=Typeof(对像) 第二种从程序集加载Assembly asm = Assembly.LoadFile(path);得到是一个集合List li = new List(); li = asm.GetTypes().T

2012-06-12 23:08:35 442

原创 2012.6.11 .net深拷贝和浅拷贝

定义不管是深拷贝和浅拷贝 都是两个不同的对象 什么是深拷贝对像中的引用类型,在堆中是指向了两个不同的地方 什么是浅拷贝对像中的引用类型,在堆中是指向了两个相同的地方using System.Runtime.Serialization.Formatters.Binary; #region 浅拷贝 //Person p1 = new Pers

2012-06-11 21:28:51 1618

原创 2012.6.11XmlDocument xpath

XmlDocument xmldoc = new XmlDocument();            xmldoc.Load(@"c:\test.xml");            XmlNodeList nodeList = xmldoc.SelectNodes("//items[@name=\"520link\"]");            foreach (XmlNode it

2012-06-11 21:21:35 241

原创 2012.6.11 加载xml到treeView 上

XDocument doc = XDocument.Load(@"c:\test.xml"); XElement root = doc.Root; TreeNode tn= treeView1.Nodes.Add(root.Name.ToString()); getxml(tn, root);

2012-06-11 20:53:36 315

原创 2012.6.11 xml读。写

xml 读加载xml文件XDocument doc = XDocument.Load("xl.xml");获取xml的根节点XElement xe = doc.Root; 获取xe节点下的 items节点 XElement its = xe.Element("items"); 获取xe节点下的所有子节点List item = its.Elements().T

2012-06-11 20:51:47 404

原创 2012.6.10 反射,插件制做

对外接口:using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Windows.Forms;namespace 对外接口{    public interface Ijiekou    {        string Name

2012-06-10 21:47:28 257

原创 2012.6.10 事件

事件也是 委托事件和委托用法一样 只是赋值的时候只能用 += class Program { static ShaoShui ss = new ShaoShui(); static void Main(string[] args) { // ss.evshaoshui = ss_evshaoshui;

2012-06-10 20:26:05 315

原创 2012.6.10关于委托和对象的多态?

对象多态先把可能的几种方法写在类里,在程序调用的时候   实例父类的子类类型,进行调用 委托我也觉得是多态的体现委托,是一个方法变量。这方法一定是变量的。这也相当于是一个多态的体现吧 委托只有多态特征而多态只是对象的其中一个特性心存疑惑,但又不知道疑惑在哪里

2012-06-10 11:24:48 263

原创 2012.6.8委托的理解和其本用法

什么是委托委托就是一种数据类型,是引用类型,其实就是一个类 既然是一种数据类型,就可以被申明,赋值,和作为参数传递 那他是怎样一种数据类型呢他就是用来存储方法的数据类型当然我们需要传递一个方法时,可用到委托,非常方便 例子1 public delegate void Getdelegate();//申明委托 public class Class1

2012-06-10 10:11:28 253

原创 2012.6.7正则表达式 分组用法

Regex rx = new Regex(@"[A-Z0-9a-z\.\-_]+@([a-z0-9]+)\.[a-z0-9A-z]"); string html = File.ReadAllText("1.htm"); //提取Email, //通过()提取组。 //fd(s(a(f

2012-06-07 20:11:43 1192

原创 2012.6.7文件序列化/反序列化

//序列化 //Person p=new Person(); //p.Name="夏华成"; //p.Age=29; //BinaryFormatter bf = new BinaryFormatter(); //using(FileStream fs=new FileStrea

2012-06-07 19:12:04 993

原创 WeakReference 弱引用

string srr = "123";WeakReference wr = new WeakReference(srr);            srr = null;            object o = wr.Target;            if (o != null)            {                Console.WriteLin

2012-06-06 21:07:24 348

原创 2012.6.6文件操作,大文件传输

public Form1() { InitializeComponent(); label1.Text = ""; System.Windows.Forms.Control.CheckForIllegalCrossThreadCalls = false; } private

2012-06-06 14:30:53 279

原创 2012.6.6文件操作实例(树型)

文件操作(树形)TreeNode trn;trn = treeView1.Nodes.Add("打开查找");getfiles(ppath, trn);#region 递归          void getfiles(string path, TreeNode tn)        {            try            {

2012-06-06 14:28:17 268

原创 2012.6.6文件操作

Path目录和文件操作的命名控件System.IOstring ChangeExtension(string path, string extension) (*)修改文件的后缀,“修改”支持字符串层面的,没有真的给文件改名string s = Path.ChangeExtension(@"C:\temp\F3.png", "jpg")string Combine(stri

2012-06-06 14:25:33 290

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除