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

[µo°Ý] ¦p¦ó±Æ§Ç­^¼Æ¦r¡H

[µo°Ý] ¦p¦ó±Æ§Ç­^¼Æ¦r¡H

½Ð°Ý¦³¿ìªk±Æ§Ç­^¼Æ¦rªº¸ê®Æ¶Ü¡H
¨Ò¦p¡G
±Æ§Ç«e
a1, b1,a3, ab1, aa3,aa1,

±Æ§Ç«á
a1, a3, b1, aa1, aa3, ab1

½Ð«e³Æ­Ì¤£§[½ç±Ð¡I

¥»©«³Ì«á¥Ñ bobomi ©ó 2015-1-15 13:22 ½s¿è

Sub XX()


ar = Array("a1", "b1", "a3", "ab1", "aa3", "aa1")

s = ar

For w = 0 To UBound(ar)
    s(w) = ""
    For k = 1 To Len(ar(w))
        s(w) = s(w) & Right("0000" & AscW(Mid(ar(w), k, 1)), 4)
    Next
    If Len(s(w)) > m Then m = Len(s(w))
Next
For w = 0 To UBound(ar)
    s(w) = Right(Space(m) & s(w), m)
Next

For i = 0 To UBound(ar)
    For j = 0 To UBound(ar) - 1
     If (s(j)) > (s(j + 1)) Then
     temp = s(j)
     s(j) = s(j + 1)
     s(j + 1) = temp
     
     temp = ar(j)
     ar(j) = ar(j + 1)
     ar(j + 1) = temp
     End If
Next j
Next i


MsgBox Join(ar, vbCrLf)

End Sub

TOP

§ï¦¨³o¦UÅo

Sub XX()


ar = Array("a1", "b1", "a3", "ab1", "aa3", "aa1", "aa0")

For w = 0 To UBound(ar)
    If Len(ar(w)) > m Then m = Len(ar(w))
Next
For w = 0 To UBound(ar)
    ar(w) = Right(Space(m) & ar(w), m)
Next

For i = 0 To UBound(ar)
    For j = 0 To UBound(ar) - 1
     If (ar(j)) > (ar(j + 1)) Then
     
     temp = ar(j)
     ar(j) = ar(j + 1)
     ar(j + 1) = temp
     End If
Next j
Next i
For w = 0 To UBound(ar)
    ar(w) = LTrim(ar(w))
Next


MsgBox Join(ar, vbCrLf)

End Sub

TOP

¦^´_ 3# bobomi

¦nªº¡A§Ú¦A¨Ó¸Õ¸Õ¬Ý¡AÁÂÁÂbobomi¤j¤j¡I

TOP

¦^´_ 3# bobomi

½Ð°Ýbobomi¤j¤j
§Ú±NÀx¦s®æ¸ê®Æ¥á¤J°}¦C«á¡A¬°¤°»òµLªk¥Î§A©Ò´£¨Ñªºµ{¦¡±Æ§Ç¡H

ex:
Dim ar
ar = Range("a1:a8")

TOP

        ÀR«ä¦Û¦b : ¤£­nÀH¤ß©Ò±ý¡A­nÀH¤ß±Ð¨|¦Û¤v¡C
ªð¦^¦Cªí ¤W¤@¥DÃD