Search:

Type: Posts; User: LaVolpe

Search: Search took 0.21 seconds.

  1. Re: ways to provide a synchronous response from an asynchronous task

    @Olaf. My reply to Eduardo was pertaining to his most recent reply to me.

    There are very few options and unless someone wants to create some thunk or COM solution to act as an async>sync...
  2. Re: ways to provide a synchronous response from an asynchronous task

    Don't know if this could apply, but maybe have your ocx be a container for another ocx. That inner ocx is created as a control array where each does its own thing and forwards events to your outer...
  3. Re: ways to provide a synchronous response from an asynchronous task

    That's understandable if DoEvents is used. And of course even without DoEvents, if any code inside that function called another method that could trigger an event, then that event could be executing...
  4. Re: ways to provide a synchronous response from an asynchronous task

    @Olaf. Maybe semantics are at play here. From my posts, I am using the definitions: When you execute something synchronously, you wait for it to finish before moving on to another task. When you...
  5. Re: ways to provide a synchronous response from an asynchronous task

    Similar to what Olaf provided, I typically use a form/class-level variable that contains bitwise flags. Where a value of zero indicates no looping is going on, 1 indicates looping is active, 2...
  6. Re: ways to provide a synchronous response from an asynchronous task

    Well, option 3 doesn't really meet the definition of synchronous, does it? I think we all agree Option 1 is not very good, unless you are updating some software or the system maybe. And option 2,...
  7. Re: ways to provide a synchronous response from an asynchronous task

    @Eduardo. Well I will bow out of this thread. In the 1st example, you are using a DoEvents loop which unless you disabled your form/controls, the user is allowed to continue/abort while waiting on...
  8. Re: ways to provide a synchronous response from an asynchronous task

    Olaf. The reason for asking for clarification is that the OP also stated that he could check the state in some cases? Therefore, why check for the state if a completion event is sent? So, yes there...
  9. Re: ways to provide a synchronous response from an asynchronous task

    DoEvents leads to other issues if you fail to address them: user can close the form, access menus and other controls.

    What is the goal here? Prevent user from continuing until async action...
Results 1 to 9 of 9



Click Here to Expand Forum to Full Width