Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c++ > #70207

Re: popup with timeout question

From T <T@invalid.invalid>
Newsgroups comp.lang.c++
Subject Re: popup with timeout question
Date 2019-12-03 01:17 -0800
Organization A noiseless patient Spider
Message-ID <qs597m$ict$1@dont-email.me> (permalink)
References <qs4q9c$ghd$1@dont-email.me> <qs55er$vdl$1@dont-email.me>

Show all headers | View raw


On 2019-12-03 00:13, Paavo Helde wrote:
> On 3.12.2019 7:02, T wrote:
>> Hi All,
>>
>> I write in Perl6.  I wrote a module to give me a pop up
>> in Windows to send information to the user.  It uses
>> a native call and I do believe it is a C++ call, but I
>> really don't know what I am doing when it comes to
>> anything C.
> 
> C and C++ are two different languages. Windows SDK interface is defined 
> in C, not C++.
> 
>>
>> Do any of you guys know how to add a time out to the
>> pop up?  I do believe it would be in the choice of the
>> constants.
>>     MessageBoxW( my $handle, to-c-str( $MessageStr ), to-c-str(
>> $TitleStr ), MB_ICONEXCLAMATION );
> 
> MessageBoxW is documented at 
> "https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-messagebox" 
>   - it does not mention any timeout.
> 
> I have written some code for a "Windows popup with timeout" in C++, but 
> I doubt it will help you. It displays the message box in a separate 
> thread, while the main thread waits for it on a condition variable with 
> a timeout.
> 
> I guess you would get better responses in forums where Perl or Windows 
> are on topic.
> 
> 

Hi Paavo,

Now I know were and what is going on with my MessageBoxW call.

On your reference, I also found MessageBoxIndirectA and 
MessageBoxIndirectW.   Maybe they will work.  It is worth
experimenting!

Thank you!

-T

Back to comp.lang.c++ | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

popup with timeout question T <T@invalid.invalid> - 2019-12-02 21:02 -0800
  Re: popup with timeout question Paavo Helde <myfirstname@osa.pri.ee> - 2019-12-03 10:13 +0200
    Re: popup with timeout question T <T@invalid.invalid> - 2019-12-03 01:17 -0800
  Re: popup with timeout question "Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com> - 2019-12-03 11:08 +0100
    Re: popup with timeout question T <T@invalid.invalid> - 2019-12-03 03:06 -0800
  Re: popup with timeout question Geoff <geoff@invalid.invalid> - 2019-12-03 12:28 -0800
    Re: popup with timeout question T <T@invalid.invalid> - 2019-12-03 14:14 -0800
      Re: popup with timeout question Geoff <geoff@invalid.invalid> - 2019-12-04 01:19 -0800
        Re: popup with timeout question T <T@invalid.invalid> - 2019-12-10 04:07 -0800

csiph-web