Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Win32_ProcessStartup
Message
From
22/11/2002 18:17:08
 
 
To
22/11/2002 08:53:55
Roman Segaud
Laboratoires Fortepharma
Nice, France
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00724194
Message ID:
00726071
Views:
28
Roman,
If I understand you correctly (correct me if I'm wrong)

>It's work fine, is-it possible to share with the child process the parent object environment and to "BINDS" some event of the parent object ?
>

to bind event you could try use CreateEvent and SetEvent in the parent process and then OpenEvent in the child process. I think www.news2news.com has the example for this

>To recover the data generated by the child process I write some API function to put these data directly into memory and recover them, but it's not to fast, to be sure to properly recover these data i must use some code like :
>
>Mem_copy(cVar, cdata)
>nCounter = 0
>Do while nCounter < 1000
> nCounter = nCounter + 1
> If Mem_Read(cVar)
> Exit
> Endif
> Sleep(100)
>EndDo
>
>In my child process, and now I can use the same Mem_Read function in my parent process, and it will work.
>
>Perhaps, I can use a structure (base on Process class) to recover directly these data ?
>

If you only want to pass in a string and get the result also in string,
I think the simplest method is to use file between the process, StrToFile and FileToStr or use a MEM file. Can it be done ? Or you can try use Clipboard to pass it, this is more safe to copy your string from memory. That's my idea.
Anyway if your program already works why don't you just use it. Cause 1000 iteration I don't think it will slow down the performance too much. Try to decrease the Sleep until you get the perfect timing.

HTH
Herman
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform