Never done it myself but I would suggest writing the c struct to a temp file.
Then call the python script using normal system call in C
(http://en.wikipedia.org/wiki/System_%28C_standard_library%29)
and read the temp file using struct module from python
http://docs.python.org/library/struct.html
You can just use Shell or AdvShell[1] to run python.exe and the script
name as parameter; If you have the associations that the python
installer setups you might just be able to use just the script name.
~Gerdus
http://www.freevbcode.com/ShowCode.Asp?ID=1282
On Mon, Oct 26, 2009 at 4:38 PM,
You would probably rename the
comtypes.gen._683BF642_E9CA_4124_BE43_67065B2FA653_0_1_0
to something more sensible
Creating an instance would be easier if you use code like
this which uses the _reg_clsid_ attribute from the generated CoClass:
from win7taskbar import ITaskbarList3, TaskbarList
interface if I decide to use this code.
Anyway usage is then straightforward:
taskbar.HrInit()
taskbar.SetProgressValue(hWnd,25,100)
Anyway I'm guessing/hoping there will be Windows 7 support in a future
version of win32com :-)
~G
On Thu, Sep 24, 2009 at 3:24 PM, Gerdus van Zyl gerdusvan
Hi,
Has anybody played with the win7 taskbar api? I just love the taskbar
progress bar and would like it in my little app. But since win7 isn't
even commercially available (i got mine from msdn) samples are scarce.
Working from some pascal examples /vb.net interop examples /msdn docs
I made the
I would say try socket.gethostbyname;
http://docs.python.org/library/socket.html#socket.gethostbyname
On Thu, Aug 27, 2009 at 2:59 PM, Dahlstrom,
Rogerrdahlst...@directedge.com wrote:
Ping it and get the address.
-Original Message-
From:
Do you set a socket timeout value via socket.setdefaulttimeout?
see: http://www.python.org/doc/2.6/library/socket.html#socket.setdefaulttimeout
~Gerdus
On Thu, Aug 13, 2009 at 7:17 PM, Marte Solizamyrtac...@gmail.com wrote:
I'm using httplib as an HTTP client for a custom HTTP server. One thing
Have you tried Spy++ I think it's part of the windows SDK tools.
On Sun, Aug 9, 2009 at 6:09 PM, Eric Bladeblade.e...@gmail.com wrote:
This is kind of a weird question - I have a process that has two
windows with the exact same name. I need to figure out some way to
differentiate between the
See this page:
http://eli.thegreenplace.net/2008/06/28/compiling-python-extensions-with-distutils-and-mingw/
it has helped me with something similar and tells how to make a mingw
compatable libpython25.a;
In newer mingw version I think it can figure out the exports (the .a)
from the dll itself.
very nice! I was looking at pyjd a while back but didn't like the gtk
dependency. Any posibility on porting hulahop to windows?
~Gerdus
On Mon, Aug 3, 2009 at 12:22 AM, lkcll...@lkcl.net wrote:
hi there,
from about a dozen different sources i've managed to put together something
similar to
Are you trying to copy a table from an access database to a postgres
database? Because that's the impression I get, in which case do you
need to do it once or do you need to do it regularly? In both cases
Python might not be an optimal choice.
You might have more luck using TransferDatabase and
1)
filename = C:/Program Files (x86)/NSIS/makensisw.exe
doc = install.nsi
status = os.system('%s %s' % (filename, doc))
print Status: , status
If you have long running program you want the output from there are
other options but the above is easiest imho.
2) just open the python file using the
My favourites are in order of preference:
nbPython - http://wiki.netbeans.org/Python (get a latest development build)
pydev - http://pydev.sourceforge.net/
~Gerdus
___
python-win32 mailing list
python-win32@python.org
another problem.
santosh-r4c:~/python-sybase-0.39/python-sybase-0.39 # python setup.py
install
Directory /root/python-sybase-0.39/python-sybase-0.39/include does not exist
- cannot build.
CAn you help me!
Thanks,
Santosh
On Mon, Jun 1, 2009 at 5:11 PM, Gerdus van Zyl gerdusvan...@gmail.com
Ok try installing the python-devel package.
On Mon, Jun 1, 2009 at 1:13 PM, Santosh Mohan santosh@gmail.com wrote:
Python is the same of SLES10 distro
santosh-r4c:~ # python -V
Python 2.4.2
On Mon, Jun 1, 2009 at 3:28 PM, Gerdus van Zyl gerdusvan...@gmail.com
wrote:
what python
Ah, ok. Thank you.
On Thu, May 14, 2009 at 12:24 AM, Mark Hammond skippy.hamm...@gmail.comwrote:
On 11/05/2009 11:16 PM, Gerdus van Zyl wrote:
I got the same error in visual studio and the solution is to set
compilation to 32bit since jet does not exist for vista-64bit. I have
python64 so
The following code:
conn = win32com.client.Dispatch(r'ADODB.Connection')
DSN = 'PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA SOURCE=%s;Jet
OLEDB:Database Password=root' % dbName
conn.Open(DSN)
gives:
com_error: (-2147352567, 'Exception occurred.', (0,
u'ADODB.Connection', u'Provider cannot be found. It
It seems it's not possible if as mentioned you aren't replacing a line
with a line of the same lenght/bytes. You then have to resort to using
intermediate files see: http://python.pastebin.com/f539b4e46
On Sun, May 3, 2009 at 1:01 PM, Robert kxrobe...@googlemail.com wrote:
Khalid Moulfi wrote:
see http://rafb.net/p/7WVngC64.html
I modified it till it worked and fixed some style issues. As suggested
there are many excellent python tutorials available which may be of
use.
On Sun, Apr 5, 2009 at 4:13 AM, DynamicBit dynamic...@gmail.com wrote:
Hi!
Got this problem,
Firstly there is no module called win32; only things like win32api or
win32gui, etc. (May have changed in py3k version?)
Otherwise check your python path in pydev:
Go Window - Preferences - Pydev - Interpreter - Python
On my system there is an entry for
c:\python25\lib\site-packages\win32; if a
I see a couple of problems with your code:
1. where is n first given a value and what is it total file count,
etc? also you decrement the value, do you want the last file in the
directory or something?
2. The if os.path.isdir(full_path): .. findFile(full_path) part
doesn't return or handle the
On Tue, Feb 24, 2009 at 12:49 PM, Gerdus van Zyl gerdusvan...@gmail.com
wrote:
I see a couple of problems with your code:
1. where is n first given a value and what is it total file count,
etc? also you decrement the value, do you want the last file in the
directory or something?
2
Try using the normal file access functions, eg: open(file,r), etc.
~G
On Mon, Feb 23, 2009 at 6:14 AM, venu madhav venutaurus...@gmail.com wrote:
Hello all, I am writing an application where I need to open a shared file on
a remote machine using python script. I tried using the following
Try removing it from PATHEXT, it seems to work fine without just going
on the file association. At least on my PC.
~Gerdus
On Sun, Nov 16, 2008 at 8:04 PM, sayeo87 [EMAIL PROTECTED] wrote:
Right now on Windows I have added .py to my PATHEXT so that I can run .py
files by doing ./filename.py.
Try pyglet [pyglet.org]. It wraps avbin for mp3,ogg reading and plays
using directsound, alsa, etc. Not sure if it could be made
easy_installable.
~Gerdus
On Tue, Aug 12, 2008 at 8:14 AM, Michael Gundlach [EMAIL PROTECTED] wrote:
Hi,
Is there a way to play an MP3 from Python 2.5 in Windows,
Wel firstly it won't work, the class should be:
class a(object):
def b(self):
print b
def c(self):
print c
so to call b you first need instance of object:
myA = a()
myA.b()
I am not really understanding what you wish to achieve. Also you say
I went thru the notes., what
And of course REAL programmers use butterflies. http://xkcd.com/378/
On Mon, Jun 23, 2008 at 12:54 PM, Dahlstrom, Roger
[EMAIL PROTECTED] wrote:
Well *I* used to line up rocks in to ones and zeros. Then I had a toucan
that would interpret them, and chisel the gui on to a stone tablet. I
From some googling it seems to be a file permission problem.
see http://www.bellaonline.com/articles/art17684.asp and
http://support.microsoft.com/?scid=kb%3Ben-us%3B315456
As a workaround you can make a local access database, use link tables
to connect to the remote database, then point your
Have you seen www.htmltopdf.org?
Otherwise might I suggest http://www.openreport.org/; you could then
transform your XML into RML(xml reporting format) into a PDF. You can also
design RML with OpenOffice.
~Gerdus
On Tue, May 27, 2008 at 10:41 PM, Rickey, Kyle W
[EMAIL PROTECTED] wrote:
Tim,
Depends on how python is integrated with maya, are there other plugins
that use external GUI libraries? You might want to ask a maya list
they will know better.
On Mon, May 19, 2008 at 8:14 PM, kNish [EMAIL PROTECTED] wrote:
I need to call it from inside Maya.
On Mon, May 19,
See this blog post:
http://www.kunxi.org/archives/2008/01/pythonsoap-second-encounter/
http://pywebsvcs.sourceforge.net/
http://trac.optio.webfactional.com/
The choice depends on your requirements.
On Fri, Apr 11, 2008 at 8:58 PM, Sagar Khushalani [EMAIL PROTECTED]
wrote:
i guess this
So to answer my own question: use win32gui.PumpWaitingMessages, it
uses peekmessage.
so you can then replace
PumpMessages()
with:
while PumpWaitingMessages() == 0:
#some idle function or processing here
~gvz
On Fri, Mar 28, 2008 at 11:59 AM, Gerdus van Zyl [EMAIL PROTECTED] wrote:
Hi
Hi,
How can I run a function when the event loop is idle? It's for
animation and some layout calculation. Currently I am doing that using
threads but the responsiveness of my application is suffering.
Thank you
~Gerdus
___
python-win32 mailing list
Try one of these: (in order of my preference)
http://datamining.anu.edu.au/~ole/pypar/
http://www.parallelpython.com/
http://www.its.caltech.edu/~astraw/seppo.html
http://www-users.cs.york.ac.uk/~aw/pylinda/
They exist on a higher level than pure IPC in that running a master
server, spawning
I would say premature optimization :-) Was just wondering if there
was some standard way to structure a graphics/gdi program. for
example: Message maps suck! use XYZ or ABC instead.
~GerdusVZ
On Feb 8, 2008 5:35 PM, Larry Bates [EMAIL PROTECTED] wrote:
Gerdus van Zyl wrote:
Hi
Please
and don't know what is the best way to do things.
Thank You,
Gerdus van Zyl
from win32api import *
try:
from winxpgui import *
except ImportError:
from win32gui import *
import win32con
import sys, os
import cairo
import thread
import time
from random import randint,random
from pprint import
it as an
exercise to the reader to make the reader window hidden instead if so
desired.
~Gerdus van zyl
On Feb 3, 2008 1:29 AM, Michel Claveau [EMAIL PROTECTED] wrote:
Hi!
Perso, I use Adobe-Reader AND SumatraPDF.
And, SumatraPDF has command-line options for print directly a file.
See : http
37 matches
Mail list logo