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

VB ¶ÁÖ¸¶¨ÐÐ

http://zhidao.baidu.com/question/81532606.html
VB ¶ÁÖ¸¶¨ÐÐ
ÐüÉÍ·Ö£º10 - ½â¾öʱ¼ä£º2009-1-20 11:41
vbÖÐÈçºÎ¶ÁÈ¡Ö¸¶¨ÐеÄÄÚÈÝ£¬´°ÌåÉÏÓÐÁ½¸ö±êÇ©£¬ÎļþÔÚC:\A.TXT,Ëĸö°´Å¥£¬µ¥»÷µÚÒ»¸ö£¬¶ÁÎļþµÄµÚÒ»Ðе½±êÇ©Ò»£¬µÚ¶þÐе½±êÇ©¶þ£»µ¥»÷µÚ¶þ¸ö°´Å¥£¬µÚÈýÐе½±êÇ©Ò»£¬µÚËÄÐе½±êÇ©¶þ£»ÒÔ´ËÀàÍÆ£¬Ð»Ð»
ÌáÎÊÕߣº imyangmo - ÊéÉú ¶þ¼¶
×î¼Ñ´ð°¸
ÓÃÎļþϵͳ¿ÉÒÔ¶ÁÈ¡Ö¸¶¨ÐС£¡£¡£µ«ÊÇÈç¹ûÎļþÄÚÈݲ»ÊǺܶàµÄ»°ÓÃ˳ÐòÎļþÈ«²¿¶Á³öÀ´½Ø¶Ïµ½Êý×éºóÌáÈ¡Ö¸¶¨Ðиü·½±ã¡£¡£¡£
ʹÓÃÎļþϵͳ¶ÁÈ¡Ö¸¶¨ÐУº
Ê×ÏÈÐèÒª“ÒýÓÔMicrosoft Scripting Runtime
Private Sub Command1_Click()
Dim FSO As New FileSystemObject
Dim TS As TextStream
Dim Str As String
If Dir("C:\A.txt") <> "" Then 'ÅжÏÎļþÊÇ·ñ´æÔÚ
Set TS = FSO.OpenTextFile("C:\A.txt", ForReading) 'ForReadingΪ¶Áģʽ,ÁíÍâÓÐдºÍ×·¼Óģʽ
Do Until TS.Line = 1 'Ìøµ½Ö¸¶¨ÐÐʱÖÕֹѭ»·
TS.SkipLine 'Ìø¹ýÒ»ÐÐ
Loop
Str = TS.ReadLine '¶Á³öÐÐ,Îļþϵͳ¶ÁдλÖþÍÊǹâ±êËùÔÚµÄλÖÃ
Print Str
Else
MsgBox "Îļþ²»´æÔÚ£¡"
End If
'µ«ÊÇÎļþϵͳºÃÏñ²»ÄÜдָ¶¨ÐÐ
End Sub
----------------------------------------------------------------
ʹÓÃ˳ÐòÎļþ»ñÈ¡Ö¸¶¨ÐÐÄÚÈÝ
Private Sub Command1_Click()
Dim Arr
Dim Str As String
Dim i As Integer
Open "C:\A.txt" For Binary As #1
Str = StrConv(InputB(LOF(1), 1), vbUnicode)
Close #1
Arr = Split(Str, vbCrLf)
For i = 0 To UBound(Arr)
Print Arr(i)
Next i
End Sub


Ïà¹ØÎĵµ£º

VB³ÌÐòÆƽâ

VB³ÌÐòÆƽâ
VB ³ÌÐò¼ò½é
¡¡¡¡ÏÖÔÚ²»ÉÙ³ÌÐòÊÇÓà VB дµÄ£¬Äãͨ¹ý·´»ã±à»ò¸ú×Ùµ÷ÊÔʱºÜÈÝÒ×¼ø±ðij¸ö³ÌÐòÊÇ·ñΪ VB ³ÌÐò£¬VB µÄ EXE Îļþ²¢²»ÊÇÕæÕýµÄ±àÒë¿ÉÖ´ÐÐÎļþ£¬ËüÃÇÐèÆ䶯̬Á´½Ó¿â²ÅÄÜÕý³£ÔËÐУ¬¸÷°æ±¾µÄÁ´½Ó¿âÈçÏ£º
VB3 Á´½Ó¿âΪ vbrun300.dll £»
VB4 Á´½Ó¿âΪ  vb40016.dll £» - 16 룬½ÏÉÙ¼û£»
VB4 ......

һЩVBÏà¹ØµÄ¶«Î÷~~


Õä¹óvbº¯ÊýÁбí
Variant ±äÁ¿µÄÄÚ²¿±íʾ:
_______________________________________________________________
·ûºÅ³£Á¿ Öµ ÄÚ²¿±íʾ ×Ö½ÚÊý
V_EMPTY 0 Empty
V_NULL 1 Null
V_INTEGER 2 Interger 2
V_LONG 3 Long 4
V_SINGLE 4 Single 4
V_DOUBLE 5 Double 8
V_CURRENCY 6 Currency 8
V_DATE 7 Date 8
V_STRI ......

VBµ÷ÓÃϵͳµÄ"´òÓ¡»úÉèÖÃ"ºÍ"Ò³ÃæÉèÖÃ".

VBµ÷ÓÃϵͳµÄ"´òÓ¡»úÉèÖÃ"ºÍ"Ò³ÃæÉèÖÃ".
Option Explicit
Const FW_NORMAL = 400
Const DEFAULT_CHARSET = 1
Const OUT_DEFAULT_PRECIS = 0
Const CLIP_DEFAULT_PRECIS = 0
Const DEFAULT_QUALITY = 0
Const DEFAULT_PITCH = 0
Const FF_ROMAN = 16
Const CF_PRINTERFONTS = &H2
Const C ......

VBÖд°ÌåÄ£¿é¡¢±ê׼ģ¿é¡¢ÀàÄ£¿éµÄÇø±ð

VBµÄ´úÂë´æ´¢ÔÚÄ£¿éÖС£ÔÚVBÖÐÌṩÁËÈýÖÖÀàÐ͵ÄÄ£¿é£º´°ÌåÄ£¿é¡¢±ê׼ģ¿éºÍÀàÄ£¿é¡£
¡¡¡¡¼òµ¥µÄÓ¦ÓóÌÐò¿ÉÒÔÖ»ÓÐÒ»¸ö´°Ì壬ËùÓõijÌÐò¶¼×¤ÁôÔÚ´°ÌåÄ£¿éÖУ¬¶øµ±Ó¦ÓóÌÐòÅÓ´ó¸´ÔÓʱ£¬¾ÍÒªÁíÍ⸽¼Ó´°Ìå¡£×îÖÕ¿ÉÄÜÓм¸¸ö´°ÌåÖÐÓÐһЩ¹²Í¬¶¼ÒªÖ´ÐеĴúÂ룬ΪÁËÔÚÁ½¸ö´°ÌåÖв»²úÉúÖظ´´úÂ룬¿É´´½¨Ò»¸ö¶ÀÁ¢µÄÄ£¿é£¬ÓÃËüʵÏÖ´ú ......

vbʹÓÃpicturebox»­ÇúÏßͼ

'Ìí¼Ó¸öpicture1ºÍcommand1
Option Explicit
Dim lngCenter As Long
Dim lngMax As Long
Dim lngPad&
Dim PCurrent As POINT, PLast As POINT
Private Type POINT
x As Long
y As Long
End Type
Private Sub Form_Load()
lngCenter = (Picture1.Top + Picture1.Height) / 2
lngMax = Pictu ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ