Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 04-15-2016, 10:09 AM
victoriapowers victoriapowers is offline Need Help Adding to Macros Windows XP Need Help Adding to Macros Office 2010 32bit
Novice
Need Help Adding to Macros
 
Join Date: Apr 2016
Posts: 1
victoriapowers is on a distinguished road
Exclamation Need Help Adding to Macros

Hello,
I'm looking to edit a macros code and I'm having some issues. Right now our workbook includes a growing amount of days on a project (day 1, day 2, day 3, etc.).
We have the same employees working each day on the same project. I'm looking to add code to our current macros which would populate the names of the employees from the day before on each added sheet. I've added a screenshot of the spreadsheet to this post, notice "workers" on the bottom left.



I've included the existing code below.

Code:
Sub CreateNewDay()
'
' CreateNewDay Macro
' Creates new tab for daily work log
'
' Keyboard Shortcut: Ctrl+Shift+D
Dim InputValue As Variant
Dim NewName As String
Dim NewName1 As String


Sheets("Blank to Copy").Visible = True
Sheets("Blank to Copy").Select
ActiveWindow.SmallScroll Down:=-12
Sheets("Blank to Copy").Select
Sheets("Blank to Copy").Copy Before:=Sheets("Blank to Copy")
Sheets("Blank to Copy (2)").Select
Sheets("Blank to Copy (2)").Name = "Day (number)"

InputValue = InputBox("Please enter the date (mm/dd/yy):")
Range("B3") = InputValue



NewName = InputBox("Enter day number on job (i.e. 1,2,3..100):")
NewName1 = "Day " & NewName
ActiveSheet.Name = NewName1


Sheets("Blank to Copy").Visible = False


End Sub
Any information would be greatly appreciated. Thank you in advance for your time.
Attached Images
File Type: jpg Screenshot.jpg (238.0 KB, 16 views)

Last edited by Pecoflyer; 04-16-2016 at 07:12 AM. Reason: Added code tags
Reply With Quote
  #2  
Old 04-16-2016, 07:16 AM
Pecoflyer's Avatar
Pecoflyer Pecoflyer is offline Need Help Adding to Macros Windows 7 64bit Need Help Adding to Macros Office 2010 64bit
Expert
 
Join Date: Nov 2011
Location: Brussels Belgium
Posts: 2,771
Pecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant futurePecoflyer has a brilliant future
Default

Cross post without links http://www.excelguru.ca/forums/showt...3717#post23717

http://www.mrexcel.com/forum/excel-q...ng-macros.html
__________________
Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post
Reply With Quote
Reply

Tags
add macros, macros



Similar Threads
Thread Thread Starter Forum Replies Last Post
Need Help Adding to Macros How to automatically enable the macros upon opening a file with macros? laurieli Office 7 01-17-2016 08:56 AM
Need Help Adding to Macros Adding Image into a excel cell and adding a hyperlink to the image saravananiyyanar Excel 3 05-04-2011 08:31 AM
Macros Steveg Word VBA 0 08-18-2010 04:04 PM
Need Help Adding to Macros Macros Desertwrangler Word VBA 6 06-25-2010 07:06 AM
Need Help Adding to Macros Macros krdzal Excel 1 04-06-2010 07:43 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 07:08 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft