Print Page | Close Window

Custom FileBox behavior. preventing edit

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Property Grid
Forum Description: Topics Related to Codejock Property Grid
URL: http://forum.codejock.com/forum_posts.asp?TID=2577
Printed Date: 18 June 2024 at 4:43am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Custom FileBox behavior. preventing edit
Posted By: turbowagon
Subject: Custom FileBox behavior. preventing edit
Date Posted: 14 July 2005 at 5:53pm

Using the PropertyGrid sample program as an example, I would like to create something similar to the CCustomItemFileBox class in CustomItems.h.

However, I would like to prevent the user from editing the edit field, but still allow them to press the [...] file dialog button.

If I set the flags to disallow editing, the little file dialog button disappears.  Also, if I override the OnChar() method, it does not prevent entries in the edit box.

How can I acheive the desired behavior?




Replies:
Posted By: Oleg
Date Posted: 15 July 2005 at 12:32am

Set

m_nFlags = xtpGridItemHasExpandButton; in its constructor



-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: turbowagon
Date Posted: 15 July 2005 at 12:27pm
Thanks!  That worked perfectly.  Don't know how I missed that.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net