{"id":5333,"date":"2013-02-06T07:00:00","date_gmt":"2013-02-06T07:00:00","guid":{"rendered":"https:\/\/blogs.msdn.microsoft.com\/oldnewthing\/2013\/02\/06\/the-curious-pattern-of-pre-emptively-rejecting-the-solution-to-your-problem\/"},"modified":"2013-02-06T07:00:00","modified_gmt":"2013-02-06T07:00:00","slug":"the-curious-pattern-of-pre-emptively-rejecting-the-solution-to-your-problem","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/oldnewthing\/20130206-00\/?p=5333","title":{"rendered":"The curious pattern of pre-emptively rejecting the solution to your problem"},"content":{"rendered":"<p><P>\nA frustrating pattern that shows up occasionally in customer\nquestions is the case where the customer poses a problem,\nand pre-emptively rejects the mechanism explicitly designed\nto solve that problem.\n<\/P>\n<BLOCKQUOTE CLASS=\"q\">\nHow can we change the widget color without using\n<CODE>IWidget::Set&shy;Color<\/CODE>?\n<\/BLOCKQUOTE>\n<P>\nUm, the whole point of\n<CODE>IWidget::Set&shy;Color<\/CODE>\nis to change the color of a widget.\nWhy are you rejecting the mechanism whose sole purpose\nin life is to solve the very problem you are having?\n<\/P>\n<P>\nUsually, if you press hard enough, they will cough up the\nreason why they think they cannot use the solution specifically\ndesigned to do what they want.\nVarious excuses tend to come up over and over.\n<\/P>\n<P>\nOne excuse is the belief that the proposed solution\ndoes not work in a particular scenario.\n&#8220;We cannot use ACLs because they don&#8217;t work on network volumes.&#8221;\nUm, yes they do.\nCheck it out.\n<\/P>\n<P>\nOr that the proposed solution doesn&#8217;t fit their choice\nof technology.\n&#8220;We are programming in a language that does not support\nCOM objects.\nWe can only p\/invoke to C-style APIs.&#8221;\nWell, you can work around that problem by writing a helper\nDLL that exposes a C-style API, and implements it by\ncalling the COM method.\n<\/P>\n<P>\nOr that the proposed solution violates some vague corporate\npolicy.\n&#8220;We have a corporate policy that users cannot change widget colors,\nso the\n<CODE>IWidget::Set&shy;Color<\/CODE> method returns\n<CODE>E_ACCESS&shy;DENIED<\/CODE>.\nWe&#8217;re looking for a way around that policy.&#8221;\nOkay, well, now that&#8217;s something you need to take up with the\npeople who establish your corporate policies.\nDon&#8217;t come to us looking for ways to circumvent corporate policy.\n<\/P>\n<P>\nOne time, the reason came from our\nown technical support staff:\n&#8220;We cannot write a C++ program that calls\n<CODE>IWidget::Set&shy;Color<\/CODE>\nand provide it to the customer\nbecause we are not a developer support team.\nWe are not allowed to send compiled binaries to the customer\nfor liability reasons,\nand we generally do not send\nsource code because our customers\ntypically do not have the expertise or desire to install\nVisual Studio and\nthe Platform SDK just to compile and run a five-line C++ program.\n(Did I mention that we are not a developer support team?)\nCan it be done from a batch file?&#8221;\n<\/P>\n<P>\nYeah, how about this batch file:\n<\/P>\n<PRE>\n &gt;changeColor.cs echo using System;\n&gt;&gt;changeColor.cs echo class Program {\n&gt;&gt;changeColor.cs echo public static void Main(string[] args) {\n&gt;&gt;changeColor.cs echo &#8230;\n&gt;&gt;changeColor.cs echo }\n&gt;&gt;changeColor.cs echo }\n%windir%\\Microsoft.NET\\Framework\\v4.0.30319\\csc changeColor.cs\nchangeColor blue\n<\/PRE>\n<P>\nOnly half-joking.\n<\/P>\n<P>\nThe non-joking answer is\n&#8220;The customer can take this information to a developer support team,\nor at least somebody who will write the program for them,\nif they don&#8217;t know how to write a program themselves.&#8221;\nMicrosoft Consulting Services exists for this, but that is\nlikely overkill for a five-line program.\n<\/P><\/p>\n","protected":false},"excerpt":{"rendered":"<p>A frustrating pattern that shows up occasionally in customer questions is the case where the customer poses a problem, and pre-emptively rejects the mechanism explicitly designed to solve that problem. How can we change the widget color without using IWidget::Set&shy;Color? Um, the whole point of IWidget::Set&shy;Color is to change the color of a widget. Why [&hellip;]<\/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":[26],"class_list":["post-5333","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-oldnewthing","tag-other"],"acf":[],"blog_post_summary":"<p>A frustrating pattern that shows up occasionally in customer questions is the case where the customer poses a problem, and pre-emptively rejects the mechanism explicitly designed to solve that problem. How can we change the widget color without using IWidget::Set&shy;Color? Um, the whole point of IWidget::Set&shy;Color is to change the color of a widget. Why [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/5333","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=5333"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/posts\/5333\/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=5333"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/categories?post=5333"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/oldnewthing\/wp-json\/wp\/v2\/tags?post=5333"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}