TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Phil Crown
from: Darin McBride
date: 1996-09-03 20:53:00
subject: Window Title

DN> I did a little checking and could find no docs on WinSetTitle but
 DN> found it in OS2386.LIB so I guessed at the prototype and voila!
 PC>                     ^^^
 PC> You mean os2286.lib?

Probably...


 DN> #define WinSetTitle WIN16SETTITLE

 DN> APIRET16 APIENTRY16 WinSetTitle (HAB hab,
 DN> PSZ title);

 PC>  [snip]


 PC> #include 

 PC> #define INCL_WIN
 PC> #include 

It won't be there.  You have to give it the prototype yourself.  Further,
it is Win16SetTitle, not WinSetTitle.

 PC> APIRET16 APIENTRY16 WinSetTitle (HAB hab, PSZ title);

APIRET16 APIENTRY16 Win16SetTitle(HAB hab, PSZ title);

 PC> int main(int argc, char* argv[])
 PC> {
 PC>    if (argc > 1)
 PC>       WinSetTitle(0, argv[1]);

           Win16SetTitle(0, argv[1]);

 PC>    getch();

 PC>    return 0;

Borland seems to give problems unless you actually use return(0);  For some
reason, it needs the parenthesis - this will likely get rid of the sys
error... :-)


--- Maximus/2 3.01
* Origin: Tanktalus' Tower BBS (PVT) (1:342/708)
SEEN-BY: 50/99 270/101 620/243 625/100 711/401 409 410 413 430 808 809 934
SEEN-BY: 711/955 712/407 515 624 628 713/888 800/1
@PATH: 342/5015 61 3615/50 396/1 270/101 712/515 711/808 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.