In its relentless efforts to crash my VBA applications, MS has gone out of its way to render invalid numerous lines of SHELL commands in my VB applications:-
A search by browser brings up a slew of suggestions, including a warning that MS can change that "8wekyb3d8bbwe" at any time.
And of course I don't want to go through all my VBA code locating SHELL.EXE for Paint, Notepad etc and then do it again in a year's time.
Computers are supposed to serve me, not me them.
I'd love to hear of some magic bullet that would obviate this new set of hurdles to humble programmers.
I can see the new MSPaint.exe, so I am tempted to write yet-another-DOS-batch-file, but thought first to ask if there is a better way to get back to The Good Old Days. Locating and replacing all my SHELL calls to the MS Windows applications I use (because other people use my VBA code) seems to be on a level of labour akin to editing all the SHELL calls in the first place.
Thanks, Chris
(1) You guessed it! I have VBA code that generates images in documents and hands the documents to VBA code that compiles them to HTML ...
I used to be able to edit {INCLUDEPICTURE} fields(1) with a single click. Now a SHELL to MSPaint.exe fails.
We see that the (image) file referred by the variable "strFullname" still exists, but that MSPaint.exe is now in an encoded folder protected, presumably to safeguard the application that is installed when MSWindows 11 is installed. Doh!MSPaint.exe is now a UWP app ...
-
- PlutoniumLounger
- Posts: 17030
- Joined: 24 Jan 2010, 23:23
- Location: brings.slot.perky
MSPaint.exe is now a UWP app ...
You do not have the required permissions to view the files attached to this post.
It is better to Aim High and Fail than to aim low and succeed.
-
- Administrator
- Posts: 80372
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: MSPaint.exe is now a UWP app ...
As far as I can tell, you're using too many quotes:
works for me in Windows 11 / Microsoft 365.
Code: Select all
Shell "MSPaint.exe """ & strFullName & """", vbMaximizedFocus
Best wishes,
Hans
Hans