#i cant get a icon to show in a massage box

5 messages · Page 1 of 1 (latest)

magic cloakBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question run !howto ask.

fresh dome
#

You can't pass such custom icon as 4th argument to MessageBox(). Only a combination of predefined values listed here: https://learn.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-messagebox.
For that, you'll need MessageBoxIndirect(). You can find an example here: https://voidnish.wordpress.com/2005/01/11/using-messageboxindirect-to-show-message-boxes-with-custom-icons/.
Notes:

  • The cast to LPCWSTR is useless.
  • The leading / in "/test.ico" will search at the root of your computer: C:/test.ico. Perhaps you wanted a relative path: ./.
magic cloakBOT
#

@tidal estuary Has your question been resolved? If so, run !solved :)

magic cloakBOT
#

This question is being automatically marked as stale.
If your question has been answered, run !solved.
If your question is not answered feel free to bump the post or re-ask.
Take a look at !howto ask for tips on improving your question.

tender coral
#

i can try to help but im too lazy to reread all of this, can you just send me in one sentence what u want to happen