Thankyou need it to be code so does all in one hithello fireslguk,
without via code, you can try this...
Get the value from Sheet1 cell A1
Unprotect the other 4 sheets
Paste the value to cell B1 on each of the other 4 sheets
Re-protect the 4 sheets
a bit more effort if a macro is drafted to handle this
hope this helps
plettieri
Sub DateTimeStampSheets()
Dim thisWS As Worksheet
Dim ws As Worksheet
Dim dt As Date
Set thisWS = ActiveSheet
dt = thisWS.Range("A1").Value2
For Each ws In ActiveWorkbook.Worksheets
If ws.Name <> thisWS.Name Then
With ws
.Unprotect Password:=123
.Range("B1").Value2 = dt
.Protect Password:=123, DrawingObjects:=True, Contents:=True, Scenarios:=True
End With
End If
Next ws
End Sub
Some manipulation required to the code above my headSee if this is close to what you are after:
VBA Code:Sub DateTimeStampSheets() Dim thisWS As Worksheet Dim ws As Worksheet Dim dt As Date Set thisWS = ActiveSheet dt = thisWS.Range("A1").Value2 For Each ws In ActiveWorkbook.Worksheets If ws.Name <> thisWS.Name Then With ws .Unprotect Password:=123 .Range("B1").Value2 = dt .Protect Password:=123, DrawingObjects:=True, Contents:=True, Scenarios:=True End With End If Next ws End Sub
Sub DateTimeStampSheets()
Dim thisWS As Worksheet
Dim ws As Worksheet
Dim dt As Date
Set thisWS = Worksheets("Main")
dt = thisWS.Range("A1").Value2
For Each ws In ActiveWorkbook.Worksheets
Select Case ws.Name
Case "s1", "s2", "s3", "s4", "s5"
With ws
.Unprotect Password:=123
.Range("B1").Value2 = dt
.Protect Password:=123, DrawingObjects:=True, Contents:=True, Scenarios:=True
End With
End Select
Next ws
End Sub
That done the job until I realised one sheet “dashboard” needs this value on a different cell “O5”Edited my previous post, accidentally deleted the unprotect line
Sub DateTimeStampSheets()
Dim thisWS As Worksheet
Dim ws As Worksheet
Dim dt As Date
Set thisWS = Worksheets("Main")
dt = thisWS.Range("A1").Value2
For Each ws In ActiveWorkbook.Worksheets
Select Case ws.Name
Case "s1", "s2", "s3", "s4", "s5"
With ws
.Unprotect Password:=123
.Range("B1").Value2 = dt
.Protect Password:=123, DrawingObjects:=True, Contents:=True, Scenarios:=True
End With
Case "dashboard"
.Unprotect Password:=123
.Range("O5").Value2 = dt
.Protect Password:=123, DrawingObjects:=True, Contents:=True, Scenarios:=True
End Select
Next ws
End Sub