Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Help with MessageBoxIndirect API
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01070654
Message ID:
01070712
Vues:
22
Carlos,

Most likely it caused by the requirement to lpszText, lpszCaption and lpszIcon members of the MSGBOXPARAMS structure to be pointers to strings.

In your code you insert strings in the structure directly. The other members become virtually displaced, which makes the system unable to recognize them properly.

Use GlobalAlloc or LocalAlloc or any other memory allocation routine and pass the resulting pointer to the structure. Don't forget to release the memory in the end.

* * *
I just made a quick test of this function. It has confirmed lpszText, lpszCaption to be pointers to strings rather than the strings themselves. The first member, cbSize, should be set to 40 bytes, the size of the structure.

Also lpszIcon should be a resource identifier. I don't think it can be an icon filename.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform