{"id":6086,"date":"2014-04-12T16:20:46","date_gmt":"2014-04-12T16:20:46","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2014\/04\/12\/how-to-make-transparent-background-of-silverlight-3-application-collection-of-common-programming-errors\/"},"modified":"2014-04-12T16:20:46","modified_gmt":"2014-04-12T16:20:46","slug":"how-to-make-transparent-background-of-silverlight-3-application-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2014\/04\/12\/how-to-make-transparent-background-of-silverlight-3-application-collection-of-common-programming-errors\/","title":{"rendered":"How to make transparent background of Silverlight 3 application?-Collection of common programming errors"},"content":{"rendered":"<p>How to make transparent background of Silverlight 3 application? I have the next code but it does not work (<\/p>\n<pre><code>          \n          \n          \nBGtest\n\nhtml, body {\n    height: 100%;\n    overflow: auto;\n}\nbody {\n\n    padding: 0;\n    margin: 0;\n}\n#silverlightControlHost {\n    height: 100%;\n    text-align:center;\n}\n\n\n\n    function onSilverlightError(sender, args) {\n        var appSource = \"\";\n        if (sender != null &amp;&amp; sender != 0) {\n          appSource = sender.getHost().Source;\n        }\n\n        var errorType = args.ErrorType;\n        var iErrorCode = args.ErrorCode;\n\n        if (errorType == \"ImageError\" || errorType == \"MediaError\") {\n          return;\n        }\n\n        var errMsg = \"Unhandled Error in Silverlight Application \" +  appSource + \"\\n\" ;\n\n        errMsg += \"Code: \"+ iErrorCode + \"    \\n\";\n        errMsg += \"Category: \" + errorType + \"       \\n\";\n        errMsg += \"Message: \" + args.ErrorMessage + \"     \\n\";\n\n        if (errorType == \"ParserError\") {\n            errMsg += \"File: \" + args.xamlFile + \"     \\n\";\n            errMsg += \"Line: \" + args.lineNumber + \"     \\n\";\n            errMsg += \"Position: \" + args.charPosition + \"     \\n\";\n        }\n        else if (errorType == \"RuntimeError\") {           \n            if (args.lineNumber != 0) {\n                errMsg += \"Line: \" + args.lineNumber + \"     \\n\";\n                errMsg += \"Position: \" +  args.charPosition + \"     \\n\";\n            }\n            errMsg += \"MethodName: \" + args.methodName + \"     \\n\";\n        }\n\n        throw new Error(errMsg);\n    }\n\n       \n          \n\n\n    \n          \n          \n                      \n                \n                       \n          \n          \n          \n                  <img decoding=\"async\" src=\"http:\/\/go.microsoft.com\/fwlink\/?LinkId=108181\" alt=\"Get Microsoft Silverlight\" style=\"border-style:none\" \/>\n          \n    \n\n                    \n                  \n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>How to make transparent background of Silverlight 3 application? I have the next code but it does not work ( BGtest html, body { height: 100%; overflow: auto; } body { padding: 0; margin: 0; } #silverlightControlHost { height: 100%; text-align:center; } function onSilverlightError(sender, args) { var appSource = &#8220;&#8221;; if (sender != null &amp;&amp; [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-6086","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/6086","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=6086"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/6086\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=6086"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=6086"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=6086"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}