ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

[µo°Ý] VBA°õ¦æ®Éµo¥Í°õ¦æ¶¥¬q¿ù»~''91''

[µo°Ý] VBA°õ¦æ®Éµo¥Í°õ¦æ¶¥¬q¿ù»~''91''

[ª©¥DºÞ²z¯d¨¥]
  • ¤p»x(2010-5-26 10:36): ¤£¯à¶Çªþ¥ó?§A¤£¬O³£¤w¸g¤W¶Çªþ¥óÀɮפF

¥»©«³Ì«á¥Ñ Hsieh ©ó 2010-5-26 16:36 ½s¿è

¤p§Ì¹J¨ì¤@­Ó°ÝÃD

´N¬O¤p§Ì¦pªG¥ý«ö¦p¤U¹Ïªº¶¶§Ç¡A¨Ó°õ¦æ¥¨¶°¡ã¡ã
´N·|¥X²{userform2ªºªí³æ


¦ý¦pªG¥ý«ö¦p¤U¹Ïªº¶¶§Ç®É



´N·|¥X²{¦p¤U¹Ï


·í«ö¤U½T©w®É¡A´N·|¥X²{¦p¤U¹Ï (°õ¦æ¶¥¬q¿ù»~91¡A¨S¦³³]©wª«¥óÅܼƩÎwith°Ï¶ôÅܼơ^¡H


¤p§Ì¦bºô¸ô¤W§ä¤FÃö©ó³o­Ó°T®§ªº¸ÑÄÀ¡A¦ý³o­Ó°T®§¦ü¥G¦³¦n´XºØ»¡ªk

¦³»¡¬OÅܼƨS³]¬°°Ï°ì¡A¤]¦³»¡¬O¨S³]¬°¥þ°ìÅܼơã¡ã

½Ð°Ý³o¬O«ç»ò¦^¨Æ©O¡H
2.rar (19.07 KB)
·PÁ¦U¦ì¡A¯¬¦w±d¡ã¡ã


PS¡G¬°¤°»ò½×¾ÂµLªk¶Çªþ¥ó¤W¥h¡H
¿ú¬O«Ü±I²öªº¡A©Ò¥H·|·Q¿ìªk»E¦b¤@°_¡I

¦^´_ 1# syuan


    if±Ô­z¨S³]©w¨ìjp
§ï¦¨
  1. Private Sub ListBox3_Click()
  2. UserForm2.ListBox1.Clear

  3. Set TA = Sheets("sheet1").Range("a2:b6")'³]¸mÅܼÆTA
  4. Set JP = Sheets("sheet1").Range("A10:B14")'³]¸mÅܼÆJP
  5. If UserForm1.ListBox1.ListIndex = 0 And UserForm1.ListBox2.ListIndex = 0 And UserForm1.ListBox3.ListIndex = 0 Then
  6. With UserForm2.ListBox1
  7.      .ColumnCount = TA.Columns.Count
  8.      .ColumnWidths = "100"
  9.      .List = TA.Value
  10. End With
  11. UserForm2.Show
  12. '----------------------------------------------------
  13. ElseIf UserForm1.ListBox1.ListIndex = 1 And UserForm1.ListBox2.ListIndex = 0 And UserForm1.ListBox3.ListIndex = 0 Then
  14. UserForm2.ListBox1.Clear
  15. With UserForm2.ListBox1
  16.      .ColumnCount = JP.Columns.Count
  17.      .ColumnWidths = "100"
  18.      .List = JP.Value
  19. End With
  20. UserForm2.Show
  21. Else
  22. MsgBox "§ä¤£¨ìÀÉ®×"
  23. End If
  24. End Sub
½Æ»s¥N½X
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

[ª©¥DºÞ²z¯d¨¥]
  • ¤p»x(2010-5-26 22:47): ½Ð¸Ô¾\½×¾Âª©³W¤§ÀɮפW¤U¶Ç­ì«h,Àɮתþ¥ó½Ð¾¨¶q§R°£¤£¥²­n¸ê®Æ«áÀ£ÁY«á¤W¶Ç(«D½Ð¤H®a§ïÀɦW)¡C

¥»©«³Ì«á¥Ñ syuan ©ó 2010-5-26 11:44 ½s¿è

Test.rar (67.5 KB) ·PÁÂHsiehª©¤jªº¸Ñ´b¡A·PÁ¤p»xºÞ¤jªº¦^ÂС]À³¸Ó¬O¤p§Ì¥Ø«eªºÅv­­¤£¨¬¡A©Ò¥H¬Ý¤£¨ì¦Û¤v¤W¶Çªºªþ¥ó¡^

¤p§Ì±Nªí³æ¤@ªºElseIF¤Uªºset¸Ó¥y¡A©ñ¨ì¦pª©¤j©Ò­zªº¦ì¸m¡AªGµM´N¤£¦A¥X²{¨º­Ó°T®§¡]°õ¦æ¶¥¬q¿ù»~91¡A¨S¦³³]©wª«¥óÅܼƩÎwith°Ï¶ôÅܼơ^

¦ý·íÂI¿ïuserform1¸ÌListbox1ªº01.¤é¥»®É¡Auserform1ªºListbox2»PListbox3³£¥iÅã¥Ü¡A¦Óuserform2ªºListbox1¸Ìªº¶µ¥Ø«oµLªkÂI¿ï¡]¦p¤U¹Ï¡^
¡]¤p§Ìªº³o­Óµ{¦¡¬O¥ÎExcelªºVBA¨Ó¶}±ÒpdfÀÉ¡^



·PÁÂ¥ý¶i­Ì¡A¯¬¦w±d¡ã¡ã

ps¡Gªþ¥óªºÀÉ®×°ÆÀɦW¡A½Ð§ï¬°xls¡I
¿ú¬O«Ü±I²öªº¡A©Ò¥H·|·Q¿ìªk»E¦b¤@°_¡I

TOP

¥»©«³Ì«á¥Ñ PD961A ©ó 2010-5-26 12:41 ½s¿è

·PÁÂHsiehª©¤jªº¸Ñ´b¡A·PÁ¤p»xºÞ¤jªº¦^ÂС]À³¸Ó¬O¤p§Ì¥Ø«eªºÅv­­¤£¨¬¡A©Ò¥H¬Ý¤£¨ì¦Û¤v¤W¶Çªºªþ¥ó¡^

¤p§Ì ...
syuan µoªí©ó 2010-5-26 11:43 [/quote]

HSªO¥D
½Ð°Ý¤U¸ü®Éªº¹ï¸Ü­n¥ÎÀx¦s   ¤U¸ü (46.82 KB)


ÀɮצWºÙª½±µ§âRARªþÀɦW¤@¨Ö¼g¤J


¥i¬O¸Ñ¤£¥XÀÉ®×
½Ð°Ý¨BÆJ­þ¸Ì¦³°ÝÃD?
ÁÂÁÂ!!

TOP

¦^´_ 4# PD961A


    1#ªþ¥ó¤w§ó·s,¤U¸ü«á¤w¬O¥¿½TrarÀ£ÁYÀÉ
¤W¶Çªþ¥ó¤£±µ¨üxls°ÆÀɦW
­n¥ýÀ£ÁY«á¦A¤W¶ÇÀ£ÁYÀÉ
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

¥»©«³Ì«á¥Ñ PD961A ©ó 2010-5-26 18:10 ½s¿è

¦^´_ 5# Hsieh
ª©¥D
1#ªþ¥ó¤w§ó·s,¤U¸ü«á¤w¬O¥¿½TrarÀ£ÁYÀÉ
§Úª¾¹D:¤W¶Çªþ¥ó¤£±µ¨üxls°ÆÀɦW
            ­n¥ýÀ£ÁY«á¦A¤W¶ÇÀ£ÁYÀÉ
¥¿±`¬Oª½±µ¸ÑÀ£ÁY´N¥i¥H
¤£¹L¦]¬°¶}¥XªºÀɮ׬O³o¼Ëªºµe­±¤~·|ı±oºÃ°Ý...
ÁÂÁÂ!!



  ¥t¥~¤£¦n·N«ä1#ªþ¥ó§ó·sÀɬO­þ¤@­Ó??·PÁ±z!

TOP

¦^´_ 6# PD961A


    ­ì¦]¦b©ó¼Ó¥D¥u¬O§âÀɮרú¦W¬°2.rar
¹ê½è¤W¸ÓÀɮ׬O.xls
§Ú¤w¸g±N¼Ó¥D­ìÀÉ®×­«·sÀ£ÁY¤W¶Ç
©Ò¥H²{¦b¤w¬O¥¿½Tªº.rar¤F
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

³y¦¨¤j®a§xÂZ¡A¯u¬O¤Q¤À©êºp¡I

°_¦]¬O¤p§Ìª½±µ±NxlsÀɪº°ÆÀɦW¡A§ï¦¨rarªºÀ£ÁYÀÉ¡I

¦b²Ä¤@©«§Ñ¤Fµù©ú¡Aµ²ªGÅýPD961A¤j»~¸Ñ¡A¯u¬O¤£¦n·N«ä¡I

¤U¦¸¤p§Ì·|±N¸ÓÀÉÀ£ÁY«á¦A¤W¶Ç¡ã¡ã
¿ú¬O«Ü±I²öªº¡A©Ò¥H·|·Q¿ìªk»E¦b¤@°_¡I

TOP

¥»©«³Ì«á¥Ñ syuan ©ó 2010-7-3 14:33 ½s¿è

¤£¦n·N«ä¡A¤p§Ì¤S¨Ó°Ý°ÝÃD¤F¡ã¡ã

¤p§Ì·Q»s§@¤@­Ó¿é¤J¸¹½X«á¡A¦A«ö¤U«ö¶s®É¡A·|¥X²{¸Ó¸¹½XªºPDFÀÉ

¦p¹Ï¤U


»¡©ú¡G·í¤W¤èªºLISTBOXÂI¿ï«á¡]§YEXCEL¤U¤èªºSHEET¦WºÙ¡^¡A¨Ï¥ÎªÌ¦A¿é¤J·Q¬d¸ßªº¸¹½X¡AVBA´N·|¨Ì¿é¤Jªº½X½X¡A¨Ó·j´MµwºÐ¸ô®|¤UªºPDFÀÉ

¤p§Ì¹ê¦b¤£ª¾¹D¸Ó¦p¦ó¼g¡A¤w¸g¦bºô¸ô¤W§ä«Ü¤[¡A¦ý³£¨S§ä¨ìÃþ¦üªº»yªk¡ã¡ã

¥u¦n¤W¨Ó½Ð¯q¦U¦ì¡AÁÙ±æ¦U¦ì¥ý¶i¤£§[±Ð¾É¡A¯¬¦³­Ó´r§Ö°²´Á¡I

³o¬OEXCELªºVBAÀÉ®× Test.rar (23.88 KB)
¿ú¬O«Ü±I²öªº¡A©Ò¥H·|·Q¿ìªk»E¦b¤@°_¡I

TOP

¥»©«³Ì«á¥Ñ kimbal ©ó 2010-7-13 22:12 ½s¿è
¤£¦n·N«ä¡A¤p§Ì¤S¨Ó°Ý°ÝÃD¤F¡ã¡ã

¤p§Ì·Q»s§@¤@­Ó¿é¤J¸¹½X«á¡A¦A«ö¤U«ö¶s®É¡A·|¥X²{¸Ó¸¹½XªºPDFÀÉ

¦p¹Ï ...
syuan µoªí©ó 2010-7-3 12:23



   
¤U­±¤Þ¥Î¥Ñsyuan¦b 2010/07/14 00:27am µoªíªº¤º®e¡G
·PÁÂkimbal¤jªº±Ð¾É¡]³o´X¤Ñ¦b§Ë§OªºªF¦è¡A©Ò¥H¨S¥ß§Y¦^ÂС^
¤p§Ì±N³o¬q»yªk®M¦bµ{¦¡¡Aªº½T¯à±Npdf¥´¶}
¦ý¤p§Ì¤Sµo²{¨â­Ó°ÝÃDÂI¡J
1.¦pªGpdfªº¥DÀɦW¸Ì¡A¦³¡y1234-2010.pdf¡z¡B¡y4321.pdf¡z»P¡y1234-1-2010.pdf?...


¡yK = TextBox1.Text
FS = "H:\" & ListBox1.List(ListBox1.ListIndex) & "\" ¡z
³o¬q§ï¦¨¦p¤U

¡ySelect Case ListBox1.ListIndex
Case 0
K = TextBox1.Text
FS = "F:\xxxx\´ú¸Õ¥Î\¥Ò\"
Case 1
K = TextBox1.Text
FS = "F:\xxxx\´ú¸Õ¥Î\¤A\"
Case 2
K = TextBox1.Text
FS = "F:\xxxx\´ú¸Õ¥Î\¤þ\"
End Select¡z

1. ¦pªG¦³¦h©ó1­ÓÀÉ
StrFile = Dir(FS & K & "-*.pdf")
    If StrFile = "" Then
        MsgBox "§ä¤£¨ìÀÉ®×"
    End If
    Do While StrFile <> ""
        If StrFile <> "" Then
            ActiveWorkbook.FollowHyperlink  FS & K & StrFile
        End If
        StrFile = Dir
    Loop

2. ¸Õ¸Õ,
FS & "*" & K & "-*.pdf"

´N¬O§ä  "F:\xxxx\´ú¸Õ¥Î\x\" + ¥ô¦ó¦r + textbox¤Wªº¦r + - +  ¥ô¦ó¦r + '.pdf' ªº·N«ä
À´±oµo°Ý,µª®×´N·|¦b¨ä¤¤

¤µ¤éの¤@¬íは  ©ú¤éにない
http://kimbalko-chi.blogspot.com
http://kimbalko.blogspot.com

TOP

        ÀR«ä¦Û¦b : Ä@­n¤j¡B§Ó­n°í¡B®ð­n¬X¡B¤ß­n²Ó¡C
ªð¦^¦Cªí ¤W¤@¥DÃD