Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Property Grid
  New Posts New Posts RSS Feed - Min/Max for Numeric and Double items
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Min/Max for Numeric and Double items

 Post Reply Post Reply
Author
Message
Osiris View Drop Down
Groupie
Groupie
Avatar

Joined: 18 June 2007
Status: Offline
Points: 29
Post Options Post Options   Thanks (0) Thanks(0)   Quote Osiris Quote  Post ReplyReply Direct Link To This Post Topic: Min/Max for Numeric and Double items
    Posted: 23 July 2007 at 11:42am
Hi,

what would the best way to implement the functionality of setting a minimum and maximum value for a numeric or double property grid item? Any input outside the min/max constraints shall not be accepted.
Actually the item shall behave like an item with a slider or a spin button (if the user types in a value outside the slider/spin range, it will be rejected) but I dont want to have such a button.

The solution I'm thinking of is to derive on of the XTPPropertyGridInplaceEdit or the XTPGridItemNumber/Double classes.

Is there another (maybe smarter) way?

Thanks in advance
Stefan
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 24 July 2007 at 2:22am
Hello,
 
You can catch XTP_PGN_ITEMVALUE_CHANGED message and update value, or XTP_PGN_EDIT_CHANGED and change value while user edit it.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.188 seconds.