Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* ej38_FormIcon
- Ejemplo para cambiar el icono asociado a la forma */
- #include <radc++.h>
- Form Form1("Cambiar/Poner el Icono de la Forma - RAD C++ Ejemplo");
- Button button1("Click a mi para cambiar el icono de la forma", AUTO_ID, 50, 10, 300, 35, Form1);
- //create some icon objects
- //NOTE: IDI_HAND and IDI_EXCLAMATION are predefined by system
- Icon icon1(IDI_EXCLAMATION);
- Icon icon2(IDI_HAND);
- FormProcedure procedure1 (FormProcArgs) {
- ON_CLOSE() Application.close();
- ON_COMMAND_BY(button1) {
- //set new icon to form's title bar
- Form1.icon = icon2;
- }
- return 0;
- }
- rad_main()
- Form1.procedure = procedure1;
- //set default icon to form's title bar
- Form1.icon = icon1;
- //center the button on form
- button1.center();
- rad_end()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement