I wrote a small applet, but I found I meet some difficulties when switching task, that is, when my applet is running, sometimes ( not always ) I cannot use task management tools to switch to some other tasks. I did put a sleep(0) before event(1). Anyone knows some other reasons for this?

It seems the probelm is not solved by adding timer. Now I describe the scenario in detail.

My application will open a file and read it. Display it content in an Edit Box. User input is from Push Button.

Before it read the file, everything seems OK. I can switch to other tasks and back. But after file reading, I can switch to other tasks but cannot switch back. But every function of my application is normal even if I got this task switching problem. If I can quit from my application, everything will be ok again.

Now I found it seems related with the function of OpenFileDlg(). If I don't use this function to open file, everything will be ok. Do you know whether there is any known problem with this function? I'm using PocketC runtime 2.0.

The file enumerating functiuns have a lot of bugs in pocketC. But the only problems i have with this one is that it doesen't support multitype (IE: *.txt;*.rtf) on the PPC.
I have written my own file dialog header, but it crashes sometimes. just tell me if you need a copy.

BTW, do you know whether move to PocketC Runtime 3.0 will be helpful? Currently, I'm using PocketC 2.0 development tools and have no plan to purchase PocketC 3.0 development tools. So is it possible to develop application under 2.0 and run it under 3.0? (Well, seems a silly question)