La spodes hacer redondas
te paso el codigo:
Para probarlo ponelo tal cual te lo di en un prg y ejecutalo para ver el resultado
PUBLIC oForm
oForm = CreateObject("Tform")
oForm.Visible = .T.
DEFINE CLASS Tform As Form
#DEFINE badgeDiameter 528 &&264
#DEFINE topMargin 4
#DEFINE leftMargin 2
Width=550&&300
Height=550 &&350
AutoCenter=.T.
Picture="badge1.bmp"
backcolor=rgb(0,100,0)
hRgn=0
ADD OBJECT lbl As Label WITH Caption="Ingrese su Id:",;
FontName="Arial", FontSize=14, Bold=.T., BackStyle=0, Alignment=2,;
Forecolor=Rgb(255,255,225), Left=70, Top=80, Width=170, Height=25
ADD OBJECT txt1 As TextBox WITH Width=100, Height=24,;
Left=82, Top=105
ADD OBJECT txt2 As TextBox WITH Width=100, Height=24,;
Left=82, Top=140, PasswordChar="*"
ADD OBJECT cmd As CommandButton WITH Width=60, Height=25,;
Left=104, Top=180, Caption="Ok", Default=.T.
Procedure txt1.keypress
lparameters nKeyCode, nShiftAltCtrl
if nkeycode = 13
endif
PROCEDURE Init
DO decl
THISFORM.TXT1.VALUE = 'SERGIO'
THISFORM.TXT2.SETFOCUS()
PROCEDURE Activate
IF THIS.hRgn = 0
THIS.RegionOn
ENDIF
PROCEDURE RegionOn
#DEFINE SM_CYSIZE 31
#DEFINE SM_CXFRAME 32
#DEFINE SM_CYFRAME 33
LOCAL hwnd, x0, y0, x1, y1
* calculating position of the region
x0 = GetSystemMetrics(SM_CXFRAME) + leftMargin
y0 = GetSystemMetrics(SM_CYSIZE) + GetSystemMetrics(SM_CYFRAME) + topMargin
x1 = x0 + badgeDiameter
y1 = y0 + badgeDiameter
* creating an elliptical region
THIS.hRgn = CreateEllipticRgn (x0, y0, x1, y1)
hwnd = GetFocus()
* applying the region to the form
IF SetWindowRgn(hwnd, THIS.hRgn, 1) = 0
* if failed then release the handle
= DeleteObject (THIS.hRgn)
THIS.hRgn = 0
ENDIF
ENDPROC
PROCEDURE MouseDown
LPARAMETERS nButton, nShift, nXCoord, nYCoord
#DEFINE WM_SYSCOMMAND 0x112
#DEFINE WM_LBUTTONUP 0x202
#DEFINE MOUSE_MOVE 0xf012
IF nButton = 1
LOCAL hWindow
hWindow = GetFocus()
= ReleaseCapture()
= SendMessage(hWindow, WM_SYSCOMMAND, MOUSE_MOVE, 0)
= SendMessage(hWindow, WM_LBUTTONUP, 0, 0)
ENDIF
PROCEDURE cmd.Click
ThisForm.Release
ENDDEFINE
PROCEDURE decl
DECLARE INTEGER GetFocus IN user32
DECLARE INTEGER DeleteObject IN gdi32 INTEGER hObject
DECLARE INTEGER GetSystemMetrics IN user32 INTEGER nIndex
DECLARE INTEGER ReleaseCapture IN user32
DECLARE INTEGER SendMessage IN user32 INTEGER hWnd, INTEGER Msg,;
INTEGER wParam, INTEGER lParam
DECLARE INTEGER CreateEllipticRgn IN gdi32 INTEGER nLeftRect, INTEGER;
nTopRect,INTEGER nRightRect, INTEGER nBottomRect
DECLARE INTEGER SetWindowRgn IN user32;
INTEGER hWnd, INTEGER hRgn, INTEGER bRedraw