12 2011 档案

摘要:C#可以直接对内存进行操作。但是默认情况下,为了保持类型安全,C#不支持指针运算。不过,通过使用 unsafe 关键字,可以定义可使用指针的不安全上下文。在不安全的上下文中,类型可以是指针类型以及值类型或引用类型。指针类型声明具有下列形式之一:unmanaged type* identifier;void* identifier;参数说明:unmanaged type:sbyte、byte、short、ushort、int、uint、long、ulong、char、float、double、decimal 或 bool。任何枚举类型。任何指针类型。仅包含非托管类型的字段的任何用户定义的结构类型 阅读全文
posted @ 2011-12-30 14:13 szjdw 阅读(333) 评论(0) 推荐(0) 编辑
摘要:1.web.config里加<authentication mode="Forms"> <forms name=".ASPXAUTH" loginUrl="Login.aspx" defaultUrl="default.aspx" protection="All" timeout="30" path="/"> </forms></authentication><authorization> < 阅读全文
posted @ 2011-12-30 14:06 szjdw 阅读(415) 评论(0) 推荐(0) 编辑
摘要:先把Winista.HtmlParser.dll放到bin文件夹下面。using System;using System.Collections.Generic;using System.Text;using Winista.Text.HtmlParser.Visitors;using Winista.Text.HtmlParser;using Winista.Text.HtmlParser.Util;//包含ParserExceptionusing Winista.Text.HtmlParser.Filters;using System.Net;using Winista.Text.Html 阅读全文
posted @ 2011-12-29 11:10 szjdw 阅读(377) 评论(0) 推荐(0) 编辑
摘要:Response.Write("<script language=\"javascript\">alert('请检查您的输入!')</script>"); 阅读全文
posted @ 2011-12-28 10:10 szjdw 阅读(99) 评论(0) 推荐(0) 编辑
摘要:#region "根据文件扩展名获取当前目录下的文件列表" /// <summary> /// 根据文件扩展名获取当前目录下的文件列表 /// </summary> /// <param name="FileExt">文件扩展名</param> /// <returns>返回文件列表</returns> public static List<string> GetDirFileList(string FileExt) { List<string> FilesL 阅读全文
posted @ 2011-12-27 16:35 szjdw 阅读(267) 评论(0) 推荐(0) 编辑
摘要:1,先在http://nodejs.org/下载node-v0.6.6.msi,马上安装吧!2.var http = require('http'); http.createServer(function (req, res) { res.writeHead(200, {'Content-Type': 'text/plain'}); res.end('Hello World\n'); }).listen(1337, "127.0.0.1"); console.log('Server running at 阅读全文
posted @ 2011-12-27 14:45 szjdw 阅读(118) 评论(0) 推荐(0) 编辑
摘要:<%-- Name:Author: Description: --%><%@ CodeTemplate Language="C#" TargetLanguage="C#" ResponseEncoding="UTF-8" Src="" Inherits="" Debug="False" Description="Template description here." %><%@ Property Name="Tabl 阅读全文
posted @ 2011-12-26 19:15 szjdw 阅读(170) 评论(0) 推荐(0) 编辑
摘要:@@identity表示最近一次向具有identity属性(即自增列)的表插入数据时对应的自增列的值,是系统定义的全局变量。一般系统定义的全局变量都以@@开头,用户自定义的变量以@开头。比如有个表A,它的自增列是id。当向A表插入一行数据后,如果插入数据后自增列的值自动增加到101,则通过select @@identity得到的值就是101。使用@@identity的前提是使用了insert操作,执行select @@identity时连接没有关闭,否则得到的将是NULL。IDENT_CURRENT 返回为任何会话和任何作用域中的特定表最后生成的标识值。IDENT_CURRENT 不受作用域和 阅读全文
posted @ 2011-12-24 14:53 szjdw 阅读(793) 评论(0) 推荐(0) 编辑
摘要:<%-- Name:Author: Description: --%><%@ CodeTemplate Language="C#" TargetLanguage="C#" ResponseEncoding="UTF-8" Src="" Inherits="" Debug="False" Description="Template description here." %><%@ Property Name="Tabl 阅读全文
posted @ 2011-12-23 18:49 szjdw 阅读(231) 评论(0) 推荐(0) 编辑
摘要:$(document).ready(function () {// $(".main").height($(".main_left").height() > $(".main_left").height() ? $(".main_left").height() : $(".main_left").height()); alert($(".main").height());// $("#test").html($(".menu_block&q 阅读全文
posted @ 2011-12-23 15:03 szjdw 阅读(74) 评论(0) 推荐(0) 编辑
摘要:test.cst<%@ CodeTemplate Language="C#" TargetLanguage="Text" Src="" Inherits="" Debug="False" CompilerVersion="v3.5"Description="Template description here." %><%@ Assembly Name="SchemaExplorer" %><%@ Impor 阅读全文
posted @ 2011-12-21 17:30 szjdw 阅读(125) 评论(0) 推荐(0) 编辑
摘要:理解了一个深刻的道理: 接手别人留下的半成品,怎么做? 不保证系统数据正确,确保查询的数据是预期的。即能查到正确的原始数据,然后越走越好!后来多次建议修改系统皆未果,为什么?没有完美的产品,只要有人参与就会完美。没有必要需要完美的产品,工具+人,只要快速完美的解决问题就行! 阅读全文
posted @ 2011-12-21 16:06 szjdw 阅读(150) 评论(0) 推荐(0) 编辑
摘要:declare @prdtid char(7)declare @date_str char(4)declare @date_int intdeclare @sql nvarchar(3000)declare @bigc intdeclare @cop char(2)set @bigc=1set @cop='02'if object_id('tempdb.dbo.#class') is nullbegincreate table #class(ClassID nvarchar(15),bigc int)endtruncate table #classinsert 阅读全文
posted @ 2011-12-20 14:55 szjdw 阅读(170) 评论(0) 推荐(0) 编辑
摘要:declare @mouth int declare @start nvarchar(20) declare @end nvarchar(20) declare @sql nvarchar(3000) set @mouth=1 while @mouth<=12 begin if @mouth=12 begin set @start='2011-'+ltrim(rtrim(STR(@mouth)))+'-1' set @end='2012-'+ltrim(rtrim(STR(1)))+'-1' end else begin s 阅读全文
posted @ 2011-12-19 16:51 szjdw 阅读(159) 评论(0) 推荐(0) 编辑
摘要:declare @mouth int --declare @start datetime --declare @end datetime declare @start nvarchar(20) declare @end nvarchar(20) declare @str nvarchar(3000) declare @sql nvarchar(3000) set @mouth=1 while @mouth<=12 begin if @mouth=12 beginset @start='2011-'+STR(@mouth)+'-1'--set @start= 阅读全文
posted @ 2011-12-19 16:07 szjdw 阅读(165) 评论(0) 推荐(0) 编辑
摘要:1,cast:将某种数据类型的表达式显式转换为另一种数据类型。CAST 和 CONVERT 提供相似的功能。语法使用 CAST:CAST ( expression AS data_type ) as : sql里列的别名建议:象cast, as 之类的都是sql 语句里的关键字,在查询分析器里,选择后,按F1+SHIFT就可以查询帮助。2,使用str函数 语法 STR ( float_expression [ , length [ , decimal ] ] ) 参数 float_expression 是带小数点的近似数字 (float) 数据类型的表达式。不要在 STR 函数中将函... 阅读全文
posted @ 2011-12-19 14:50 szjdw 阅读(186) 评论(0) 推荐(0) 编辑
摘要:test.cst:<%@ CodeTemplate Language="C#" TargetLanguage="Text" Src="" Inherits="" Debug="False" CompilerVersion="v3.5" Description="Template description here." %><%-- 加载访问数据库的组件SchemaExplorer,并声明其使用的命名空间 --%><%@ Asse 阅读全文
posted @ 2011-12-17 18:31 szjdw 阅读(151) 评论(0) 推荐(0) 编辑
摘要:string ls_cop,ls_copsdeclare cop_cursor cursor for select cop_id from sys_cop where operations_center is not null and operations_center<>"" and operations_center=:ai_center using sqlca;open cop_cursor; fetch cop_cursor into :ls_cop;do while sqlca.sqlcode=0 ls_cops=ls_cops+",&quo 阅读全文
posted @ 2011-12-17 11:15 szjdw 阅读(305) 评论(0) 推荐(0) 编辑
摘要:应该说,PDF文档的规范性使得浏览者在阅读上方便了许多,但倘若要从里面提取些资料,实在是麻烦的可以。回忆起当初做毕业设计时规定的英文翻译,痛苦的要命,竟然傻到用Print Screen截取画面到画图板,再回粘到word中。1、实现工具:Office 2003中自带的Microsoft Office Document Imaging 应用情景:目前国外很多软件的支持信息都使用PDF方式进行发布,如果没有Adobe Reader,无法查看其内容,如果没有相关的编辑软件又无法编辑PDF文件。转换为DOC格式则可以实现编辑功能。尽管有些软件也可以完成PDF转换为DOC的工作,但很多都不支持中文,我们. 阅读全文
posted @ 2011-12-17 10:18 szjdw 阅读(240) 评论(0) 推荐(0) 编辑
摘要:当需要从数据库中同时读取多条记录的时候,就需要使用游标进行操作。游标CURSOR是一个与SELECT语句相关联的符号名,游标的最大好处是可以让用户逐行的访问表中的记录。使用游标的典型的过程如下: 1)用DECLARE关键字声明游标。 2)使用OPEN语句打开游标 3)使用FETCH语句读取一行数据 4)处理数据 5)判断是否已经读取完所有的数据,未读完数据的话,GOTO步骤3 6)使用CLOSE关键字关闭游标 (1)DECLARE 语句 在使用游标之前,需要使用DECLARE语句声明游标,使用DECLARE语句声明游标的格式如下: DECLARE CursorName CURSOR FOR S 阅读全文
posted @ 2011-12-16 19:27 szjdw 阅读(223) 评论(0) 推荐(0) 编辑
摘要:1.如何让存储文件目录的列,显示图片? 答:选择对应的column的display as picture属性为true 2、如何复制grid类型的所选择的行的数据到系统剪切板?答:string ls_selectedls_selected=dw_1.Object.DataWindow.Selected.Dataclipboard(ls_selected)3、如何复制graph风格的datawindow中的图形到剪切板?答:dw_1.clipbord("gr_1")4、如何设置的DW底色?在DW的editsource中改变color的值5、如何将Grid风格改成自由格式?在D 阅读全文
posted @ 2011-12-15 18:22 szjdw 阅读(365) 评论(0) 推荐(0) 编辑
摘要:长沙销售10:44:09??物流10:44:20这个怎么回事啊!长沙销售10:45:37这个是我点发货 的时候点错了。客户退货了的。长沙销售10:46:02他们东莞都没发货。为什么要退货入库呢。陈东跃(物流) 10:49:32现在我是不会处理了,现在多了一个库存客服总监 10:50:38如果是操作失误库存不准的,请及时打报告申请处理 阅读全文
posted @ 2011-12-15 11:02 szjdw 阅读(94) 评论(0) 推荐(0) 编辑
摘要:1,返款470元是在订单中作为备注说明的作用,销售金额及应收是17700元,财务要先收客户17700元,业务员再以费用形式报470元返款付给中间人。而不是客户2,应收金额应大于或等于销售金额,销售金额=数量*单价 应收金额=销售金额+运费-折扣-使用e币,返款不在应收款中扣减只作备注说明。3,你理解的运费是实际发生的运费和物流费用(送货费用),由物流或授权人根据物流单据录入系统里的费用,不是业务员录进去的。而销售单上的运费是应收客户的运费还没发生的,就是应有客户承担的费用,所以是应收款的一个组成部分,是业务中录入销售单时录入的。这是两码事不能混为一谈。例如:销售某项商品价值低于500元,我司应 阅读全文
posted @ 2011-12-14 16:05 szjdw 阅读(500) 评论(0) 推荐(0) 编辑
摘要:...dw_1.dataobject=d_prdtorder_view_cust...if ls_refno<>"" thendw_1.dataobject="d_prdtorder_saleno"dw_1.settransobject(sqlca)dw_1.retrieve(ls_refno)elsedw_1.retrieve(ll_cid)end if 阅读全文
posted @ 2011-12-13 19:07 szjdw 阅读(213) 评论(0) 推荐(0) 编辑
摘要:事件ID是pbm_keydown下输入代码如下:if keydown(keyenter!) then cb_2.TriggerEvent(clicked!)end if就可实现点击按钮的效果了! 阅读全文
posted @ 2011-12-13 16:14 szjdw 阅读(241) 评论(0) 推荐(0) 编辑
摘要:以下是全部代码:using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Diagnostics;using System.Threading;using System.Runtime.InteropServices;namespace ConsoleApplication1{ public static class CodeTimer { public static void Initialize() { Process.GetCurrentProcess(). 阅读全文
posted @ 2011-12-09 19:06 szjdw 阅读(143) 评论(0) 推荐(0) 编辑
摘要:Twitter大量使用Memcached,MQ也是基于Memcached 协议的,Memcached并不是新鲜的东西,但是由于它强大的影响力,有必要深入一下,这篇主要讲它的基础:1.Memcached是什么?Memcached 是一个高性能的分布式内存对象缓存系统,用于动态Web应用以减轻数据库负载。它通过在内存中缓存数据和对象来减少读取数据库的次数,从而提供动态、数据 库驱动网站的速度。Memcached基于一个存储键/值对的hashmap。其守护进程(daemon )是用C写的,但是客户端可以用任何语言来编写,并通过memcached协议与守护进程通信。但是它并不提供冗余(例如,复制其ha 阅读全文
posted @ 2011-12-06 22:50 szjdw 阅读(249) 评论(0) 推荐(0) 编辑