ALLOWEDIT with long Cell

General Help regarding HMG, Compilation, Linking, Samples

Moderator: Rathinagiri

Post Reply
User avatar
AUGE_OHR
Posts: 592
Joined: Sun Aug 25, 2019 3:12 pm
DBs Used: DBF, PostgreSQL, MySQL, SQLite
Location: Hamburg, Germany
Has thanked: 75 times
Been thanked: 129 times

ALLOWEDIT with long Cell

Post by AUGE_OHR » Sat Feb 15, 2020 6:05 am

hi,

when have a large Cell and use ALLOWEDIT it will go "outside" Browse

c:\hmg.3.4.4\SOURCE\h_browse.prg

Code: Select all

FUNCTION _BrowseEdit
   ...
   ElseIf ControlType == 'C'
	CellData := RTRIM ( CellData )
	DEFINE TEXTBOX Control_1
	FONTNAME BFN
	FONTSIZE BFS
	ROW 0
	COL 0
	WIDTH This.CellWidth 
the last Row will do the Effect so i recommend to enhance it

Code: Select all

	WIDTH MIN(This.CellWidth, This.Window.Width) 
as i know width of WC_EDIT is independent from "Buffer" Size so "@S" is "include"

---

other Solution :

Code: Select all

If ControlType == 'M' .or, ( ControlType == 'C' .and. This.CellWidth > This.Window.Width )
"This.Window.Width" is just a dummy. i guess _HMG_SYSDATA have it.
so who can tell me how to get "This.Window.Width" :idea:
have fun
Jimmy

Post Reply