Code:
Sub TE()
Application.ScreenUpdating = True
For i = 2 To 145
For j = 2 To 145
Sheets("Tab").Range("V8").Value = i - 1
Sheets("Tab").Range("V8").Value = j - 1
Sheets("Tab").Select
Range("W9").Select
Selection.Copy
Sheets("TE").Select
Cells(1, j).Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
Sheets("Tab").Select
Range("S2:S291").Select
Selection.Copy
Sheets("TE").Select
Cells(2, i).Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
Next
Next
Application.ScreenUpdating = True
End Sub
Sub TE()
Application.ScreenUpdating = True
For i = 2 To 145
For j = 2 To 145
Sheets("Tab").Range("V8").Value = i - 1
Sheets("Tab").Range("V8").Value = j - 1
Sheets("Tab").Select
Range("W9").Select
Selection.Copy
Sheets("TE").Select
Cells(1, j).Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
Sheets("Tab").Select
Range("S2:S291").Select
Selection.Copy
Sheets("TE").Select
Cells(2, i).Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
False, Transpose:=False
Next
Next
Application.ScreenUpdating = True
End Sub
ovo je code koji treba da koristim. celija W9 se menja, a sa njom se menja i kolona S.
e sad, meni se kopiraju normalno podaci iz celije w9 i selektuju redom b1, c1, d1 ...
ali kolona S se kopira, ali se selektuje tj pastuje uvek u kolonu B... umesto u b, c, d, ... gde je greska?