
Sub Macro1() Dim shp As Shape For Each shp In ActiveSheet.Shapes shp.Placement = xlMove Next shp End Sub |
Sub prova()
Dim img As Shape
For Each img In ActiveSheet.Shapes
img.Placement = xlMove
Next img
End Sub
Sub copiaIntestazione()
Dim i As Integer
For i = 3 To 7 Step 2
Range("a1:b1").Copy Destination:=Range("a" & i)
Next i
End Sub |
Sub ImpostaProprietàImmagini()
Dim img As Shape
For Each img In ActiveSheet.Shapes
img.Placement = xlMove
Next img
End Sub
Sub copiaIntestazione()
Dim i As Integer
Dim ur As Long
Dim numimg As Long
numimg = ActiveSheet.Shapes.Count
Application.ScreenUpdating = False
For i = 3 To numimg * 2 Step 2
Range("a1:b1").Copy Destination:=Range("a" & i)
Next i
Application.ScreenUpdating = True
End Sub
Sub SubInserisciRighe()
Dim i As Integer
Dim numimg As Long
numimg = ActiveSheet.Shapes.Count
Application.ScreenUpdating = False
For i = 3 To numimg * 2 Step 2
Range("A" & i).Select
Selection.EntireRow.Insert
Selection.EntireRow.AutoFit
Next i
Application.ScreenUpdating = True
End Sub
Sub MacroGenerale()
Call ImpostaProprietàImmagini
Call SubInserisciRighe
Call copiaIntestazione
End Sub
|
Sub copiaIntestazione()
Dim i As Integer
Dim ur As Long
ur = Cells(Rows.Count, 1).End(xlUp).Row
Application.ScreenUpdating = False
For i = 3 To ur Step 2
Range("a1:g1").Copy Destination:=Range("a" & i)
Next i
Application.ScreenUpdating = True
End Sub
Sub SubInserisciRighe()
Dim i As Integer
Dim ur As Long
ur = Cells(Rows.Count, 1).End(xlUp).Row
Application.ScreenUpdating = False
For i = 3 To ur Step 2
Range("A" & i).Select
Selection.EntireRow.Insert
Selection.EntireRow.AutoFit
Next i
Application.ScreenUpdating = True
End Sub
Sub MacroGenerale()
Call SubInserisciRighe
Call copiaIntestazione
End Sub
|
