Hi,
I'm using in my script command os.system('command') on Windows XP.
Each time the os.system command is used, python opens an empty ms-dos
command window (the black one) and then closes it. So when in one
script the os.system command 50 times is used, I see 50 black windows.
Is there a way of how to suppress this unnecessary command windows to
be opened?
thx.
Boris 4 2581
En Thu, 12 Jun 2008 05:28:13 -0300, boriq <bo***********@gmail.com>
escribió:
I'm using in my script command os.system('command') on Windows XP.
Each time the os.system command is used, python opens an empty ms-dos
command window (the black one) and then closes it. So when in one
script the os.system command 50 times is used, I see 50 black windows.
Is there a way of how to suppress this unnecessary command windows to
be opened?
Use the subprocess module instead of os.system
--
Gabriel Genellina
On 12 Jun., 11:51, "Gabriel Genellina" <gagsl-...@yahoo.com.arwrote:
En Thu, 12 Jun 2008 05:28:13 -0300, boriq <boris.smir...@gmail.com*
escribió:
I'm using in my script command os.system('command') on Windows XP.
Each time the os.system command is used, python opens an empty ms-dos
command window (the black one) and then closes it. So when in one
script the os.system command 50 times is used, I see 50 black windows.
Is there a way of how to suppress this unnecessary command windows to
be opened?
Use the subprocess module instead of os.system
--
Gabriel Genellina
I'm on version 2.2.1 because of a program we use and it uses this
version.
and the subprocess module was implemented in version 2.4
Any possibility to do it with the old stuff in ver 2.2.1?
Thx
En Thu, 12 Jun 2008 07:08:00 -0300, boriq <bo***********@gmail.com>
escribió:
On 12 Jun., 11:51, "Gabriel Genellina" <gagsl-...@yahoo.com.arwrote:
>En Thu, 12 Jun 2008 05:28:13 -0300, boriq <boris.smir...@gmail.com* escribió:
I'm using in my script command os.system('command') on Windows XP.
Each time the os.system command is used, python opens an empty ms-dos
command window (the black one) and then closes it. So when in one
script the os.system command 50 times is used, I see 50 black windows.
Is there a way of how to suppress this unnecessary command windows to
be opened?
Use the subprocess module instead of os.system
I'm on version 2.2.1 because of a program we use and it uses this
version.
and the subprocess module was implemented in version 2.4
Any possibility to do it with the old stuff in ver 2.2.1?
Sure, depending on your needs, use any of the os.popen variants or any of
the os.spawn variants.
--
Gabriel Genellina
Gabriel Genellina wrote:
En Thu, 12 Jun 2008 07:08:00 -0300, boriq <bo***********@gmail.com>
escribió:
>On 12 Jun., 11:51, "Gabriel Genellina" <gagsl-...@yahoo.com.arwrote:
>>En Thu, 12 Jun 2008 05:28:13 -0300, boriq <boris.smir...@gmail.com> escribió:
I'm using in my script command os.system('command') on Windows XP. Each time the os.system command is used, python opens an empty ms-dos command window (the black one) and then closes it. So when in one script the os.system command 50 times is used, I see 50 black windows.
Is there a way of how to suppress this unnecessary command windows to be opened?
Use the subprocess module instead of os.system I'm on version 2.2.1 because of a program we use and it uses this version.
and the subprocess module was implemented in version 2.4
Any possibility to do it with the old stuff in ver 2.2.1?
Sure, depending on your needs, use any of the os.popen variants or any
of the os.spawn variants.
Or you can download the external module which became the subprocess
module in the stdlib: http://www.lysator.liu.se/~astrand/popen5/
TJG This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Evan Kontos |
last post by:
I am using the window.open function to open a small window and I am
using GET to get values back from that window. I want to be able to open
another from the second window but I get an error...
|
by: Laura Zeafla via .NET 247 |
last post by:
I have an application I wrote using the Windows Form Application(.NET) wizard. Pressing a button calls a function in a dllwritten in Visual C++. This function is supposed to cause acommand prompt...
|
by: Kartik |
last post by:
Hi,
I have an ASP.NET application using VB.NET.I am sending a DOS command to a
machine on the network to print a file.
This is achieved using xp_cmdshell
Dim str As String = "xp_cmdshell...
|
by: D. Alvarado |
last post by:
Hello,
I am trying to open a window containing an image and I would like
the image to be flush against the window -- i.e. have no padding or
border. Can I make this happen with a single call to a...
|
by: sjp |
last post by:
I need to open new windows only for the purpose of viewing linked
images, maybe a dozen or so throughout the site. Using the
Target="blank" command is quick, easy and seems like the best way to...
|
by: DFS |
last post by:
I'm using a query as the SourceObject for a subform. When I change any of
the column widths and try to close the form I'm prompted to save changes to
the layout.
Anyone know how to suppress...
|
by: January Smith |
last post by:
When I run the code below after creating an Empty .Net type project and
adding an Empty C++ file it always opens a command window before displaying
the form. If I write a similar VB application by...
|
by: brianflannery |
last post by:
Greetings! My situation is this. I currently have a database of
which in a form displays jpeg pictures (one at a time) which are
linked to the db and stored in a separate folder. I have set up a...
|
by: bbrewder |
last post by:
I am struggling with some MSAccess automation issues. Basically, we
have a .Net application that uses MSAccess for reporting (legacy
code). We are able to launch MSAccess fine and even work with...
|
by: Kemmylinns12 |
last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and efficiency. While initially associated with cryptocurrencies...
|
by: Naresh1 |
last post by:
What is WebLogic Admin Training?
WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge required to effectively administer and manage Oracle...
|
by: AndyPSV |
last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and...
|
by: Arjunsri |
last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and credentials and received a successful connection...
|
by: WisdomUfot |
last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific technical details, Gmail likely implements measures...
|
by: Matthew3360 |
last post by:
Hi,
I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web server and have made sure to enable curl. I get a...
|
by: Oralloy |
last post by:
Hello Folks,
I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA.
My problem (spelled failure) is with the synthesis of my design into a bitstream, not the C++...
|
by: Rahul1995seven |
last post by:
Introduction:
In the realm of programming languages, Python has emerged as a powerhouse. With its simplicity, versatility, and robustness, Python has gained popularity among beginners and experts...
|
by: Ricardo de Mila |
last post by:
Dear people, good afternoon...
I have a form in msAccess with lots of controls and a specific routine must be triggered if the mouse_down event happens in any control.
Than I need to discover what...
| |