{"id":101060,"date":"2019-02-20T07:00:00","date_gmt":"2019-02-20T22:00:00","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/oldnewthing\/?p=101060"},"modified":"2019-03-12T23:57:28","modified_gmt":"2019-03-13T06:57:28","slug":"20190220-00","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/oldnewthing\/20190220-00\/?p=101060","title":{"rendered":"The early history of the <CODE>ES_NUMBER<\/CODE> edit control style"},"content":{"rendered":"<p>The <code>ES_<\/code><code>NUMBER<\/code> edit control style was added in Windows 95. If the style is set, then the edit control limits typed input to digits. It doesn&#8217;t do very much, but what it does is kind of handy. As noted in the documentation, this doesn&#8217;t prevent the user from putting non-digits into the edit control by other means, like pasting with <kbd>Ctrl<\/kbd>+<kbd>V<\/kbd>. <\/p>\n<p>It took a while, but eventually a problem with the <code>ES_<\/code><code>NUMBER<\/code> style was discovered: Earlier versions of Windows didn&#8217;t use this style bit, and there was an application that decided, &#8220;Hey, look, free bit!&#8221; <\/p>\n<p>I don&#8217;t know what it used the bit for. Maybe it set it by mistake. But whether they set the bit on purpose or by mistake, what ended up happening was that the edit controls in this application accepted only digits! <\/p>\n<p>So another application compatibility tweak was made: The <code>ES_<\/code><code>NUMBER<\/code> style is honored only if the application&#8217;s expected Windows version is 4.0 (Windows 95) or higher. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>It&#8217;s just a little style bit.<\/p>\n","protected":false},"author":1069,"featured_media":111744,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[2],"class_list":["post-101060","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-oldnewthing","tag-history"],"acf":[],"blog_post_summary":"<p>It&#8217;s just a little style bit.<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/101060","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/users\/1069"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/comments?post=101060"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/101060\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media\/111744"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/media?parent=101060"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/categories?post=101060"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/tags?post=101060"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}