Access to Win API

  • Thread starter Ladvánszky Károly
  • Start date
L

Ladvánszky Károly

What is the best way to access Win API functions that are not present in the
various extension packages. Is writing a C extension the only solution?
Thanks for any help.

Károly
 
?

=?ISO-8859-1?Q?Gerhard_H=E4ring?=

Ladvánszky Károly said:
What is the best way to access Win API functions that are not present in the
various extension packages. Is writing a C extension the only solution?

You don't have to write a C extension, you can use ctypes instead.

-- Gerhard
 
L

Ladvánszky Károly

Thanks for your help. I remember once I tried a Python cookbook sample code
that included ctypes but now 'import ctypes' does not work.
Should ctypes come together with the 2.3 installation?

Károly

"Gerhard Häring" <[email protected]> az alábbiakat írta a következo
hírüzenetben: (e-mail address removed)...
Ladvánszky Károly said:
What is the best way to access Win API functions that are not present in the
various extension packages. Is writing a C extension the only solution?

You don't have to write a C extension, you can use ctypes instead.

-- Gerhard
 
?

=?ISO-8859-1?Q?Gerhard_H=E4ring?=

Ladvánszky Károly said:
Thanks for your help. I remember once I tried a Python cookbook sample code
that included ctypes but now 'import ctypes' does not work.
Should ctypes come together with the 2.3 installation? [...]

No, it's a third-party module that you need to download and install.

Google says it's at http://starship.python.net/crew/theller/ctypes/, but
the Starship seems to be down ATM [1]. Maybe somebody has the ctypes
installer for Python 2.3 and can send it to you. I only have ctypes 0.2
for Python 2.2 here ATM.

-- Gerhard

[1] Probably the recent virus flood bogs down the server :-/
 
M

Michael Hudson

Gerhard Häring said:
Ladvánszky Károly said:
Thanks for your help. I remember once I tried a Python cookbook sample code
that included ctypes but now 'import ctypes' does not work.
Should ctypes come together with the 2.3 installation? [...]

No, it's a third-party module that you need to download and install.

Google says it's at http://starship.python.net/crew/theller/ctypes/,
but the Starship seems to be down ATM [1].

It's only DNS woes. Try IP 217.160.219.194.

Cheers,
mwh
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,164
Messages
2,570,898
Members
47,439
Latest member
shasuze

Latest Threads

Top