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

¦p¦ó³]©w½Æ»s°j°ésheet1½Æ»sÀx¦s®æ¦Üsheet2©T©w¦ì¸m????

¦^´_ 1# poke0817


  ¬O³o¼Ë¶Ü¡H
§Ú§â¼ÐÅҼ˦¡§ï¨ìSheet3¥HÀ³²Ä2­Ó°ÝÃD
  1. Public Sub ex()
  2. Dim rng As Range, r%, c%
  3. Sheet3.Range("a1:h" & Sheet3.Cells(Rows.Count, 1).End(xlUp).Row).Delete
  4. r = 1
  5. c = 1
  6. For i = 1 To 8 Step 2
  7.     Sheet3.Columns(i).ColumnWidth = 9.65
  8.     Sheet3.Columns(i + 1).ColumnWidth = 18.13
  9. Next
  10. For Each rng In Sheet1.Range("a2:a" & Sheet1.Cells(Rows.Count, 1).End(xlUp).Row)
  11.     With Sheet3
  12.         If c < 8 Then
  13.             With .Range(.Cells(r, c), .Cells(r + 2, c + 1))
  14.                 .HorizontalAlignment = xlCenter
  15.                 .VerticalAlignment = xlCenter
  16.                 .WrapText = False
  17.                 .Orientation = 0
  18.                 .AddIndent = False
  19.                 .IndentLevel = 0
  20.                 .ShrinkToFit = True
  21.                 .ReadingOrder = xlContext
  22.                 .Borders(xlDiagonalDown).LineStyle = xlNone
  23.                 .Borders(xlDiagonalUp).LineStyle = xlNone
  24.                 With .Borders(xlEdgeLeft)
  25.                     .LineStyle = xlContinuous
  26.                     .ColorIndex = xlAutomatic
  27.                     .TintAndShade = 0
  28.                     .Weight = xlMedium
  29.                 End With
  30.                 With .Borders(xlEdgeTop)
  31.                     .LineStyle = xlContinuous
  32.                     .ColorIndex = xlAutomatic
  33.                     .TintAndShade = 0
  34.                     .Weight = xlMedium
  35.                 End With
  36.                 With .Borders(xlEdgeBottom)
  37.                     .LineStyle = xlContinuous
  38.                     .ColorIndex = xlAutomatic
  39.                     .TintAndShade = 0
  40.                     .Weight = xlMedium
  41.                 End With
  42.                 With .Borders(xlEdgeRight)
  43.                     .LineStyle = xlContinuous
  44.                     .ColorIndex = xlAutomatic
  45.                     .TintAndShade = 0
  46.                     .Weight = xlMedium
  47.                 End With
  48.                 With .Borders(xlInsideVertical)
  49.                     .LineStyle = xlContinuous
  50.                     .ColorIndex = xlAutomatic
  51.                     .TintAndShade = 0
  52.                     .Weight = xlThin
  53.                 End With
  54.                 With .Borders(xlInsideHorizontal)
  55.                     .LineStyle = xlContinuous
  56.                     .ColorIndex = xlAutomatic
  57.                     .TintAndShade = 0
  58.                     .Weight = xlThin
  59.                 End With
  60.                 With .Font
  61.                     .Name = "¼Ð·¢Åé"
  62.                 End With
  63.             End With
  64.             With .Range(.Cells(r, c), .Cells(r, c + 1))
  65.                 .MergeCells = True
  66.                 .Value = "XX¥ø·~ªÑ¥÷¦³­­¤½¥q"
  67.                 With .Font
  68.                     .Size = 14
  69.                 End With
  70.             End With
  71.             .Cells(r + 1, c) = "°]²£½s½X"
  72.             .Cells(r + 1, c + 1) = rng
  73.             .Cells(r + 2, c) = "«~¦W"
  74.             .Cells(r + 2, c + 1) = rng.Offset(, 1)
  75.             c = c + 2
  76.         End If
  77.         If c > 8 Then
  78.             c = 1
  79.             r = r + 3
  80.         End If
  81.     End With
  82. Next
  83. End Sub
½Æ»s¥N½X

TOP

¦^´_ 4# poke0817


    »s§@Àx¦s®æ®æ¦¡¡A©Mª©¥»¦³Ãö«Y¡I2003¤£¬Û®e¡I

TOP

        ÀR«ä¦Û¦b : ÁÀ¨¥¹³¤@¦·²±¶}ªºÂAªá¡A¥~ªí¬üÄR¡A¥Í©Rµu¼È¡C
ªð¦^¦Cªí ¤W¤@¥DÃD