- ©«¤l
- 4901
- ¥DÃD
- 44
- ºëµØ
- 24
- ¿n¤À
- 4916
- ÂI¦W
- 255
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Office 20xx
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥x¥_
- µù¥U®É¶¡
- 2010-4-30
- ³Ì«áµn¿ý
- 2024-11-25
|
¥»©«³Ì«á¥Ñ Hsieh ©ó 2013-2-26 14:18 ½s¿è
¦^´_ 3# lifedidi
Sheet2¼Ò²Õ- Private Sub CommandButton1_Click()
- FormA.Show 0
- End Sub
½Æ»s¥N½X FormA¼Ò²Õ- Private Sub CommandButton1_Click()
- FormB.Show 0
- End Sub
- Private Sub UserForm_Initialize()
- Set d = CreateObject("Scripting.Dictionary")
- With Sheet1
- For Each a In .Range(.[A2], .[A1].End(xlDown))
- d(a.Value) = ""
- Next
- End With
- ComboBox1.List = d.keys
- End Sub
½Æ»s¥N½X FormB¼Ò²Õ- Private Sub CommandButton1_Click()
- FormC.Show 0
- FormC.pºâ 1
- End Sub
- Private Sub CommandButton2_Click()
- FormC.Show 0
- FormC.pºâ 2
- End Sub
½Æ»s¥N½X FormC¼Ò²Õ- Sub pºâ(work As Integer)
- Dim Ar()
- With Sheet1
- For Each a In .Range(.[A2], .[A1].End(xlDown))
- If a.Value = FormA.ComboBox1.Value Then
- ReDim Preserve Ar(s)
- Ar(s) = a.Offset(, 1).Value
- s = s + 1
- End If
- Next
- End With
- If work = 1 Then ListBox1.AddItem Format(Application.Sum(Ar), "hh:mm:ss")
- If work = 2 Then ListBox1.AddItem Format(Application.Average(Ar), "hh:mm:ss")
- End Sub
½Æ»s¥N½X
Form Test.zip (12.55 KB)
|
|