print using TablePrint demo

I tried to do print preview & add some codes taken
from TablePrint demo to my Frame:

        prt = PrintTable(self)
        prt.label = ["Keterangan", "Data"]
        prt.set_column = []
        prt.data = [["Jenis Kelamin", "Laki-laki", ],
["Umur", "3"]]
        prt.SetFooter()
        prt.Preview()

when I run this event I got:

C:\Python23\lib\site-packages\wxPython\gdi.py:623:
DeprecationWarning: integer a
rgument expected, got float
  val = apply(gdic.wxDC_DrawRectangle,(self,) + _args,
_kwargs)
C:\Python23\lib\site-packages\wxPython\gdi.py:638:
DeprecationWarning: integer a
rgument expected, got float
  val = apply(gdic.wxDC_DrawText,(self,) + _args,
_kwargs)
C:\Python23\lib\site-packages\wxPython\gdi.py:611:
DeprecationWarning: integer a
rgument expected, got float
  val = apply(gdic.wxDC_DrawLine,(self,) + _args,
_kwargs)

Whats wrong???

Danu Kusmana

···

__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com

Could someone point me to sample code on accessing a MYSQL database and/or
ODBC.

Thanks,
Kenton

Hi, Kenton. This question is not really related to wxPython.

A quick google search turned up a couple promising links:

odbc on win32:

mysqldb for python:

which is a db api-2.0 compliant sql interface. For db api-2.0 info see:
http://www.python.org/topics/database/DatabaseAPI-2.0.html

Hope that helps,

Mark

···

On Sat, 2003-06-14 at 17:53, register@lomadeluz.net wrote:

Could someone point me to sample code on accessing a MYSQL database
and/or
ODBC.

danu kusmana wrote:
[...]

C:\Python23\lib\site-packages\wxPython\gdi.py:611:
DeprecationWarning: integer a
rgument expected, got float
  val = apply(gdic.wxDC_DrawLine,(self,) + _args,
_kwargs)

Whats wrong???

Nothing. The Python PyArg_ParseTuple* APIs in 2.4 will be changed to no longer do an implicit conversion to integer when passed a floating point value for an "i" parameter. In 2.3 you are getting warnings about it.

If anybody feels up to doing a patch for wxPython/lib/printout.py (Lorne?) I'd appreciate it.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!