Re: LEP - hide console?

2019-04-09 Thread Bruno LEGAY via 4D_Tech
Hi Pat,

Call 

SET ENVIRONMENT VARIABLE("_4D_OPTION_HIDE_CONSOLE";"true")

before calling LEP

HTH
Bruno

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: LEP - hide console?

2019-04-09 Thread Pat Bensky via 4D_Tech
So simple!
thanks guys.

On Tue, 9 Apr 2019 at 11:39, Jeffrey Kain via 4D_Tech <4d_tech@lists.4d.com>
wrote:

> Hi Pat,
>
> Did you try calling SET ENVIRONMENT VARIABLE with the
> _4D_OPTION_HIDE_CONSOLE option?  It works with normal batch windows... not
> sure about PowerShell windows.
>
>
> https://doc.4d.com/4Dv15/4D/15.6/SET-ENVIRONMENT-VARIABLE.301-3817570.en.html
>
> Jeff
>
>
> > On Apr 9, 2019, at 5:34 AM, Pat Bensky via 4D_Tech <4d_tech@lists.4d.com>
> wrote:
> >
> > So I now have a Powershell script which converts a Word document to PDF.
> > Unfortunately it briefly shows the Powershell console window when it
> starts
> > the script, which is rather ugly and I would prefer not to inflict it
> upon
> > my users.
> > Is there any way to prevent it from appearing?
> >
> > Here's my LEP code:
> >
> > $tExecute:="powershell -windowstyle hidden -ExecutionPolicy ByPass -File
> > "+Char(34)+$ScriptPath+Char(34)+" "+Char(34)+tDocnameWord+Char(34)
> > LAUNCH EXTERNAL PROCESS($tExecute)
> >
> > "-windowstyle hidden" stops the console from being displayed the whole
> time
> > the script is running, but it still appears for a couple of seconds.
>
> **
> 4D Internet Users Group (4D iNUG)
> Archive:  http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
> **



-- 
*
CatBase - Top Dog in Data Publishing
tel: +44 (0) 207 118 7889
w: http://www.catbase.com
skype: pat.bensky
*
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: LEP - hide console?

2019-04-09 Thread Jeffrey Kain via 4D_Tech
Hi Pat,

Did you try calling SET ENVIRONMENT VARIABLE with the _4D_OPTION_HIDE_CONSOLE 
option?  It works with normal batch windows... not sure about PowerShell 
windows.

https://doc.4d.com/4Dv15/4D/15.6/SET-ENVIRONMENT-VARIABLE.301-3817570.en.html

Jeff


> On Apr 9, 2019, at 5:34 AM, Pat Bensky via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> So I now have a Powershell script which converts a Word document to PDF.
> Unfortunately it briefly shows the Powershell console window when it starts
> the script, which is rather ugly and I would prefer not to inflict it upon
> my users.
> Is there any way to prevent it from appearing?
> 
> Here's my LEP code:
> 
> $tExecute:="powershell -windowstyle hidden -ExecutionPolicy ByPass -File
> "+Char(34)+$ScriptPath+Char(34)+" "+Char(34)+tDocnameWord+Char(34)
> LAUNCH EXTERNAL PROCESS($tExecute)
> 
> "-windowstyle hidden" stops the console from being displayed the whole time
> the script is running, but it still appears for a couple of seconds.

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: LEP - hide console?

2019-04-09 Thread Epperlein, Lutz (agendo) via 4D_Tech
SET ENVIRONMENT VARIABLE("_4D_OPTION_HIDE_CONSOLE";"true")

And see:
https://doc.4d.com/4Dv17/4D/17.1/LAUNCH-EXTERNAL-PROCESS.301-4178683.en.html

9. To launch a command with the current directory and without displaying the 
console:

 SET ENVIRONMENT VARIABLE("_4D_OPTION_CURRENT_DIRECTORY";"C:\\4D_VCS")
 SET ENVIRONMENT VARIABLE("_4D_OPTION_HIDE_CONSOLE";"true")
 LAUNCH EXTERNAL PROCESS("mycommand")

Regards
Lutz

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**