This line works in Excel 2010, but will not work on my work laptop running Excel 2013! It works up to/including "documents", then when I add the rest it errors. Any help appreciated!
Please Login or Register to view this content.
This line works in Excel 2010, but will not work on my work laptop running Excel 2013! It works up to/including "documents", then when I add the rest it errors. Any help appreciated!
Please Login or Register to view this content.
what does this give you on 2013 machine?Please Login or Register to view this content.
If you are satisfied with the solution(s) provided, please mark your thread as Solved.
Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.
The path C:\Users\Computername
what is the exact error message?
cant find any fault in the line of code you have given
Last edited by humdingaling; 09-07-2016 at 10:39 PM.
does that folder exist on your 2013 machine?
Try saving it somewhere else.
Hi,
Does that pdf file already exist when you run the code?
Don
Please remember to mark your thread 'Solved' when appropriate.
It's the date reference I think! As part of the filename I reference two cells, one is a cell with the formula "=today(), in Excel 2010 32bit, it displays in vba as 09-10-2016 which is fine as a filename, but in Excel 2013 64bit, it displays the date as 09/10/2016 which it does not allow as a filename.
How do I get Excel 2013 to display the date that is an acceptable filename? I have changed the format of the cell, but in vba it still shows it with the "/"!
I can't tell by your description of your dates which way around the months and days are (or even which cell contains the date) but for an example try something like...
Please Login or Register to view this content.
Last edited by WasWodge; 09-10-2016 at 12:15 PM.
If my solution worked (or not) please let me know. If your question is answered then please remember to mark it solved
Computers are like air conditioners. They work fine until you start opening windows. ~Author Unknown
Personally I have my Regional settings as dd/mm/yyyy and prefer them that way.
Because of this, in my case I wouldn't change them just to have a legitimate file name to save in Excel, so I use a similar solution to what I posted in post #11.
Like I stated though that is only my personal preference.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks