Gamestudio Links
Zorro Links
Newest Posts
No connection to MT4
by JeyKey II. 10/29/26 09:34
Zorro plugin for Hyperliquid.xyz
by opm. 10/28/26 13:50
Icon "OP"
by JeyKey II. 10/27/26 07:03
ZorroGPT
by TipmyPip. 10/26/26 08:09
Chat Room for Zorro Programmers
by Haitao_Ren. 10/25/26 03:14
Trading Journey
by Haitao_Ren. 10/25/26 03:14
AUM Magazine
Latest Screens
Dorifto samurai
Shadow 2
Rocker`s Revenge
Stug 3 Stormartillery
Who's Online Now
1 registered members (LucasJoshua), 18,135 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Haitao_Ren, JimSimons, julienp, julienper, KelleyAbbey
19247 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Please Add title bar parameter to error() #283303
08/07/09 00:58
08/07/09 00:58
Joined: Dec 2006
Posts: 434
UK,Terra, SolarSystem, Milky W...
pararealist Offline OP
Senior Member
pararealist  Offline OP
Senior Member

Joined: Dec 2006
Posts: 434
UK,Terra, SolarSystem, Milky W...
Hi,

Would it be possible to add the title bar string to the
error() function?
OR
could you overload the error function

Code:
error("title str","message");



if title str is "" then it displays the default error code
in title bar, else it displays title str.

This is because i like to display in which function
the error takes place in the title bar.

Last edited by pararealist; 08/07/09 01:03.

A8.3x Commercial, AcknexWrapper and VS 2010 Express
○pararealist now.
Re: Please Add title bar parameter to error() [Re: pararealist] #283332
08/07/09 08:56
08/07/09 08:56
Joined: Jul 2000
Posts: 28,145
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 28,145
Frankfurt
The error() function is sort of superfluous in lite-C. You can just use the Windows MessageBox function, with any title and buttons that you desire.

Re: Please Add title bar parameter to error() [Re: jcl] #283334
08/07/09 09:04
08/07/09 09:04
Joined: Jul 2008
Posts: 894
T
TechMuc Offline
User
TechMuc  Offline
User
T

Joined: Jul 2008
Posts: 894
simply:

Code:
#define errorT(Message,Title) MessageBox(hWnd,Message,Title,MB_OK|MB_ICONSTOP)

errorT("my Message","my Title");



Re: Please Add title bar parameter to error() [Re: jcl] #283339
08/07/09 09:47
08/07/09 09:47
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
But Ive found that doesnt work terribly reliably if you are in full-screen mode.
(unfortunately, this mis-behaviour is not consistant)


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial
Re: Please Add title bar parameter to error() [Re: EvilSOB] #283348
08/07/09 10:17
08/07/09 10:17
Joined: Jul 2000
Posts: 28,145
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 28,145
Frankfurt
For a MessageBox in fullscreen mode, you need to call the DirectX function SetDialogBoxMode(TRUE) before.

if (fullscreen)
d3dDev->SetDialogBoxMode(TRUE);
else
d3dDev->SetDialogBoxMode(FALSE);

MessageBox(hWnd,Text,Title,MB_OK|MB_ICONSTOP|MB_TASKMODAL|MB_SETFOREGROUND|MB_TOPMOST);



Re: Please Add title bar parameter to error() [Re: jcl] #283598
08/08/09 18:06
08/08/09 18:06
Joined: Sep 2003
Posts: 9,859
F
FBL Offline
Senior Expert
FBL  Offline
Senior Expert
F

Joined: Sep 2003
Posts: 9,859
This calls for a library function smile

Re: Please Add title bar parameter to error() [Re: FBL] #283685
08/09/09 09:28
08/09/09 09:28
Joined: Feb 2008
Posts: 3,232
Australia
EvilSOB Offline
Expert
EvilSOB  Offline
Expert

Joined: Feb 2008
Posts: 3,232
Australia
Hmmm, I'll have to look into this. Thanks again JCL.


"There is no fate but what WE make." - CEO Cyberdyne Systems Corp.
A8.30.5 Commercial

Moderated by  old_bill, Tobias 

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1