张志峰的博客

水滴石川,积少成多。

导航

2013年9月27日

摘要: delphi编写dll心得1。每个函数体(包括exports和非exports函数)后面加 'stdcall;', 以编写出通用的dll2。exports函数后面必须加'export;'(放在'stdcall;'前面)3。对于非exports函数可以使用string类型,而且建议使用string类型进行参数传递4。对于exports函数请使用PChar类型做参数传递5。如果exports调用其他函数,建议在exports函数体内使用变量过渡,然后再调用其他函数; 也就是说:尽量不要把exports的参数再作为参数调用其他函数。6。exports函 阅读全文

posted @ 2013-09-27 17:45 ╰★张志峰★╮ 阅读(5246) 评论(0) 推荐(0)

摘要: 最近项目中,需要在一个bpl中调用另一个bpl中的单元的方法, 方法如下:在被调用的单元中定义:procedure Inner_Ex(VoucherType: TVoucherType);exports Inner_Ex;实现:procedure Inner_Ex(VoucherType: TVoucherType);var frm: tfrmaaa;begin frm := tfrmaaa.Create(Application); try frm.VoucherType := VoucherType; frm.ShowModal; finally frm.Free; end;end;在那个b 阅读全文

posted @ 2013-09-27 15:50 ╰★张志峰★╮ 阅读(1756) 评论(0) 推荐(0)

摘要: http://news.163.com/13/0927/09/99P6M2TA0001124J.html 阅读全文

posted @ 2013-09-27 12:37 ╰★张志峰★╮ 阅读(132) 评论(0) 推荐(0)

摘要: SQL Server 中有两个函数,语法: ISNULL(check_expression, replacement_value)check_expression 与 replacement_value 数据类型必须一致 如果 check_expression 为 NULL,则返回 replacement_value如果 check_expression 不为 NULL,则返回 check_expression NULLIF 用于检查两个表达式,语法: NULLIF(expression, expression) 如果两个 expression 相等,则返回 NULL,该 NULL 为第一个. 阅读全文

posted @ 2013-09-27 10:32 ╰★张志峰★╮ 阅读(332) 评论(0) 推荐(0)