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

°Æµ{¦¡/if§PÂ_¤£¨ì/½Ð¨D¸Ñ´b

¥»©«³Ì«á¥Ñ luhpro ©ó 2013-10-20 21:18 ½s¿è

¦^´_ 5# ³Ì°ª¾÷±K
§A»~·|¤F.

2# ©Ò»¡ ¶·©ó¥Dµ{¦¡¦¡ªº¼Ò²Õ¤¤ªº³»ºÝ PUBLIC X,Y ³]¬°¤½¥ÎÅÜ¼Æ ·N«ä¬OÅܼƭn¦b Model ¤¤¥H Public ¨Ó©w¸q:
¥H¤Uµ{¦¡©ñ¦b Model ¼Ò²Õ¤¤ :
  1. Public x, y
½Æ»s¥N½X
¥t§Aªº If x > Cells(a, 1) <= y Then «h­n§ï¬°

If x > Cells(a, 1) And Cells(a, 1) <= y Then

©³¤U¥H§A 1# ªºµ{¦¡¬°¨Ò­×§ï :
  1. Sub trend()
  2.   x = InputBox("¿é¤J²Ä¤@¤Ñ")
  3.   y = InputBox("¿é¤J³Ì«á¤@¤Ñ")
  4.   For a = 2 To 486
  5.     Call aa(a)
  6.   Next a
  7. End Sub

  8. Sub aa(ByVal a As Integer)
  9.   For b = 9 To 32
  10.     If x > Cells(a, 1) And Cells(a, 1) <= y Then
  11.       Cells(a, b + 25) = Cells(a + 2, 2) - Cells(a + 1, 2)
  12.     Else
  13.       Cells(a, b + 25) = Cells(a + 1, 2) - Cells(a + 2, 2)
  14.     End If
  15.     c = Cells(a, b + 25)
  16.     d = d + c
  17.     Cells(489, b + 25) = d
  18.     e = Cells(1, b + 25)
  19.     Cells(488, b + 25) = e
  20.   Next
  21.   c = 0
  22.   Cells(1, b + 25) = Cells(1, b)
  23. End Sub
½Æ»s¥N½X
±MÃD½d¥»0917 (§ï)-a.zip (45.87 KB)

TOP

        ÀR«ä¦Û¦b : ¤H­n¦Û·R¡A¤~¯à·R´¶¤Ñ¤Uªº¤H¡C
ªð¦^¦Cªí ¤W¤@¥DÃD