Antonio,
Mira esto por favor:
Code: Select all
#Include "FiveWin.ch"
//----------------------------------------------------------------------------//
Function Main()
Local oDlg
local oMemo
local cGet := space(100)
DEFINE DIALOG oDlg NAME "Test" TITLE "Prueba memo"
REDEFINE GET oMemo VAR cGet OF oDlg ID 100 MEMO
REDEFINE BUTTON ID 110 ACTION ( oDlg:end() )
REDEFINE BUTTON ID 120 ACTION ( oDlg:end() )
ACTIVATE DIALOG oDlg CENTERED;
ON INIT ( BuildButton( oMemo ), .T. )
Return nil
function BuildButton( oMemo, oDlg )
local oBtn
@ 0, oMemo:nWidth - 22 BUTTONBMP oBtn PROMPT "..." OF oMemo PIXEL SIZE 20, 20 ACTION MsgInfo( "click" )
oMemo:bChange = { || oBtn:Refresh() }
return nil
archivo .rc
Code: Select all
#ifdef __FLAT__
1 24 "c:\fivetech\WindowsXP.Manifest"
#endif
#define IDC_EDIT1 101
Test DIALOG 41, 64, 409, 199
EXSTYLE WS_EX_DLGMODALFRAME
STYLE DS_MODALFRAME | DS_3DLOOK | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
CAPTION "Testing"
FONT 8, "MS Sans Serif"
{
EDITTEXT 100, 6, 12, 166, 162, ES_AUTOHSCROLL | ES_MULTILINE | WS_BORDER | WS_TABSTOP
CONTROL "OK", 110, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 5, 179, 50, 16
CONTROL "Cancelar", 120, "BUTTON", BS_PUSHBUTTON | WS_CHILD | WS_VISIBLE | WS_TABSTOP, 95, 179, 50, 16
}
Muchas gracias.