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

[µo°Ý] «ç»ò¦bUSERFORM¤¤¥[¤J¥i¿z¿ï½Æ¿ï¤§¾ðª¬¹Ï

¦^´_ 39# chaoyiho


    ¨º­Ó°T®§¥Nªí2·N¸q
(1) ª«¥ó¤£¦s¦bµù¥Uªí¤¤
(2) §A¥i¯à¥´¿ù¦W
µª®×=(2)
Set a = CreateObject("scripting.dictionary")

TOP

¦^´_ 39# chaoyiho
#40 ¬O§Ú¤ñ¸û±`¥Îªº³B²z¤è¦¡ (±q¦­´Á¶Ç²Î¨t²Î¨ì¥Ø«e)¡A
¦]¬° ListBox ¬O¦b "EXCELªí³æ³B²z¤¶­±"  ¸Ì°õ¦æ³B²z¡A
²ßºD¤W§Ú·|±N¦r¨åªº§@·~ª½±µ©ñ¸m¦b UserForm ¸Ì«Å§i
»P³B¸Ì¡A¦Ó¨Ã¤£±N¥¦¸m©ó UserForm ¥~«Å§i¡A°£«D¥¦¦b
UserForm °Ï¶ô¥~¥ç³Q¨ä¥¦µ{¦¡¼Ò²Õ¨Ï¥Î¡B¹B¥Î¨ì°£¥~¡C

¦pªG§Aı±o¦p¦ó«Å§i§¡µL§«¡A¥u­n¨t²Î¯à°Ê«K OK ªº¸Ü
(§Ú¬O¤£ÃÙ¦¨§A¥H¦¹ºØ¤è¦¡¨Ó¾Ç²ß½s¼¶µ{¦¡)¡F¨º§Ú´N¥H
§A¶Ç¨Óªº "¿ù»~°T®§" ¨Ó°µ¸Ñµª§a (ÀÉ®×.rar)¡I

¥ç§Y¦b§A¥Ø«e¤§ Module1 ¤WÀY¥[¤W¡G
  1. Private Sub Auto_Open()
  2.     Set vD = CreateObject("Scripting.Dictionary")      '  «Ø¥ßª«¥ó¡C
  3. End Sub
½Æ»s¥N½X

TOP

¥»©«³Ì«á¥Ñ c_c_lai ©ó 2016-4-27 19:50 ½s¿è

¦^´_ 39# chaoyiho
¹ïÀ³ EXCELªí³æ³B²z¤¶­±.ListBox ªº³¡¤À¡A
»P #40 ¬O¤@­Pªº¡C

¾Ü¤@¿ï¾Ü¥[¤J (½Ð¬Ý³Æµù»¡©ú)¡A
AB ¤£¯à¥þ³¡³q¦Y (³o«K¬O§A¬Ý¨ìªº
­«½Æ Integer ªº¿ù»~°T®§)¡C

±µ¤U¨Ó¥þ¥æµ¹¤F¡C

TOP

¦^´_ 43# c_c_lai

«e½ú¦­¡A©êºp²{¦b¤~¦^¤å
¦]¬°¬Q¤Ñ¦³ÂI¨Æ±¡¯ÔÀÁ¤F...
±z¤W­±ªº¦^¤å§Ú²{¦b°¨¤W¨Ó³B²z¬Ý¬Ý~~!!

¦ý¬OÃö©ó¦^¤å«eªº¨º­Ó¨BÆJ §Úªº½T¬O·ÓµÛ°µ¤F
«o¬O·|¥X²{ ActiveX µLªk«Ø¥ßª«¥óªº¿ù»~
¦pªþÀÉ
ªí³æ³B²z¨t²Î3.2µ¥«Ý­×§ï.rar (650.65 KB)

¯uªº¤£ª¾¹D¨ì©³«ç»ò¤F Q_Q

¦pªG±z¬Ý¨£¤F ¦A³Â·Ð±zÀ°§ÚÀˬd¤@¤U!!
ÁÂÁ±z

ÞË...¹ï¤F  §Ú¨S¦³Åv­­ ©Ò¥HµLªk¦b³o¸Ì§ìªF¦è
§Æ±æ«e½ú¦A³Â·Ð¤@¤Uµ¹§Ú­Ó¤U¸üÂI©Îºô§}©Îª½±µ±H°e¦Ü§Úªº«H½c[email protected]
§Ú·|°¨¤W¦^´_
¦A¦¸·PÁÂ

TOP

¦^´_ 41# jackyq

«e½ú±z¦n
±zªº·N«ä¬O activexªº¿ù»~¬O¦]¬°³o¤@¥y»yªk¿ù»~¶Ü?
¦ý¬O§ÚÀˬd§¹¤§«á
À³¸Ó¨S¦³¿ù°Ú(?)
¥i¥H½Ð±z»¡©ú¸Ô²Ó¤@ÂI¶Ü?

TOP

¥»©«³Ì«á¥Ñ jackyq ©ó 2016-4-28 09:12 ½s¿è

¦^´_ 44# chaoyiho


Set vD = CreateObject("scripting.dictionary")

§A¤Ö¤F¤@­Ó   i


¥t¥~ LongPtr  
¥Î long ´N¥i¥H¤F

TOP

¦^´_ 46# jackyq

¯uªº¤Ö¤F¤@­Ó i !!!

¦ý¬O´Nºâ¥[¤W¥h §ÚÁÙ¬O«ùÄò¥X²{activex¿ù»~....

TOP

¥»©«³Ì«á¥Ñ jackyq ©ó 2016-4-28 09:30 ½s¿è

EXCELªí³æ³B²z¤¶­± ¸Ì­±ªº

Private Sub UserForm_Initialize()

Dim hWndForm As LongPtr
Dim IStyle As LongPtr

Set vD = CreateObject("scripting.dictonary")

§ï¦¨¦p¤U

Private Sub UserForm_Initialize()

Dim hWndForm As Long
Dim IStyle As Long

Set vD = CreateObject("scripting.dictionary")


¦sÀÉ«á , Ãö³¬¦A­«¶}±Ò

§ï§¹«á §Ú³oÃä°õ¦æ´Nok ¤F°Ú

TOP

¥t¥~
§â EXCELªí³æ³B²z¤¶­± ¸Ì­±ªº²Ä¤@¦æ   Option Explicit  ¼È®É¥ý®³±¼

TOP

¥»©«³Ì«á¥Ñ c_c_lai ©ó 2016-4-28 09:48 ½s¿è

¦^´_ 44# chaoyiho
²Ä¤@­Ó°ÝÃD¡G Åܼƫŧi«e«á¤£¤@
  1. Private Sub CommandButton1_Click()
  2.     If Application.FindFile = False Then
  3.         MsgBox "±z¨S¦³¶}±Ò¥ÀÀÉ"
  4.     End If
  5.     Dim lRow&        '  Dim lRrow&  (¿ù»~ªºÅܼƫŧi)
  6.     lRow = 3         '  lRrow = 3   (¿ù»~ªºÅܼƫŧi)
  7.    
  8.     EXCELªí³æ³B²z¤¶­±.ListBox1.Clear    '  ÁקK­«½Æ¶K»s¡A³y¦¨»P "¤â°Ê¿z¿ï" ¶µ¥Ø¤£²Å
  9.    
  10.     vD.RemoveAll
  11.     While Cells(lRow, 5) <> ""
  12.       If Not vD.Exists(CStr(Cells(lRow, 5))) Then
  13.         EXCELªí³æ³B²z¤¶­±.ListBox1.AddItem CStr(Cells(lRow, 5))
  14.         vD(CStr(Cells(lRow, 5))) = lRow
  15.       End If
  16.       lRow = lRow + 1
  17.     Wend             '  ¤W¦³ While ¦ÓµLµ²§ô³B¸Ì (Wend)
  18. End Sub
½Æ»s¥N½X
²Ä¤@­Ó°ÝÃD¡G ²£¥Í ActiveX ªº­ì¦]
  1. Private Sub UserForm_Initialize()
  2.     Dim hWndForm As Long        '  LongPtr ¬O 64 ¦ì¤¸ªºªø¾ã¼Æ«ü¼Ð«Å§i
  3.     Dim IStyle As Long
  4.    
  5.     '  Set vD = CreateObject("scripting.dictonary")    '  ¤Ö¤@­Ó i
  6.     Set vD = CreateObject("Scripting.Dictionary")
  7.    
  8.     hWndForm = FindWindow("ThunderDFrame", Me.Caption)
  9.     IStyle = GetWindowLong(hWndForm, GWL_STYLE)
  10.     IStyle = IStyle Or WS_THICKFRAME '(ÁÙ­ì)
  11.     IStyle = IStyle Or WS_MINIMIZEBOX '(³Ì¤p¤Æ)
  12.     IStyle = IStyle Or WS_MAXIMIZEBOX '(³Ì¤j¤Æ)
  13.     SetWindowLong hWndForm, GWL_STYLE, IStyle
  14. End Sub
½Æ»s¥N½X
jackyq ¤j¤j«üÃÒ¥X§A  ActiveX ªº¿ù»~ÂI¤F¡A­ì¦]¬O§A¿é¿ù¦r¤F
Set vD = CreateObject("scripting.dictonary") ¡A¤Ö¤@­Ó i  ¡A
»P¤j¤p¼gµLÃö¡A¦~¬ö¤j¤F²¦³ºµø¤O°h«Ü¦h¤F¡A¤£¥J²ÓÁÙ¯u¨S¬Ý¨ì©O¡I
ÁÂÁÂ jackyq ¤j¤j¡C

TOP

        ÀR«ä¦Û¦b : ¬°¤H³B¥@­n¤p¤ß²Ó¤ß¡A¦ý¤£­n¡u¤p¤ß²´¡v¡C
ªð¦^¦Cªí ¤W¤@¥DÃD