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

¦p¦óÅýListBox¥i¥HÀHµÛÀx¦s®æ¤ºªº¼Æ¦rÅܤÆ

¦p¦óÅýListBox¥i¥HÀHµÛÀx¦s®æ¤ºªº¼Æ¦rÅܤÆ

¦U¦ì«e½ú½Ð°Ý¤@¤U

¦p¦óÅýListBoxÅã¥Ü¥i¥HÀHµÛÀx¦s®æ(A1)¤ºªº¼Æ¦rÅܤÆ
ÁÙ¬O­n¥ÎTextbox??

§â§ïÅܪº»y¥y¼g¦bWorksheet_Change¨Æ¥ó¸Ì¡C

TOP

§ÚªºListbox¬O¦buseform¤º¡A©Ò¥H°õ¦æ³£·|¥X²{¿ù»~

TOP

¦^´_ 3# catmm
  1. Private Sub UserForm_Initialize()
  2.     With ListBox1
  3.         .RowSource = "a1:b6"
  4.         .ColumnCount = 2
  5.     End With
  6. End Sub
½Æ»s¥N½X

TOP

¥i¥H¥Î³á~~
ÁÂÁ¤j¤j~~
·P®¦~~

TOP

¤p§Ìªº¼gªk¡]¦n¹³¤ñ¸û¦h¤F¤@ÂI¡D¡D¡D¡D¡D¡D¡^


Private Sub UserForm_Initialize()
Dim xxxx AS Range

Set xxxx = Sheets("xxxx").Range("a1:b2")  

With UserForm1.ListBox1
     .ColumnCount = xxxx.Columns.Count
     .ColumnWidths = "100"
     .List = xxxx.Value
End With
End sub


¥H¤W¶È°Ñ¦Ò¡D¡D¡D¡D¡D
¿ú¬O«Ü±I²öªº¡A©Ò¥H·|·Q¿ìªk»E¦b¤@°_¡I

TOP

¦^´_ 6# syuan
ListBox1.List = xxxx.Value                             ·|©T©wListªº­È,¬°³Ìªì³]©w®Éxxxxªº­È
ListBox1.RowSource = xxxx.Address(, , , 1)   Listªº­È,·|ÀHxxxxªº­È ¦Ó§ïÅÜ

TOP

¦^´_ 7# GBKEE
·PÁÂGBKEE¤jªº±Ð¾É

¤p§Ì©|¦³¤@¨Æ¤£¸Ñ

¦pªG¦bEXCEL¸Ì¦³¦n´X­¶ªº¤À­¶(Sheet1¡BSheet2¡BSheet3¡D¡D¡D¡D¡^¡A¤p§Ì¦b#6©Ò¼gªº»yªk¡A´N¬O¦]¬°¦³¦n´X­¶ªº¤À­¶¡A©Ò¥H¤~³o¼Ë¼g¡I

¤p§Ì¤£¤~¡A¨º¦pªG·Q¥H±z³o¥y»yªk¥h­×§ï¤p§Ìªºµ{¦¡®É¡A½Ð°Ý­n¦p¦ó¥h§ï©O¡H
ListBox1.RowSource = xxxx.Address(, , , 1)

µù¡G¥H¤U¬°¤p§Ì®M¥Î±zªº»yªk¨Ó­×§ï¡Aµo²{¦n¹³¶È·|¨q¥X²Ä¤@­ÓSheetªº¤º®e¦Ó¤w¡I
ElseIf UserForm1.ListBox1.ListIndex = 6 And UserForm1.ListBox2.ListIndex = 1 And UserForm1.ListBox3.ListIndex = 1 Then
With UserForm2.ListBox1
     .RowSource = "m5:n8"
     .ColumnCount = 2
     .ColumnWidths = "100"
End With
UserForm2.Show


¥H¤W¡A¯¬¦w±d¡I
¿ú¬O«Ü±I²öªº¡A©Ò¥H·|·Q¿ìªk»E¦b¤@°_¡I

TOP

¦^´_ 8# syuan

§Aªº·N«ä¬O¿ï¤@±iªíªº¹ï§a? ¥i¥H³o¼Ëªº

dim strsht as string
strsht ="sheet1"

.....
ElseIf UserForm1.ListBox1.ListIndex = 6 And UserForm1.ListBox2.ListIndex = 1 And UserForm1.ListBox3.ListIndex = 1 Then
With UserForm2.ListBox1
     .RowSource = worksheets(strsht).range("m5:n8").address(,,,1)
     .ColumnCount = 2
     .ColumnWidths = "100"
End With
UserForm2.Show

¥H¤W¦^¶Çsheet1
§âstrsht="sheet1"  ´«¦¨ "sheet2" ´N·|¦^¶Çsheet2 ªº
À´±oµo°Ý,µª®×´N·|¦b¨ä¤¤

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

TOP

ª±¤@¤U¤½¦@©w¸q
¤Á´«Àɮפu§@ªí¸Õ¸Õ¬Ý¦³¬Æ»ò®t§O ¦@¥Î©w¸q.rar (9.3 KB)
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

        ÀR«ä¦Û¦b : ½_ÁJµ²±o¶V¹¡º¡¡A¶V·|©¹¤U««¡A¤@­Ó¤H¶V¦³¦¨´N¡A´N­n¶V¦³Á¾¨Rªº¯ÝÃÌ¡C
ªð¦^¦Cªí ¤W¤@¥DÃD