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

¤@­Ó²M³æÅçÃÒ°ÝÃD

¤@­Ó²M³æÅçÃÒ°ÝÃD

½Ð°Ý¦U¦ì¥ý¶i
§Ú¤U¦Cµ{¦¡½X¦³­þ¸Ì¿ù»~¶Ü?
¬°¦ó§Ú¿é¤J²M³æ¥H¥~ªº¤å¦r
µLªk¥X²{¿ù»~°T®§

With Selection.Validation
        .Delete
        .Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Operator:= _
        xlBetween, Formula1:="=" & bb
        .IgnoreBlank = True
        .InCellDropdown = True
        .InputTitle = ""
        .ErrorTitle = ""
        .InputMessage = ""
        .ErrorMessage = ""
        .ShowInput = True
        .ShowError = True
    End With

¦^´_ 1# dafa
  1. Sub Ex()
  2.    Dim BB(3), CC
  3.    BB(0) = 1
  4.    BB(1) = 3
  5.    BB(2) = 4
  6.    BB(3) = 5
  7.    'CC = Join(BB, ",")          '°}¦C
  8.    CC = "=" & [A1:A5].Address   'Àx¦s®æ
  9.    With Selection.Validation
  10.         .Delete
  11.         .Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Operator:= _
  12.         xlBetween, Formula1:=CC
  13.         .IgnoreBlank = True
  14.         .InCellDropdown = True
  15.         .InputTitle = ""
  16.         .ErrorTitle = ""
  17.         .InputMessage = ""
  18.         .ErrorMessage = ""
  19.         .ShowInput = True
  20.         .ShowError = True
  21.     End With
  22. End Sub
½Æ»s¥N½X

TOP

¦^´_ 2# GBKEE


    ·PÁÂG¤jªº¦^ÂÐ
§Ú¥h¸Õ¸Õ¬Ý

TOP

¦^´_ 2# GBKEE


    ¦A½Ð°ÝG¤j¤@­Ó°ÝÃD
°}¦CBB(30)¤º30¥i¥H¬OÅܼƶÜ?

TOP

¦^´_ 4# dafa
  1. Option Explicit
  2. Sub Ex()
  3.     Dim BB(5 To 30), i As Integer
  4.     For i = 5 To 30
  5.         BB(i) = i + 2
  6.     Next
  7.     MsgBox Join(BB, ",")
  8. End Sub
½Æ»s¥N½X

TOP

¦^´_ 5# GBKEE

½Ð°ÝG¤j§Ú°õ¦æ¨ì³o¤@¬q·|¥X²{¿ù»~
Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Operator:= _
        xlBetween, Formula1:="=" & bb
·|¥X²{¿ù»~

    Sub ²M³æ©ú²Ó()
If ActiveCell.Cells.Column <> "4" Then Exit Sub
aa = ActiveCell
If aa = "" Then Exit Sub

g = Worksheets("²M³æ©ú²Ó").Cells(65536, 1).End(xlUp).Row
For i = 1 To g
If Worksheets("²M³æ©ú²Ó").Cells(i, 1) = aa Then
b = 0
    For a = 4 To 34
        kk(b) = Worksheets("²M³æ©ú²Ó").Cells(i, a)
        b = b + 1
    Next a
bb = Join(kk, ",")

'bb = Worksheets("²M³æ©ú²Ó").Cells(i, 3)

ActiveCell.Cells(, 4).Select
Exit For
End If
Next i
With Selection.Validation
        .Delete
        .Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Operator:= _
        xlBetween, Formula1:="=" & bb
        .IgnoreBlank = True
        .InCellDropdown = True
        .InputTitle = ""
        .ErrorTitle = ""
        .InputMessage = ""
        .ErrorMessage = ""
        .ShowInput = True
        .ShowError = True
    End With


End Sub

TOP

¦^´_ 5# GBKEE

½Ð°ÝG¤j
   ·|¤£·|¬O¦]¬°§Úªº°}¦C¸ê®Æ¤º¦³ªÅ­È
¦Óµo¥Íªº¿ù»~

TOP

¦^´_ 7# dafa
xlBetween, Formula1:="=" & bb §ï¦¨  xlBetween, Formula1:=bb

TOP

¦^´_ 8# GBKEE


    ·PÁÂG¤jªº¼ö¤ß
À°§Ú¸Ñ¨MÃøÃD

TOP

¦^´_ 8# GBKEE


    ¦A½Ð°ÝG¤j¤@¤U
¬°¦ó§ÚªºÄµ§i°T®§¤£·|¥X²{


Sub ²M³æ©ú²Ó()

Dim bb, kk(30), aa
If ActiveCell.Cells.Column <> "4" Then Exit Sub

aa = ActiveCell
If aa = "Account Code " Then Exit Sub
If aa = "" Then Exit Sub
g = Worksheets("²M³æ©ú²Ó").Cells(65536, 2).End(xlUp).Row
For i = 1 To g
e = Worksheets("²M³æ©ú²Ó").Cells(i, 2)
If Worksheets("²M³æ©ú²Ó").Cells(i, 2) = aa Then

b = 0
j = Worksheets("²M³æ©ú²Ó").Cells(i, 34).End(xlToLeft).Column
    For a = 3 To j
        kk(b) = Worksheets("²M³æ©ú²Ó").Cells(i, a)
        b = b + 1
    Next a
bb = Join(kk, ",")
Exit For

End If
Next i
pp = Worksheets("²M³æ©ú²Ó").Cells(i, 3)
MsgBox pp, , "Account_Code»¡©ú"

ActiveCell.Cells(, 4).Select
ActiveCell = ""
With Selection.Validation
        .Delete
        .Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop, Operator:= _
        xlBetween, Formula1:=bb
        .IgnoreBlank = True
        .InCellDropdown = True
        .InputTitle = ""
        .ErrorTitle = ""
        .InputMessage = ""
        .ErrorMessage = "You must enter a number from five to ten"
        .ShowInput = True
        .ShowError = True
    End With
Set kk(30) = Nothing
ActiveCell.Offset(, -5) = Date
ActiveCell.Offset(, 1) = Environ("UserName")
End Sub

TOP

        ÀR«ä¦Û¦b : ¤H¥Í³Ì¤jªº¦¨´N¬O±q¥¢±Ñ¤¤¯¸°_¨Ó¡C
ªð¦^¦Cªí ¤W¤@¥DÃD