Hi, Looking to change up my code it doesn't stop and wait for the file to open so the send keys doesn't work.
![]()
Please Login or Register to view this content.
Hi, Looking to change up my code it doesn't stop and wait for the file to open so the send keys doesn't work.
![]()
Please Login or Register to view this content.
Hello jimrosser,
It is seldom necessary to have select or activate objects in VBA before using them.
If you can explain in words what you are doing then we can find a solution for you.
Sincerely,
Leith Ross
Remember To Do the Following....
1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.2. Thank those who have helped you by clicking the Starbelow the post.
3. Please mark your post [SOLVED] if it has been answered satisfactorily.
Old Scottish Proverb...
Luathaid gu deanamh maille! (Rushing causes delays!)
All the macro is trying to do is primarily open and save the file depending on the date. It will run a total of 10 times. It has no problem with smaller files but one it reaches some of size it begins to open the additional files and skips the sendkeys function.
Hello jimrosser,
That's the part that doesn't make sense to me. Are you wanting to change the last modified date of the most recent file?All the macro is trying to do is primarily open and save the file depending on the date.
If your attempting to Open/Edit/Close text files then you should look at the commands that involve opening files for input
example colde here shows "Open .. for Input" method to open and edit text files.
F1 = FreeFile
Open SourceFile For Input As F1
![]()
Please Login or Register to view this content.
The files are being sent down from a server and some of the data is garbled. So the only way to fix the files is to manually open and save the files. However I'd like to be able to do this without having to manually sit and wait each morning.
Hello jimrosser,
This will open and the close the file without using Notepad or having to wait.
![]()
Please Login or Register to view this content.
Thanks Leith! It's like a rocketship compared to what I was attempting to run.
Hello jimrosser,
You're welcome.
Still having issues as the way the files are written they must be opened in notepad to remove the hard returns and other garbage that's being passed down.
Hello jimrosser,
To solve this problem, I need a copy of the raw data for testing. Without a before and after files for comparison, I can do nothing for you.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks