![]() |
Add a Message Box
Hi,
I have the code below (attached to a button) which adds a list of items to a seperate log, can somebody tell me what code to add to it that will produce a message box confirming the data has been placed in the new worksheet. Thanks Excel novice !! Sub add_monday_jobs() With Sheets("monday'S LOG").Range("A8:N34") Sheets("Log").Range("A" & Rows.Count).End(xlUp).Offset( _ 1, 0).Resize(.Rows.Count, .Columns.Count).Value = .Value End With End Sub |
Sub add_monday_jobs()
With Sheets("monday'S LOG").Range("A8:N34") Sheets("Log").Range("A" & Rows.Count).End(xlUp).Offset( _ 1, 0).Resize(.Rows.Count, .Columns.Count).Value = .Value End With MsgBox "Log Created", vbInformation End Sub Regards Rowan "Anthony" wrote: Hi, I have the code below (attached to a button) which adds a list of items to a seperate log, can somebody tell me what code to add to it that will produce a message box confirming the data has been placed in the new worksheet. Thanks Excel novice !! Sub add_monday_jobs() With Sheets("monday'S LOG").Range("A8:N34") Sheets("Log").Range("A" & Rows.Count).End(xlUp).Offset( _ 1, 0).Resize(.Rows.Count, .Columns.Count).Value = .Value End With End Sub |
Hi Anthony
The text in the inverted commas can be changed to suit your needs. Also have a look at MsgBox in the Help file. Sub add_monday_jobs() With Sheets("monday'S LOG").Range("A8:N34") Sheets("Log").Range("A" & Rows.Count).End(xlUp).Offset( _ 1, 0).Resize(.Rows.Count, .Columns.Count).Value = .Value End With MsgBox "Data has been transferred!" End Sub HTH Michael "Anthony" wrote: Hi, I have the code below (attached to a button) which adds a list of items to a seperate log, can somebody tell me what code to add to it that will produce a message box confirming the data has been placed in the new worksheet. Thanks Excel novice !! Sub add_monday_jobs() With Sheets("monday'S LOG").Range("A8:N34") Sheets("Log").Range("A" & Rows.Count).End(xlUp).Offset( _ 1, 0).Resize(.Rows.Count, .Columns.Count).Value = .Value End With MsgBox "Data has been transferred!" End Sub |
All times are GMT +1. The time now is 05:22 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com