Problem with write binary data to OLE field in Access

2008-03-26 Thread lialie
, it is OK. Windows XP sp2; Python 2.4.4; Pywin32 210; Microsoft Access 2002 --- Regards, lialie -- http://mail.python.org/mailman/listinfo/python-list

Dispatch(Excel.Application) failed

2008-03-13 Thread lialie
Hi, Maybe it 's quite simple, but I can't fix it. Do I make some mistakes in my env setting? My excel version is 2003. any suggestion? Thanks. Traceback (most recent call last): File testexcel.py, line 3, in ? excel = Dispatch(Excel.Application) File

RE: Dispatch(Excel.Application) failed

2008-03-13 Thread lialie
speed is horribly slow when connect to Pywin32 project at SF. Regards, Lialie -- http://mail.python.org/mailman/listinfo/python-list

How to control the creation of an instance?

2007-06-02 Thread lialie
Hi, suppose i have a free_object list[Sample1, Smaple2]. when create a new object sample(*args, **kwds), if free_object_list isn't empty, just pop one from free_object_list instead of creating a new instance. any way to do this? I do some work as follows: class Sample(object): used_object

Why does my callback funtion collapse?

2007-04-05 Thread lialie
Hi,all I try to callback from a thread in C. But it collapsed. I can't figure it out. My test files attached. Thanks. #include windows.h #include Python.h #include stdio.h static PyObject *my_callback = NULL; DWORD threadId; HANDLE thread; static PyObject * callback_set_callback(PyObject

Too slow to read an entire table from Microsoft Access

2007-03-14 Thread lialie
Hi, all: I read a table with 4500 rows and 12 columns using win32com.client. Reading and updating records are OK, but cost too much time.Especially making a dict as line(***). All follows done may take nearly 90s! Is there any good idea? Thanks. conn =

quickly read a formated file?

2007-03-01 Thread lialie
Hi, Is there a fine way to read a formated file like: %HEADER title = Untilted username = User %DATA .. .. The formated file may be very popularly, but the module ConfigPaser doesn't handle it. Is there a way to process it freely? -- http://mail.python.org/mailman/listinfo/python-list

Is it good to create a thread in a non gui thread?

2006-12-14 Thread Lialie - KingMax
Hi, I create a thread in a non gui thread, and it does well. But it seems strange. Somebody told me better not for it may cause something hard to imagine. Is there any different between them? THX -- http://mail.python.org/mailman/listinfo/python-list

how to read a list from python in C?

2006-05-19 Thread Lialie KingMax
Hi, all I am writing a C extension with .Net. Now I have a list of points, like [(0.0, 0.0), (2.0, 3.0), (random x, random y)]. Is there a better way to translate it to an array than doing it one by one? Thanks -- http://mail.python.org/mailman/listinfo/python-list

Re: how to read a list from python in C?

2006-05-19 Thread Lialie
Thanks for your reply. yes, I pass a list as an argument to the function in C. The list has a random length. Do you mean to do it in this way? use PyTuple_Size(args), in a loop use PyTuple_GetItem(args, i) or use PyArg_VaParse? Best Regards --

Re: hyperthreading locks up sleeping threads

2006-05-09 Thread Lialie KingMax
I haven't try the files yet. But have got a similar problem before. The situation is nearly the same. Always at random time , it reported that the memory read or write violently.But I use Windows 2000(Python 2.3, wxPython 2.4). Windows issue says 2000 doesn't support HP, so I simply turn it off.

how to write special value to a config file with ConfigParser

2006-04-23 Thread Lialie
Hello,all I found it easy to read configures from a config file. But how can I set a special value to an item or write it into the original file? I have tried this: import ConfigParser config = ConfigParser.ConfigParser() config.read('a.conf') config.get('Main', 'Something') # That is OK.

Re: how to write special value to a config file with ConfigParser

2006-04-23 Thread Lialie
Lialie write: OK.I find out myself. Excuse me. Just open ini file in write mode. ---BeginMessage--- Lialie write: OK.I find out myself. Excuse me. Just open ini file in write mode. ---End Message--- -- http://mail.python.org/mailman/listinfo/python-list