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

vbÓÃapiµ÷ÓöԻ°¿ò

½¨Ò»¸öÄ£¿é
Public Declare Function GetOpenFileName Lib "comdlg32.dll" Alias "GetOpenFileNameA" (pOpenfilename As OPENFILENAME) As Long
Public Type OPENFILENAME
lStructSize As Long
hwndOwner As Long
hInstance As Long
lpstrFilter As String
lpstrCustomFilter As String
nMaxCustFilter As Long
nFilterIndex As Long
lpstrFile As String
nMaxFile As Long
lpstrFileTitle As String
nMaxFileTitle As Long
lpstrInitialDir As String
lpstrTitle As String
flags As Long
nFileOffset As Integer
nFileExtension As Integer
lpstrDefExt As String
lCustData As Long
lpfnHook As Long
lpTemplateName As String
End Type

´°ÌåÉÏ·ÅÒ»¸ö±à¼­¿òºÍ°´Å¥
Private Sub Command1_Click()
Dim ofn As OPENFILENAME
Dim strRtn As String
ofn.lStructSize = Len(ofn)
ofn.hwndOwner = Me.hwnd
ofn.hInstance = App.hInstance
ofn.lpstrFilter = "ËùÓÐÎļþ"
ofn.lpstrFile = Space(254)
ofn.nMaxFile = 255
ofn.lpstrFileTitle = Space(254)
ofn.nMaxFileTitle = 255
ofn.lpstrInitialDir = App.Path
ofn.lpstrTitle = "´ò¿ªÎļþ"
ofn.flags = 6148
rtn = GetOpenFileName(ofn)
If rtn >= 1 Then
Text1.Text = ofn.lpstrFile
Else
Text1.Text = "Cancel Was Pressed"
End If
End Sub


Ïà¹ØÎĵµ£º

VB±àдÍÐÅÌͼ±êʵÀý

VB±àдÍÐÅÌͼ±êÓÐÁ½¸öÒªµã£¬Ò»ÊÇʹÓà Shell_NotifyIcon º¯ÊýÏÔʾͼ±ê£»¶þÊÇÏòϵͳע²á TaskbarCreated ÏûÏ¢£¬ÒÔ±ãexplorer±ÀÀ£Ê±»Ö¸´ÍÐÅ̵Äͼ±ê¡£
Ê×ÏÈÐèÒªÔö¼ÓÒ»¸öÄ£¿éÎļþ£¬ÄÚÈÝÈçÏ£º
Public Declare Function Shell_NotifyIcon Lib "shell32.dll" Alias "Shell_NotifyIconA" (ByVal dwMessage As Long, lpData As NOT ......

ÈçºÎÓÅ»¯VB³ÌÐò

ÈçºÎÈ¥ÓÅ»¯ÄãµÄVB³ÌÐò°ïÖú 
1¡¢ÈçºÎÈ¥ÓÅ»¯ÄãµÄVB³ÌÐò
Visual Basic ×÷ΪһÖָ߼¶±à³ÌÓïÑÔ£¬ËüÒ²ÓÐ×Ų»¿É±ÜÃâµÄȱµã---¿ª·¢³öµÄÓ¦ÓóÌÐòÔËÐÐËÙ¶ÈÂý¡£Èç¹ûÎÒÃÇÄܹ»³ÌÐò×öһЩÓÅ»¯£¬ÄÇôÇé¿ö½«»á´ó´ó¸ÄÉÆ¡£ÒªÓÅ»¯³ÌÐòÔËÐеÄʵ¼ÊËÙ¶È£¬³£Óõķ½·¨ÓÐÈýÖÖ£º
1.¾¡Á¿±ÜÃâʹÓà Variant ±äÁ¿¡£ÓÉÓÚVB²»ÄÜÈ·¶¨ Variant ±äÁ¿µÄ¾ ......

VBÓëFTP±à³Ì

Option Explicit
Private Const INTERNET_OPEN_TYPE_DIRECT = 1
Private Const scuseragent = "vb wininet"
Private Const INTERNET_FLAG_PASSIVE = &H8000000
'µ÷ÓÃÉèÖû·¾³
Private Declare Function InternetOpen Lib "wininet.dll" Alias "InternetOpenA" (ByVal sAgent As String, ByVal lAccessType As Long ......

VB²Ù×÷WORD

 Dim wdapp As Word.Application
    Dim wddoc As Word.Document
    Dim wdtable As Word.Table
   
    Set wdapp = CreateObject("word.application")
   
    Set wddoc = wdapp.Documents.Add
   ......

VBÁù¸öÊýÈ¡×î´óÖµºÍƽ¾ùÊýµÄƽ·½

VERSION 5.00
Begin VB.Form Form2
   AutoRedraw      =   -1  'True
   Caption         =   "¼ÆËã½çÃæ"
   ClientHeight    =   4905
   ClientLe ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ