sptk



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: icon button?



You can use buttonImage(SP_EXIT_BUTTON);

2006/6/7, HERNAN LAGRAVA <hernanjls@hotmail.com>:


Perfect I even could change the label of the button

m_cancelButton->hide();
m_okButton->label("Cerrar");

now as to change the icon the following thing tries but it seems that that
member does not exist is possible to change it?


m_okButton->kind(SP_EXIT_BUTTON); ???????




>From: "Alexey Parshin" <alexeyp@gmail.com>
>To: "HERNAN LAGRAVA" <hernanjls@hotmail.com>
>Subject: Re: insert record (return value method save)?
>Date: Wed, 7 Jun 2006 15:39:05 +1000
>
>CDialog class has m_okButton and m_cancelButton members.
>In your class, you can simply call:
>
>m_cancelButton->hide();
>
>2006/6/7, HERNAN LAGRAVA <hernanjls@hotmail.com>:
>>
>>it works very well
>>
>>The CDialog class shows the buttons OK and Cancel, now like showing
single
>>the Ok button. it is possible?
>>
>>
>>
>>
>> >From: "Alexey Parshin" <alexeyp@gmail.com>
>> >To: "HERNAN LAGRAVA" <hernanjls@hotmail.com>
>> >Subject: Re: insert record (return value method save)?
>> >Date: Wed, 7 Jun 2006 15:21:34 +1000
>> >
>> >If after save() you want to close the dialog window - then return
true.
>>If
>> >you have an error during save(), then most likely you want to show
this
>> >error with spError() function, and return false - to allow the user to
>> >decide what to do.
>> >
>> >2006/6/7, HERNAN LAGRAVA <hernanjls@hotmail.com>:
>> >>
>> >>
>> >>now the compile process said this message
>> >>
>> >>error C4716: 'CDataInput::save' : must return a value
>> >>
>> >>as value it must return the method?
>> >>
>> >>well, then code is the follow
>> >>
>> >>virtual bool save()
>> >>          {
>> >>
>> >>                  CQuery  IDQuery(database(),"SELECT max(IdPersona)
>>FROM
>> >>tbl_Personas");
>> >>                  CQuery  InsertQuery(database(),"INSERT INTO
>>tbl_Personas
>> >>VALUES (
>> >>:person_id, :person_name, :person_date, :person_depto, :person_cargo
>>)");
>> >>
>> >>                    try {
>> >>                             IDQuery.open();
>> >>                                 InsertQuery.param("person_id") =
>> >>IDQuery[0].asInteger() + 1;
>> >>                                 InsertQuery.param("person_name") =
>> >>nombre->data();
>> >>                                 InsertQuery.param("person_date") =
>> >>fn->data();
>> >>                                 InsertQuery.param("person_depto") =
>> >>depto->data();
>> >>                                 InsertQuery.param("person_cargo") =
>> >>cargo->data();
>> >>
>> >>                                 InsertQuery.exec();
>> >>                         }
>> >>                         catch (CException& e) {
>> >>                                 printf("\nError: %s\n",e.text
>>().c_str());
>> >>                                 puts("\nSorry, NO SE  GUARDO EL
>> >>REGISTRO.");
>> >>                         }
>> >>
>> >>          }
>> >>
>> >>
>> >>
>> >
>> >
>> >--
>> >Alexey Parshin,
>> >http://www.sptk.net
>>
>>
>>
>
>
>--
>Alexey Parshin,
>http://www.sptk.net





--
Alexey Parshin,
http://www.sptk.net

List hosted by Total Knowledge

Authoright © Total Knowledge: 2005