Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

BarCode Ëã·¨ VBÀà¿â 2

 
Option Explicit
Public Function ascii2Char(strInput As String) As String
Dim i As Integer
Dim strTemp As String
Dim nPos As Integer
Dim nValue As Integer
i = 1
nPos = InStr(i, strInput, "&#", vbTextCompare)
While (nPos > 0)
    ascii2Char = ascii2Char + Left(strInput, nPos - 1)
    strInput = Right(strInput, Len(strInput) - nPos + 1)
    i = 3
    strTemp = ""
    While (i <= Len(strInput) And IsNumeric(Mid(strInput, i, 1)) And Len(strTemp) < 3)
        strTemp = strTemp + Mid(strInput, i, 1)
        i = i + 1
    Wend
    nValue = 0
    If (strTemp <> "") Then nValue = Val(strTemp)
    If (nValue >= 0 And nValue < 128) Then
        ascii2Char = ascii2Char + Chr(nValue)
    ElseIf (nValue > 127 And nValue < 256) Then
        ascii2Char = ascii2Char + ChrW(nValue)
    Else
        ascii2Char = ascii2Char + Left(strInput, i - 1)
    End If
    If (i <= Len(strInput) And Mid(strInput, i, 1) = ";") Then
        i = i + 1
    End If
    strInput = Right(strInput, Len(strInput) - i + 1)
    nPos = InStr(1, strInput, "&#", vbTextCompare)
Wend
If (Len(strInput) > 0) Then
    ascii2Char = ascii2Char + strInput
End If
End Function
Public Function Code39(strToEncode As String) As String
Dim i As Integer
Dim charSet As String
Dim charToEncode As String
Dim charPos As Integer
Dim mappingSet As String
charSet = "0123456789.+-/ $%ABCDEFGHIJKLMNOPQRSTUVWXYZ"
mappingSet = "0123456789.+-/#$%ABCDEFGHIJKLMNOPQRSTUVWXYZ"
strToEncode = asci


Ïà¹ØÎĵµ£º

vb Ä£ÄâÊó±ê°´¼ü

 °ÑÊó±êÒÆµ½ÆÁĻָ¶¨Î»Öà È磨111.111£© µ¥»÷Ò»ÏÂ
ÔÙÒÆµ½ÆÁÄ»ÁíÒ»Ö¸¶¨Î»ÖÃÖ¸¶¨Î»Öà È磨222.222£©µ¥»÷Ò»ÏÂ
Private Declare Sub mouse_event Lib "user32" (ByVal dwFlags As Long, ByVal dx As Long, ByVal dy As Long, ByVal cButtons As Long, ByVal dwExtraInfo As Long)
Private Declare Function SetCursorPo ......

VBµÄput£¬getº¯Êý

 
Put Óï¾ä
½«Ò»¸ö±äÁ¿µÄÊý¾ÝдÈë´ÅÅÌÎļþÖС£
Put [#]filenumber, [recnumber], varname
Get Óï¾ä
½«Ò»¸öÒÑ´ò¿ªµÄ´ÅÅÌÎļþ¶ÁÈëÒ»¸ö±äÁ¿Ö®ÖС£
Get [#]filenumber, [recnumber], varname
ÀýÈ磺
dim B as byte
open "File1.txt" for binary as #1
get #1, 1, B
close #1
¼´¿É½«File1.txtÎļþµ ......

VBÏÂÈçºÎ±àдCRCУÑé³ÌÐò

 VBÏÂÈçºÎ±àдCRCУÑé³ÌÐò
¡¡¡¡Ëæ×żÆËã»ú¼¼ÊõµÄ²»¶Ï·¢Õ¹£¬ÔÚÏÖ´ú¹¤ÒµÖУ¬ÀûÓÃ΢»ú½øÐÐÊý¾ÝͨѶµÄ¹¤Òµ¿ØÖÆÓ¦ÓõÃÒ²Ô½À´Ô½¹ã·º¡£ÓÉÓÚ´«Êä¾àÀë¡¢ÏÖ³¡×´¿öµÈÖî¶à¿ÉÄܳöÏÖµÄÒòËØÓ°Ï죬¼ÆËã»úÓëÊÜ¿ØÉ豸֮¼äµÄͨѶÊý¾Ý³£»á·¢ÉúÎÞ·¨Ô¤²âµÄ´íÎó¡£ÎªÁË·ÀÖ¹´íÎóËù´øÀ´µÄÓ°Ï죬һ°ãÔÚͨѶʱ²ÉÈ¡Êý¾ÝУÑéµÄ°ì·¨£¬¶øÑ­»·ÈßÓàÂëУ ......

VBÈ¡µÃÏ߳̾ä±ú

 Private Declare Function OpenThread Lib "kernel32" (ByVal dwDesiredAccess As Long, ByVal bInheritHandle As Long, ByVal dwThreadId As Long) As Long
Private Const THREAD_ALL_ACCESS = &H1F03FF
 OpenThread(THREAD_ALL_ACCESS, 1, Ïß³ÌID)    'ÓÉÏß³ÌIDÈ¡µÃÏ߳̾ä±ú,·µ»ØÏß³Ì¾ä± ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ