vb Ëø¶¨Êó±êµ½Ä³Ò»Î»ÖÃ
Private Declare Function ClipCursor Lib "user32" (lpRect As Any) As Long
Private Type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Type
Private Sub Command1_Click() 'Ëø¶¨Êó±ê µ½Ä³Ò»Î»ÖÃ
Dim r As RECT
r.Left = 100: r.Top = 100
r.Right = 100: r.Bottom = 100
ClipCursor r
End Sub
Private Sub Command2_Click() '½â³ýËø¶¨
ClipCursor ByVal 0&
End Sub
'ÔÌûµØÖ·:
http://fy5388.blog.163.com/blog/static/5649953720091127115554104/
Ïà¹ØÎĵµ£º
'´óСд×Öĸת»»Æ÷vb
'½çÃæ°üÀ¨ command¡¢command1¡¢command2¡¢command3 ºÍÒ»¸ö text Îı¾¿ò
'command Ϊ“»¥×ª”°´Å¥£¬command1 Ϊ“ת´ó”°´Å¥£¬command2 Ϊ“תС”°´Å¥£¬command3 Ϊ“Çå³ý”°´Å¥
Private Sub Command_Click()
Dim i As Integer, n As Integer
Dim x As S ......
VBÖÐÀûÓÃCopyMemoryʹÓÃÖ¸Õë
¡¡¡¡Ò»¡¢Ö¸ÕëÊÇʲô£¿
¡¡¡¡²»ÐèҪȥÕÒʲô±ê×¼µÄ¶¨Ò壬Ëü¾ÍÊÇÒ»¸ö32λÕûÊý£¬ÔÚCÓïÑÔºÍÔÚVBÀï¶¼¿ÉÒÔÓÃLongÀàÐÍÀ´±íʾ¡£ÔÚ32λWindowsƽ̨ÏÂËüºÍÆÕͨµÄ32볤ÕûÐÍÊýûÓÐʲô²»Í¬£¬Ö»²»¹ýËüµÄÖµÊÇÒ»¸öÄÚ´æµØÖ·£¬ÕýÊÇÒòΪÕâ¸öÕûÊýÏóÕëÒ»ÑùÖ¸ÏòÒ»¸öÄÚ´æµØÖ·£¬ËùÒÔ¾ÍÓÐÁËÖ¸ÕëµÄ¸ÅÄî¡£
¡¡¡¡ÓÐÍ ......
¾Ý˵vb6ÖÐ,×Ö ·û´®ÒÔÒÔUNICODE·½Ê½´æ´¢£¬ËùÒÔ
Private Type UDT
lngM1 As Long
lngM2 As Long
strM3 As String * 18
strM4 As String * 8
lngM5 As Long
End Type
Private Sub Command4_Click()
Dim tmp As UDT
With tmp
.lngM1 = 1
.lngM2 = 2
' .str ......
delphiÖеÄDLLÖеÄÉùÃ÷ÔÂëÈçÏ£º
ÕâÀïÉùÃ÷ÁËÊä³öÐÔ²ÎÊý·Ö±ðΪÊý×ÖÓë×Ö·ûÀàÐÍ
library dll1;
uses
SysUtils,
Classes;
{$R *.res}
Function mymax(x, y: Integer; out jj: Integer; out abc: PChar): Integer; stdcall;
begin
jj := x * y;
abc := PChar(StrPas(abc) + 'ÕâÊÇ´«³öµÄ' ......
'******************************************************************************************
'* ÐèҪעÒâµÄÎÊÌâ *
'******************************************************************************************
'1.INIÎļþµÄ· ......