This works for me in 2003:
Set myBar = Application.CommandBars("Testing")
Set myControl = myBar.Controls _
.Add(Type:=msoControlButton, Before:=3)
With myControl
.FaceId = 2950
.OnAction = app & "!rowdn"
.DescriptionText =...
Thank you so much!
I'm familiar with FileCopy, but am not sure how to specify a variable in a destination path, so it would work for the currient user. I know that %userprofile% wouldn't work here. Any suggestions?
Thanks again,
Borman2005
Thanks for the fast reply!
I really appreciate your help!
So, if for example, I'm logged in as "JDoe", and I want the macro to copy "C:\test\test.doc" file to "C:\Documents and Settings\JDoe\Test", how would I use it in that code?
Borman2005
Can someone help me with VBA code to have an Excel macro to copy files into a folder within a "current user" folder? Basically, when current user would click on a macro button, it would copy files into a specified folder within his\her userprofile.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.