Edit con Button

Edit con Button

Postby Xevi » Fri Jan 26, 2018 12:02 pm

Cómo puedo mostrar un botón en un EDIT

Si bien veo que existe el método bLButtonup, que supongo seria el encargado de realizar lo que se le mande, no veo como mostrar ese button

Cogiendo el ejemplo de FW, edit.prg... cómo hago que uno de esos EDITs tenga el botoncillo a al derecha???


Code: Select all  Expand view

// Testing Class TEdit that implements GETs without using a Harbour embedded GET

#include "FiveWin.ch"

//----------------------------------------------------------------------------//

function Main()

   local oDlg, cFirst := "Hello", cLast := "World"

   DEFINE DIALOG oDlg SIZE 500, 250
   
   @ 1, 1 EDIT cFirst OF oDlg SIZE 80, 10
   
   @ 2, 1 EDIT cLast OF oDlg SIZE 80, 10

   @ 5, 11 BUTTON "Ok" ACTION MsgInfo( cFirst + ", " + cLast )

   @ 5, 21 BUTTON "Cancel" ACTION oDlg:End()

   ACTIVATE DIALOG oDlg CENTERED

return nil

//----------------------------------------------------------------------------//
 
Un Saludo,
Xevi.

Aprendiz de la vida!!!
User avatar
Xevi
 
Posts: 169
Joined: Wed Nov 29, 2017 11:42 am
Location: Girona

Re: Edit con Button

Postby Xevi » Fri Jan 26, 2018 12:32 pm

Seria como ...

Code: Select all  Expand view

// Testing Class TEdit that implements GETs without using a Harbour embedded GET

#include "FiveWin.ch"

//----------------------------------------------------------------------------//

function Main()

   local oDlg, cFirst := "Hello", cLast := "World"
Local oBtn

   DEFINE DIALOG oDlg SIZE 500, 250
   
   @ 1, 1 EDIT cFirst OF oDlg SIZE 80, 10
   @ 0.75, 14.8 BUTTON oBtn PROMPT "..." OF oDlg SIZE 8, 8
   
   @ 2, 1 EDIT cLast OF oDlg SIZE 80, 10

   @ 5, 11 BUTTON "Ok" ACTION MsgInfo( cFirst + ", " + cLast )

   @ 5, 21 BUTTON "Cancel" ACTION oDlg:End()

   ACTIVATE DIALOG oDlg CENTERED

return nil

//----------------------------------------------------------------------------//
 


De esta manera "ya me sirve", pero lo suyo es tener el botón "integrado" dentro del EDIT.

Vaya... un EDITBUTTON

Gracias.
Un Saludo,
Xevi.

Aprendiz de la vida!!!
User avatar
Xevi
 
Posts: 169
Joined: Wed Nov 29, 2017 11:42 am
Location: Girona

Re: Edit con Button

Postby karinha » Fri Jan 26, 2018 12:33 pm

debería funcionar asi, pero no funciona com EDIT.

Code: Select all  Expand view

   @ 10,10 EDIT oEdit1 VAR cFirst bitmap "..\bitmaps\on.bmp" action( msginfo( "With Transparent" ) ) ;
           OF oDlg SIZE 80,10

   oEdit1:lBtnTransparent := .T.       // transparent button get oEdit1
   oEdit1:lAdjustBtn      := .T.       // Button Get Adjust Witdh oEdit1
   oEdit1:lDisColors      := .F.       // Deactive disable color
   oEdit1:nClrTextDis     := CLR_WHITE // Color text disable status
   oEdit1:nClrPaneDis     := CLR_BLUE  // Color Pane disable status
 



Saludos
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7154
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: Edit con Button

Postby nageswaragunupudi » Sun Jan 28, 2018 6:10 pm

In this way "and serves me", but his is to have the "integrated" into the EDIT button.

Not provided.
Need to use Get if that feature is required.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10206
Joined: Sun Nov 19, 2006 5:22 am
Location: India


Return to FiveWin para Harbour/xHarbour

Who is online

Users browsing this forum: GUSPRE and 10 guests