Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Text Previewer (windows only)
#11
Updated (Thanks to RhoSigma's suggestion) to include toggles for the various PrintModes.
Reply
#12
All I got out of this was Steve broke SHELL. When will that be fixed? Please don't go using chewing gum and twins... I mean twine.

Pete Big Grin

- I always look good in text.
Reply
#13
There have always been issues with SHELL in CONSOLE:ONLY vs regular window. I've just accepted them and found ways around them.
Tread on those who tread on you

Reply
#14
(03-17-2024, 07:16 PM)SMcNeill Wrote: SHELL is broken.  Sad

Try these three examples:

Code: (Select All)
$Console:Only
Shell _Hide "reg query " + Chr$(34) + "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" + Chr$(34) + " /s > temp.txt"

Code: (Select All)
$Console:Only
Shell "reg query " + Chr$(34) + "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" + Chr$(34) + " /s > temp.txt"

Code: (Select All)
Shell "reg query " + Chr$(34) + "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" + Chr$(34) + " /s > temp.txt"

$CONSOLE:ONLY and SHELL works.
$CONSOLE:ONLY and SHELL HIDE doesn't work.
SHELL withotu $CONSOLE:ONLY doesn't work.

/SIGH
Run into this a lot.
If it does not work, try adding "cmd /c " in front of your command
That fixes is 99% of the time
Code: (Select All)
$Console:Only
Shell _Hide "cmd /c reg query " + Chr$(34) + "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts" + Chr$(34) + " /s > temp.txt"
45y and 2M lines of MBASIC>BASICA>QBASIC>QBX>QB64 experience
Reply
#15
The only 100% workaround that I've found is just to write the shell command into a batch file and then call it from there.  Crazy, but it is what it is.

I found another SHELL that was almost impossible to deciper the other day.  It was something like:

 foo print 123 > text.txt

From the command line, it worked with no isses.

From SHELL, it ended up having to be something like:

SHELL chr$(34) + "powershell 'foo print 123' > text.txt" + CHR$(34)

The entire powershell command had to be listed inside the single quotes, so it'd process as a single command, and then *everything* had to be encased in quotes so that CMD wouldn't break it apart into multiple, fractional calls to crap.

Lord, the hoops to ump throug, for something so simple!!
Reply




Users browsing this thread: 2 Guest(s)