1. ES_NUMERIC
- Posted by rubis at fem.unicamp.br Oct 22, 2002
- 390 views
Hi people; The flag ES_NUMERIC is working or not in win2000 ??? Where can I find a list of flags for each control in the docs ? I didn't find, for example, this flag in the win32lib doc. Thanks Rubens
2. Re: ES_NUMERIC
- Posted by Robert Szalay <robsz1 at netzero.net> Oct 22, 2002
- 390 views
well, to get all the styles (or flags as they are commonly called), I beleive you would need the Platform SDK. They are available for veiwing online or can be downloaded at: download them at: http://www.microsoft.com/msdownload/platformsdk/sdkupdate/ But beware: They are big. i think around well i dont know. The version I have (November 2001) is 380mb. Im not sure how often or how much they are updated. You can view them on the microsoft site at: http://msdn.microsoft.com/default.asp I find them to be a lot easier to look at on my HD. The Microsoft site takes for ever(on a 28.8k dialup connection anyways) Regards, Robert Szalay ----- Original Message ----- From: <rubis at fem.unicamp.br> To: EUforum <EUforum at topica.com> Sent: Tuesday, October 22, 2002 6:20 PM Subject: ES_NUMERIC > > Hi people; > > The flag ES_NUMERIC is working or not in win2000 ??? > > Where can I find a list of flags for each control in the docs ? > I didn't find, for example, this flag in the win32lib doc. > > > Thanks > > Rubens > > > >
3. Re: ES_NUMERIC
- Posted by petelomax at blueyonder.co.uk Oct 23, 2002
- 374 views
On Wed, 23 Oct 2002 15:07:21 +1000, Derek Parnell <ddparnell at bigpond.com> wrote: >Ooops. A bug in the example code. > >> constant vFldSize =3D { -1, fld1, fld3, fld5} > >should be=20 > constant vFldSize =3D { fld1, fld3, fld5} > So, in: constant vMaxSize =3D {9999, 4, 5, 19} if length(getText(self)) >=3D vMaxSize[find(self, vFldSize)+1]=20 can I assume the 9999 & the +1 are unnecessary (but cause no harm)? BTW nice timing. I was just about to go searching the archives to find out how this is done. Pete
4. Re: ES_NUMERIC
- Posted by Derek Parnell <ddparnell at bigpond.com> Oct 23, 2002
- 388 views
23/10/2002 5:19:13 PM, petelomax at blueyonder.co.uk wrote: >> >So, in: > constant vMaxSize = {9999, 4, 5, 19} > if length(getText(self)) >= vMaxSize[find(self, vFldSize)+1] > >can I assume the 9999 & the +1 are unnecessary (but cause no harm)? > Well "unnecessary" isn't the right word really. What it does show is my laziness (a.k.a. terse coding style). I need vMaxSize to have one more element than the number of fields to check. This is because I use the find() function to locate the fld id to check. If the field being checked isn't in the list of 'sized' fields, then find() will return a zero. So all I do is add one to whatever find() returns and use that as an index into the vMaxSize list. The first (zero'th item) is always ignored unless I try to check a field that isn't supposed to be checked - in which case the maxsize is a huge number (9999). The other way to code it would be... integer tempval tempval = find(self, vFldSize) if tempval > 0 then if length(getText(self)) >= vMaxSize[tempval] then returnValue(-1) end if end if My method saves a temporary variable and only uses one line of code. It is however ever so slightly slower when an incorrect field is being checked - but that shouldn't happen , right? . --------- Cheers, Derek Parnell
5. Re: ES_NUMERIC
- Posted by petelomax at blueyonder.co.uk Oct 23, 2002
- 403 views
On Wed, 23 Oct 2002 18:28:34 +1000, Derek Parnell <ddparnell at bigpond.com> wrote: >check a field that isn't supposed to be checked -=20 >in which case the maxsize is a huge number (9999).=20 Oooh, sneaky. You clever boy you! Glad I asked! Cheers, Pete