|
yuki さん
こんばんは。
マクロでやっていいなら・・・↓ので可能かと思いますが、いががでしょうか?
SHEET1に記入されているデータを元に
SHEET2に変換結果を出力します。
Sub Chg_Txt()
Dim Cel As Range
Dim i As Long, j As Long
Set Cel = Sheets("SHEET2").Cells(1, 1)
For i = 1 To Sheets("SHEET1").Cells(65000, 1).End(xlUp).Row
For j = CInt(Left(Sheets("SHEET1").Cells(i, 2), 1)) To CInt(Left(Sheets("SHEET1").Cells(i, 3), 1))
With Cel
.Value = Sheets("SHEET1").Cells(i, 1)
.Offset(0, 1).Value = j
.Offset(0, 2).Value = Sheets("SHEET1").Cells(i, 4)
End With
Set Cel = Cel.Offset(1, 0)
Next
Next
Set Cel = Nothing
End Sub
|
|