- ©«¤l
- 5923
- ¥DÃD
- 13
- ºëµØ
- 1
- ¿n¤À
- 5986
- ÂI¦W
- 0
- §@·~¨t²Î
- win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW°ò¶©
- µù¥U®É¶¡
- 2010-5-1
- ³Ì«áµn¿ý
- 2022-1-23
|
¦^´_ 1# kai6929
¤£¿ùªº¤À¨É,¦ý¦P ¤@ÅU«È¿ï²Ä¤G¦¸®É,¦b·s¼W¤u§@ªíªº©R¦W·|¿ù»~
¯Â°Ñ¦Ò;ªí³æªºµ{¦¡½X- Private Sub myComboBox_Change()
- ' Call »s§@½Ð´Ú®Ñ(myComboBox.Text)
- »s§@½Ð´Ú®Ñ '(myComboBox.Text)
- End Sub
- Private Sub UserForm_Initialize()
- 'myForm.myComboBox.List = Array("A¤½¥q", "B«Ø³]¤½¥q", "C¹q¾¹¤½¥q", "D¤£°Ê²£¤½¥q") '
- '¤U¦Cµ{¦¡½X ¥i®Ú¾Ú "¾P°â¸ê®Æ" BÄ檺ÅU«È «Ø¥ß myComboBox ªº List
- With Sheets("¾P°â¸ê®Æ")
- .Range("B3", .[B3].End(xlDown)).AdvancedFilter xlFilterCopy, , .Cells(1, Columns.Count), True
- 'AdvancedFilter ¶i¶¥¿z¿ï ¤£«½ÆªºÅU«È¦W³æ¨ì.Cells(1, Columns.Count)³Ì«á¤@Äæ
- With .Range(.Cells(2, Columns.Count), .Cells(2, Columns.Count).End(xlDown)) '²Ä2¦C¨ì³Ì«á¦³¸ê®Æªº¦C
- myComboBox.List = .Value
- .EntireColumn.Clear
- End With
- End With
- End Sub
- Private Sub »s§@½Ð´Ú®Ñ()
- Application.ScreenUpdating = False
- With Sheets("¾P°â¸ê®Æ")
- .Range("A3").AutoFilter 2, myComboBox '¦Û°Ê¿z¿ï BÄæ myComboBox(ÅU«È)
- .Columns(2).Hidden = True 'ÁôÂÃBÄæ
- .Range("A3").CurrentRegion.Copy '½Æ»s¿z¿ï¥Xªº ¤é´Á,°Ó«~,³æ»ù,¼Æ¶q,ª÷ÃB
- .AutoFilterMode = False
- With Sheets("½Ð´Ú®ÑÂú§Î")
- .Range("A6") = myComboBox
- .Range("A11").CurrentRegion = "" '²M°£Â¦³¸ê®Æ
- .Range("A11").PasteSpecial xlPasteValuesAndNumberFormats '¶K¤W ȤΤ½¦¡
- End With
- Application.CutCopyMode = False '¨ú®ø½Æ»sªºµê½u
- .Columns(2).Hidden = False '¨ú®øÁôÂÃBÄæ
- End With
- Application.ScreenUpdating = True
- End Sub
½Æ»s¥N½X |
|