<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Garrett Serack: Open Source Development at Microsoft : scripting</title><link>http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx</link><description>Tags: scripting</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Using JScript as a batch scripting language (Part III)</title><link>http://blogs.msdn.com/garretts/archive/2009/05/18/using-jscript-as-a-batch-scripting-language-part-iii.aspx</link><pubDate>Mon, 18 May 2009 23:15:01 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9625922</guid><dc:creator>GarrettS</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/garretts/comments/9625922.aspx</comments><wfw:commentRss>http://blogs.msdn.com/garretts/commentrss.aspx?PostID=9625922</wfw:commentRss><description>&lt;p&gt;Now that I’ve shown how to build a cool .Format() method for strings, we can put it to good use in a lot of places.&lt;/p&gt;  &lt;p&gt;In batch scripting, it’s really nice to be able to make nearly every call support replacement arguments in a consistent fashion. In cmd.exe batch scripts, we use %var% all over the place. In JScript batch scripting, we simply use {$VAR} instead, and put a little bit of code in the top of our functions to help out with that.&lt;/p&gt;  &lt;p&gt;First, the one-stop-universal-arguments helper, which we can add to the source from before:&lt;/p&gt;  &lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;     &lt;tr&gt;       &lt;td class="gsCodeTitle"&gt;Scripting.js &lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;         &lt;pre class="brush: js;"&gt;function ArgsToArray(x) { return Array.prototype.slice.call(x);} 

// FormatArguments must be passed either:
//     one argument: 
//          containing the arguments object from the caller
//          where the first argument of that should be the format string.
//          == or ==
//          just the format string.
//
//     two arguments:
//          the first argument is the format string
//          the second argument is the argument collection from the caller.
function FormatArguments(args, moreargs) {
    var result = &amp;quot;&amp;quot;;

    if (arguments.length == 1) {
        if (typeof (args) == &amp;quot;object&amp;quot;) {
            args = ArgsToArray(args);
            result = &amp;quot;&amp;quot; + (args.shift());

            if (args.length == 1 &amp;amp;&amp;amp; arguments[0].length &amp;gt; 0)
                args = arguments[0];

            return result.Format(args);
        } else return (&amp;quot;&amp;quot; + args).Format();
    } else if (arguments.length == 2) {
        if (typeof (args) == &amp;quot;string&amp;quot; &amp;amp;&amp;amp; typeof (moreargs) == &amp;quot;object&amp;quot;) {
            result = args;
            args = ArgsToArray(moreargs);
            args.shift();

            return result.Format(args);
        }
    }
    throw &amp;quot;Invalid Argument passed to FormatArguments&amp;quot;;
}&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;br /&gt;

&lt;p&gt;&lt;strong&gt;FormatArguments()&lt;/strong&gt;&amp;#160; gives us the ability to do variable substitution in any function, in a very flexible way. You can simply use the function to give you a completed string:&lt;/p&gt;

&lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;
    &lt;tr&gt;
      &lt;td class="gsCodeTitle"&gt;Test-4.js&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr&gt;
      &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;
        &lt;pre class="brush: js;"&gt;// use the first string as the format string, 
// the rest are potential value substitutions
function Test1() {
    var foo = FormatArguments(arguments)
    WScript.echo( foo );
}

Test1(&amp;quot;the path is {$PATH}&amp;quot;);

// both arguments are used as format strings. any 
// parameter substitution should use numbers starting
// at {1}, since the 'destfile' parameter is techincally {0}
function Test2(srcfile, destfile) {
    var srcfile = FormatArguments(srcfile, arguments);
    var destfile = FormatArguments(destfile, arguments);
    var msg = &amp;quot;Copy {0} to {1}&amp;quot;.Format(srcfile, destfile);
    WScript.echo(msg);
}

Test2(&amp;quot;{$WINDIR}\\system32\\notepad.exe&amp;quot; , &amp;quot;{$USERPROFILE}\\desktop\\notepad.exe&amp;quot;);&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;Knowing that, we can create a few functions that will use the FormatArguments function:&lt;/p&gt;

&lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;
    &lt;tr&gt;
      &lt;td class="gsCodeTitle"&gt;Scripting.js&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr&gt;
      &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;
        &lt;pre class="brush: js;"&gt;// Some global objects we'll need 
var WSHShell = WScript.CreateObject(&amp;quot;WScript.Shell&amp;quot;);
var WinShell = WScript.CreateObject(&amp;quot;Shell.Application&amp;quot;);
var procEnvironment=WSHShell.Environment(&amp;quot;PROCESS&amp;quot;)
var fso = new ActiveXObject(&amp;quot;Scripting.FileSystemObject&amp;quot;);

function Print() {
    WScript.echo(FormatArguments(arguments));
}

function cd() {
    WSHShell.CurrentDirectory = FormatArguments(arguments);
}

function pwd() {
    return WSHShell.CurrentDirectory;
}

function erase(file) {
    file = FormatArguments(arguments);
    if (exists(file))
        fso.DeleteFile(file);
}

function rmdir(folder) {
    folder = FormatArguments(arguments);
    if (folderExists(folder))
        fso.DeleteFolder(folder, true);
}

function exists(file) {
    return fso.FileExists(FormatArguments(arguments));
}

function folderExists(folder) {
    return fso.FolderExists(FormatArguments(arguments));
}

function mkdir(folder) {
    folder = FormatArguments(arguments);
    if (!folderExists(folder))
        fso.CreateFolder(folder);
}&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;Now, we can do some pretty nifty little batch scripting:&lt;/p&gt;

&lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;
    &lt;tr&gt;
      &lt;td class="gsCodeTitle"&gt;test-5.js&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr&gt;
      &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;
        &lt;pre class="brush: js;"&gt;// Bootstrap Scripting Library
eval(new ActiveXObject(&amp;quot;Scripting.FileSystemObject&amp;quot;).OpenTextFile(&amp;quot;Scripting.js&amp;quot;, 1, false).ReadAll());

$ORIG_DIR = pwd();

if( exists(&amp;quot;{$WINDIR}\\log.txt&amp;quot;) ) {
    Print(&amp;quot;Deleting log file&amp;quot;);
    erase(&amp;quot;{$WINDIR}\\log.txt&amp;quot;);
}

mkdir(&amp;quot;{$TEMP}\\tempdir&amp;quot;);&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;Next time, we’ll see how we can call on command-line tools to do our bidding, and play with the results.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9625922" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx">scripting</category><category domain="http://blogs.msdn.com/garretts/archive/tags/JScript/default.aspx">JScript</category></item><item><title>Using JScript as a batch scripting language (Part II)</title><link>http://blogs.msdn.com/garretts/archive/2009/05/15/using-jscript-as-a-batch-scripting-language-part-ii.aspx</link><pubDate>Sat, 16 May 2009 02:17:56 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9620215</guid><dc:creator>GarrettS</dc:creator><slash:comments>2</slash:comments><comments>http://blogs.msdn.com/garretts/comments/9620215.aspx</comments><wfw:commentRss>http://blogs.msdn.com/garretts/commentrss.aspx?PostID=9620215</wfw:commentRss><description>&lt;p&gt;Last time, I wrote about synthesizing an &lt;strong&gt;&lt;em&gt;#include &lt;/em&gt;&lt;/strong&gt;facility along with handling environment variables in a trivial way.&lt;/p&gt;  &lt;p&gt;This time, let’s look at filling in a couple more gaps in JScript’s basic scripting functionality. &lt;/p&gt;  &lt;h4&gt;&lt;u&gt;What’s wrong with String?&lt;/u&gt;&lt;/h4&gt;  &lt;p&gt;The String class in JavaScript/JScript is … ok. If you work in .NET enough, you’ll eventually get to the point where you’d like a couple of functions that seem to be missing. First, is &lt;strong&gt;Trim&lt;/strong&gt;, which I’ve always thought as obvious:&lt;/p&gt;  &lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;     &lt;tr&gt;       &lt;td class="gsCodeTitle"&gt;Scripting.js – String Prototypes&lt;/td&gt;     &lt;/tr&gt;      &lt;tr&gt;       &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;         &lt;pre class="brush: js;"&gt;//----------------------------------------------------------------------------&lt;br /&gt;// String Prototypes&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;String.prototype.Trim = function() {
    return (this || &amp;quot;&amp;quot;).replace(/^\s+|\s+$/g, &amp;quot;&amp;quot;);
}&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;And secondly, is something I miss dearly from when I’m in .NET, is a string &lt;strong&gt;Format &lt;/strong&gt;function. Now, I’ve seen a couple of these that were pretty simple, but I wanted to be able to do some really cool Format strings (and, since the rest of my scripting will rely on them quite a bit, I’m going for the gold here.&lt;/p&gt;

&lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;
    &lt;tr&gt;
      &lt;td class="gsCodeTitle"&gt;Scripting.js – String Prototypes&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr&gt;
      &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;
        &lt;pre class="brush: js;"&gt;String.prototype.Format = function() {
    var args = (arguments.length == 1 &amp;amp;&amp;amp; typeof (arguments[0]) == &amp;quot;object&amp;quot;) ? arguments[0] : arguments;

    result = this;
    while (z = /{(.*?)}/.exec(result))
        try { result = result.replace(z[0], isNaN(z[1]) ? eval(z[1]) : (args[z[1]]||&amp;quot;??&amp;lt;&amp;quot; + z[1] + &amp;quot;&amp;gt;??&amp;quot; )); }
    catch (x) { result = result.replace(z[0], &amp;quot;??&amp;lt;&amp;quot; + z[1] + &amp;quot;&amp;gt;??&amp;quot;); }
    return result.replace(&amp;quot;??&amp;lt;&amp;quot;, &amp;quot;{&amp;quot;).replace(&amp;quot;&amp;gt;??&amp;quot;, &amp;quot;}&amp;quot;);
}&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;So, with this tasty little script in my pocket, I can do ad-hoc format strings that use one of a few types of replacement:&lt;/p&gt;

&lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;
    &lt;tr&gt;
      &lt;td class="gsCodeTitle"&gt;test-3.js&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr&gt;
      &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;
        &lt;pre class="brush: js;"&gt;// simple parameter # replacement like .NET
var foo = &amp;quot;My Name is {0}. Please to meet you {1}&amp;quot;.Format(&amp;quot;Garrett&amp;quot;, &amp;quot;Mr. Serack&amp;quot;);
WScript.echo(foo);

// *global* variable replacement
ABC = &amp;quot;this is a test&amp;quot;;
var bar = &amp;quot;'{ABC}' is really a replacement string&amp;quot;.Format();
WScript.echo(bar);

// really, any legal expression in there is fine.
bar = &amp;quot;'{100+200/75}' is really a replacement value?&amp;quot;.Format();
WScript.echo(bar);

// and if it doesn't match, just leave it alone...
bar = &amp;quot;'{teehee}' isn't really a replacement value.&amp;quot;.Format();
WScript.echo(bar);

// even if it's just a number.
bar = &amp;quot;'{1}' isn't really an index.&amp;quot;.Format();
WScript.echo(bar);&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;Which spits out the following:&lt;/p&gt;

&lt;table border="0" cellspacing="0" cellpadding="2" width="100%"&gt;&lt;tbody&gt;
    &lt;tr&gt;
      &lt;td class="gsCodeTitle"&gt;Ouptut&lt;/td&gt;
    &lt;/tr&gt;

    &lt;tr&gt;
      &lt;td style="border-bottom: #060 1px solid; border-left: #060 1px solid; border-top: #060 1px solid; border-right: #060 1px solid" valign="top" width="100%"&gt;
        &lt;pre class="brush: js;"&gt;My Name is Garrett. Please to meet you Mr. Serack
'this is a test' is really a replacement string
'102.66666666666667' is really a replacement value?
'{teehee}' isn't really a replacement value.
'{1}' isn't really an index.&lt;/pre&gt;
      &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;Basically, it just looks for anything in braces, and checks to see if it’s a number. if it is, it tries to substitute in the n’th parameter passed in. Otherwise it just does an &lt;strong&gt;eval() &lt;/strong&gt;on it—which, will replace expressions, or global variables. If something goes haywire, it just leaves it alone (well, it does some switcheroo stuff to get past the while loop, but it puts it back in the end). &lt;/p&gt;

&lt;p&gt;Next time, we’ll see how to use this… &lt;em&gt;everywhere&lt;/em&gt;.&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9620215" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx">scripting</category><category domain="http://blogs.msdn.com/garretts/archive/tags/JScript/default.aspx">JScript</category></item><item><title>VBScript: Betcha never thought of this one</title><link>http://blogs.msdn.com/garretts/archive/2008/01/16/vbscript-betcha-never-thought-of-this-one.aspx</link><pubDate>Thu, 17 Jan 2008 00:17:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7134805</guid><dc:creator>GarrettS</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/garretts/comments/7134805.aspx</comments><wfw:commentRss>http://blogs.msdn.com/garretts/commentrss.aspx?PostID=7134805</wfw:commentRss><description>&lt;P&gt;I mentioned in a previous post that I had to solve a little issue with the wonderful &lt;A href="http://www.citizeninsomniac.com/WMV/#WMCmd" mce_href="http://www.citizeninsomniac.com/WMV/#WMCmd"&gt;WMCMD.VBS&lt;/A&gt; script that Alex Zambelli maintains.&amp;nbsp; Because of some occasional nastyness, when the script is done--successful or not-- it tries to kill it's own process, in case any of the WM Encoder objects gets hung up.&lt;/P&gt;
&lt;P&gt;The original script uses WMI to look on the machine for the cscript process for the currently running script:&lt;/P&gt;
&lt;TABLE class="" style="FONT-SIZE: 10pt; COLOR: #000000; FONT-FAMILY: 'Consolas'" cellSpacing=0 cellPadding=2 width="100%" bgColor=#ffffff border=1&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class="" vAlign=top width="100%"&gt;&lt;FONT color=#000000 size=2&gt;&lt;SPAN style="COLOR: #00007f"&gt;function&lt;/SPAN&gt; TerminateEncoderProcess&lt;SPAN style="COLOR: #000000"&gt;()&lt;/SPAN&gt; &lt;BR&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;dim&lt;/SPAN&gt; objWMIService &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;dim&lt;/SPAN&gt; objProcess &lt;BR&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;On&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;Error&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;Resume&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;Next&lt;/SPAN&gt; &lt;BR&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="FONT-SIZE: 9pt; COLOR: #007f00; FONT-FAMILY: 'Consolas'"&gt;' Get Windows Manager object&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;Set&lt;/SPAN&gt; objWMIService &lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt; GetObject&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f"&gt;"winmgmts:"&lt;/SPAN&gt; _ &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #000000"&gt;&amp;amp;&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;"{impersonationLevel=impersonate}!\\.\root\cimv2"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;)&lt;/SPAN&gt; &lt;BR&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="FONT-SIZE: 9pt; COLOR: #007f00; FONT-FAMILY: 'Consolas'"&gt;' Enumerate all CScript.exe processes&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;dim&lt;/SPAN&gt; colProcessList &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;Set&lt;/SPAN&gt; colProcessList &lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt; objWMIService.ExecQuery &lt;FONT color=#000000 size=2&gt;_&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/FONT&gt;&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f"&gt;"Select * from Win32_Process Where Name =" _&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;FONT color=#000000 size=2&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;amp;&lt;/SPAN&gt;&lt;/FONT&gt; "'cscript.exe'"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;)&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;dim&lt;/SPAN&gt; strArguments &lt;BR&gt;&amp;nbsp;&amp;nbsp; strArguments &lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;""&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="FONT-SIZE: 9pt; COLOR: #007f00; FONT-FAMILY: 'Consolas'"&gt;' Enumerate all command-line arguments&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;for&lt;/SPAN&gt; i &lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt; &lt;SPAN style="COLOR: #007f7f"&gt;0&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;to&lt;/SPAN&gt; wscript.arguments.Length&lt;SPAN style="COLOR: #000000"&gt;-&lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f"&gt;1&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; strArguments &lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt; strArguments &lt;SPAN style="COLOR: #000000"&gt;&amp;amp;&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;" "&lt;/SPAN&gt; &lt;SPAN style="COLOR: #000000"&gt;&amp;amp; _ &lt;BR&gt;&lt;/SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; wscript.arguments&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;i&lt;SPAN style="COLOR: #000000"&gt;)&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;next&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; strArguments &lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt; Replace&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;strArguments&lt;SPAN style="COLOR: #000000"&gt;,&lt;/SPAN&gt; Chr&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f"&gt;34&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;),&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;""&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;)&lt;/SPAN&gt; &lt;BR&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="FONT-SIZE: 9pt; COLOR: #007f00; FONT-FAMILY: 'Consolas'"&gt;' Kill the processes that match this one in name and arguments&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;For&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;Each&lt;/SPAN&gt; objProcess &lt;SPAN style="COLOR: #00007f"&gt;in&lt;/SPAN&gt; colProcessList &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;if&lt;/SPAN&gt; InStr&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f"&gt;1&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;,&lt;/SPAN&gt; Replace&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;objProcess.CommandLine&lt;SPAN style="COLOR: #000000"&gt;,&lt;/SPAN&gt; _ &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Chr&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f"&gt;34&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;),&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;""&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;),&lt;/SPAN&gt; &lt;FONT color=#000000 size=2&gt;_ &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/FONT&gt;Trim&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;WScript.ScriptName &lt;SPAN style="COLOR: #000000"&gt;&amp;amp;&lt;/SPAN&gt; strArguments&lt;SPAN style="COLOR: #000000"&gt;),&lt;/SPAN&gt; &lt;SPAN style="COLOR: #007f7f"&gt;1&lt;/SPAN&gt; &lt;SPAN style="COLOR: #000000"&gt;)&lt;/SPAN&gt; &lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN style="COLOR: #007f7f"&gt;0&lt;/SPAN&gt; _ &lt;BR&gt;&lt;SPAN style="COLOR: #00007f"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; then&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; objProcess.Terminate&lt;SPAN style="COLOR: #000000"&gt;()&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;end&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;if&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;Next&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="FONT-SIZE: 9pt; COLOR: #007f00; FONT-FAMILY: 'Consolas'"&gt;' What? Still not terminated? OK, kill first occurrence.&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;For&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;Each&lt;/SPAN&gt; objProcess &lt;SPAN style="COLOR: #00007f"&gt;in&lt;/SPAN&gt; colProcessList &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;if&lt;/SPAN&gt; InStr&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f"&gt;1&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;,&lt;/SPAN&gt; objProcess.CommandLine&lt;SPAN style="COLOR: #000000"&gt;,&lt;/SPAN&gt; _ &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; WScript.ScriptName&lt;SPAN style="COLOR: #000000"&gt;)&lt;/SPAN&gt; &lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN style="COLOR: #007f7f"&gt;0&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;then&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; objProcess.Terminate&lt;SPAN style="COLOR: #000000"&gt;()&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;end&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;if&lt;/SPAN&gt; &lt;BR&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #00007f"&gt;Next&lt;/SPAN&gt; &lt;BR&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #00007f"&gt;end&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;function&lt;/SPAN&gt; &lt;BR&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P&gt;Unfortunatly, this script, when all else fails, tries to kill itself by finding the first running cscript, and killing it. Hmmm. not too good, I had multiple encoder script processes going on, and it kept killing the wrong one.&lt;/P&gt;
&lt;P&gt;A pity it seems so hard to find the current process in VBScript... until I thought about it a bit more:&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;TABLE class="" style="FONT-SIZE: 10pt; COLOR: #000000; FONT-FAMILY: 'Consolas'" cellSpacing=0 cellPadding=2 width="100%" bgColor=#ffffff border=1&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class="" vAlign=top width="100%"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: #000000; FONT-FAMILY: 'Consolas'"&gt;&lt;SPAN style="COLOR: #00007f"&gt;function&lt;/SPAN&gt; TerminateEncoderProcess&lt;SPAN style="COLOR: #000000"&gt;()&lt;/SPAN&gt; &lt;BR&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp; GetObject&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f"&gt;"winmgmts:root\cimv2:Win32_Process.Handle='"&lt;/SPAN&gt; _&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: #000000"&gt;&amp;amp;&lt;/SPAN&gt; GetObject&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f"&gt;"winmgmts:root\cimv2:Win32_Process.Handle='"&lt;/SPAN&gt; _ &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;amp; CreateObject&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;"WScript.Shell"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;).&lt;/SPAN&gt;Exec&lt;SPAN style="COLOR: #000000"&gt;(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f"&gt;"cmd.exe"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;).&lt;/SPAN&gt;ProcessId _&amp;nbsp; &lt;BR&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;amp;&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;"'"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;).&lt;/SPAN&gt;ParentProcessId &lt;SPAN style="COLOR: #000000"&gt;&amp;amp;&lt;/SPAN&gt; &lt;SPAN style="COLOR: #7f007f"&gt;"'"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;).&lt;/SPAN&gt;Terminate &lt;BR&gt;&lt;BR&gt;&lt;SPAN style="COLOR: #00007f"&gt;end&lt;/SPAN&gt; &lt;SPAN style="COLOR: #00007f"&gt;function&lt;/SPAN&gt; &lt;BR&gt;&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P&gt;&lt;STRONG&gt;Huh?&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;This version of the script spawns off a new &lt;FONT face=Consolas&gt;cmd.exe&lt;/FONT&gt; process (which exits nearly instantly), but uses the process ID from that, looks up the process, and get it's parent process, and then terminate that.&amp;nbsp; Nice thing is, it don't get confused :D&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=7134805" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx">scripting</category><category domain="http://blogs.msdn.com/garretts/archive/tags/fear+the+cowboy/default.aspx">fear the cowboy</category><category domain="http://blogs.msdn.com/garretts/archive/tags/hacking/default.aspx">hacking</category></item><item><title>Where are the WS-* Protocols? (Part One)</title><link>http://blogs.msdn.com/garretts/archive/2006/08/07/691018.aspx</link><pubDate>Mon, 07 Aug 2006 18:06:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:691018</guid><dc:creator>GarrettS</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/garretts/comments/691018.aspx</comments><wfw:commentRss>http://blogs.msdn.com/garretts/commentrss.aspx?PostID=691018</wfw:commentRss><description>&lt;P&gt;&lt;STRONG&gt;Logging into a Website&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;When signing into a website using CardSpace, the website has the choice of accepting two card types, Personal Cards or Managed Cards.&lt;/P&gt;
&lt;P&gt;Personal Cards are ones that you create the claim values yourself, support only a fixed set of claims, and have the cryptographic keys and PPID generated for you.&lt;/P&gt;
&lt;P&gt;Managed Cards are cards that are issued to you from an Identity Provider, they decide the claims, and they provide the Security Token Server that issues the token to the webiste. We'll cover this one in Part Two.&lt;/P&gt;
&lt;P&gt;Personal Cards and the Protocols&lt;/P&gt;
&lt;P&gt;When a website requests a personal card, it does so by putting an object element into the HTML of the page, and engaging the CardSpace Identity Selector:&lt;/P&gt;
&lt;P&gt;
&lt;HR&gt;

&lt;STYLE type=text/css&gt;
.S0 {
	font-family: 'Consolas';
	color: #000000;
	background: #FFFFFF;
	font-size: 9pt;
}
.S1 {
	color: #000080;
	background: #FFFFFF;
}
.S3 {
	color: #008080;
	background: #FFFFFF;
}
.S5 {
	color: #007F7F;
	background: #FFFFFF;
}
.S6 {
	color: #7F007F;
	background: #FFFFFF;
}
.S8 {
	color: #800080;
	background: #FFFFFF;
}
.S11 {
	color: #000080;
	background: #FFFFFF;
}
.S21 {
	color: #000080;
	background: #EFEFFF;
}
.S22 {
	font-weight: bold;
	color: #000080;
	background: #EFEFFF;
}
.S23 {
	color: #006600;
	background: #EFEFFF;
}
.S24 {
	color: #800000;
	background: #EFEFFF;
}
span {
	font-family: 'Consolas';
	color: #000000;
	background: #FFFFFF;
	font-size: 9pt;
}
.S40 {
	color: #7F7F00;
	background: #FFFFFF;
}
.S41 {
	font-weight: bold;
	font-family: 'Consolas';
	color: #000000;
	background: #F0F0FF;
	font-size: 9pt;
}
.S46 {
	font-family: 'Consolas';
	color: #000000;
	background: #F0F0FF;
	font-size: 9pt;
}
.S47 {
	font-weight: bold;
	font-family: 'Consolas';
	color: #00007F;
	background: #F0F0FF;
	font-size: 9pt;
}
.S48 {
	font-family: 'Consolas';
	color: #7F007F;
	background: #F0F0FF;
	font-size: 9pt;
}
.S50 {
	font-weight: bold;
	font-family: 'Consolas';
	color: #000000;
	background: #F0F0FF;
	font-size: 9pt;
}
&lt;/STYLE&gt;
&lt;SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;html&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;xmlns&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"http://www.w3.org/1999/xhtml"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S1&gt;&amp;lt;head&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;title&amp;gt;&lt;/SPAN&gt;&lt;SPAN class=S0&gt;Sample 4&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;/title&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;object&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;type&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"application/x-informationcard"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;name&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"_xmlToken"&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;param&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;name&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"tokenType"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;value&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"urn:oasis:names:tc:SAML:1.0:assertion"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S11&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;param&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;name&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"issuer"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; value&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"http://schemas.microsoft.com/ws/2005/05/identity/issuer/self"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S11&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;param&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;name&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"requiredClaims"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; value&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"http://schemas.microsoft.com/ws/2005/05/identity/claims/givenname &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; http://schemas.microsoft.com/ws/2005/05/identity/claims/surname&amp;nbsp;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; http://schemas.microsoft.com/ws/2005/05/identity/claims/emailaddress&amp;nbsp;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; http://schemas.microsoft.com/ws/2005/05/identity/claims/privatepersonalidentifier"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S11&gt;/&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;/object&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;script&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;language&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"javascript"&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;

&lt;SPAN class=S41&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S47&gt;function&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S46&gt;GetIdentity&lt;/SPAN&gt;&lt;SPAN class=S50&gt;()&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S41&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S50&gt;{&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S41&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S47&gt;var&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S46&gt;xmltkn&lt;/SPAN&gt;&lt;SPAN class=S50&gt;=&lt;/SPAN&gt;&lt;SPAN class=S46&gt;document.getElementById&lt;/SPAN&gt;&lt;SPAN class=S50&gt;(&lt;/SPAN&gt;&lt;SPAN class=S48&gt;"_xmltoken"&lt;/SPAN&gt;&lt;SPAN class=S50&gt;);&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S41&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S47&gt;var&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S46&gt;thetextarea&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S50&gt;=&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S46&gt;document.getElementById&lt;/SPAN&gt;&lt;SPAN class=S50&gt;(&lt;/SPAN&gt;&lt;SPAN class=S48&gt;"xmltoken"&lt;/SPAN&gt;&lt;SPAN class=S50&gt;);&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S41&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S46&gt;thetextarea.value&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S50&gt;=&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S46&gt;xmltkn.value&lt;/SPAN&gt;&lt;SPAN class=S41&gt; &lt;/SPAN&gt;&lt;SPAN class=S50&gt;;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S41&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S50&gt;}&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S1&gt;&lt;SPAN class=S0&gt;&lt;FONT size=3&gt;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&amp;lt;/script&amp;gt;&lt;/SPAN&gt;

&lt;BR&gt;&lt;SPAN class=S1&gt;&amp;lt;/head&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S1&gt;&amp;lt;body&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;form&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;id&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"form1"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;method&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"post"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;action&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"login4.aspx"&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;div&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;button&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;name&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"go"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;id&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"go"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;onclick&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"javascript:GetIdentity();"&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;gt;&lt;BR&gt;&lt;/SPAN&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Click here to get the token.&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;/button&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;button&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;type&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"submit"&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN class=S0&gt;Click here to send the card to the server&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;/button&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;textarea&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;cols&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S5&gt;100&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;rows&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S5&gt;20&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;id&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"xmltoken"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S3&gt;name&lt;/SPAN&gt;&lt;SPAN class=S8&gt;=&lt;/SPAN&gt;&lt;SPAN class=S6&gt;"xmlToken"&lt;/SPAN&gt;&lt;SPAN class=S8&gt; &lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;gt;&amp;lt;/textarea&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;/div&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class=S1&gt;&amp;lt;/form&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S0&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S1&gt;&amp;lt;/body&amp;gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;SPAN class=S1&gt;&amp;lt;/html&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt; 
&lt;HR&gt;
&lt;BR&gt;&lt;BR&gt;This obviously does not use any WS-* protocols, it's just simply asking the browser to supply the token requested to the website. And, with no STS in the puzzle, where's the WS-*?&lt;BR&gt;&lt;BR&gt;Well, there &lt;EM&gt;&lt;STRONG&gt;is&lt;/STRONG&gt;&lt;/EM&gt; an STS. It's built into the CardSpace Identity Selector. It's there to provide the&amp;nbsp;Personal card to the Relying Party (the website). The communication between the Identity Selector and the STS should be WS-* right? Well, since they are tightly coupled in this case, the STS in CardSpace short-circuits some of that and delivers the token to the browser just using inter-process communication. But the STS is built as if it was going to go over a wire, just optimized for local use.
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;So, there really isn't WS-* involved here. Until CardSpace supports a Portable STS, which then would seperate the Idenity store from the Idenity Selector, thus requiring WS-*. &lt;/P&gt;
&lt;P&gt;
&lt;TABLE style="BORDER-COLLAPSE: collapse" cellSpacing=0 cellPadding=0 border=0&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD style="PADDING-RIGHT: 0pt; PADDING-LEFT: 0pt; PADDING-BOTTOM: 0in; PADDING-TOP: 0in" vAlign=center width=55&gt;
&lt;P style="TEXT-ALIGN: center" align=center valign="middle"&gt;&lt;SPAN style="FONT-SIZE: 60pt; FONT-FAMILY: Elephant"&gt;g&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD style="PADDING-RIGHT: 0pt; PADDING-LEFT: 0pt; PADDING-BOTTOM: 0in; PADDING-TOP: 0in" vAlign=center&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: Arial"&gt;&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;Garrett Serack&amp;nbsp;|&amp;nbsp;Program Manager&amp;nbsp;|Federated Identity Team | Microsoft Corporation&lt;BR&gt;blog: &lt;A href="http://blogs.msdn.com/garretts"&gt;http://blogs.msdn.com/garretts&lt;/A&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=691018" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx">scripting</category><category domain="http://blogs.msdn.com/garretts/archive/tags/CardSpace/default.aspx">CardSpace</category></item><item><title>Detecting Information Card Support (CardSpace!) in a browser</title><link>http://blogs.msdn.com/garretts/archive/2006/08/04/688971.aspx</link><pubDate>Sat, 05 Aug 2006 01:23:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:688971</guid><dc:creator>GarrettS</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/garretts/comments/688971.aspx</comments><wfw:commentRss>http://blogs.msdn.com/garretts/commentrss.aspx?PostID=688971</wfw:commentRss><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;FONT face=Arial&gt;I hacked out this a few weeks back, and never got around to publishing it.&amp;nbsp; I've not decided that this is the 'official' way to detect Information Card support in a browser, but it'll do until I can think of something better.&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;FONT face=Arial&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;FONT face=Arial&gt;I'd say something like, "see how it detects support in other browsers too?" except that I'm not thinking many people have a CardSpace plugin for another browser yet. But you can trust me--It works!&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;
&lt;HR&gt;
&lt;/SPAN&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;html&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;head&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;SCRIPT&lt;/SPAN&gt;&lt;SPAN style="COLOR: purple; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: teal; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;LANGUAGE&lt;/SPAN&gt;&lt;SPAN style="COLOR: purple; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"Javascript"&lt;/SPAN&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;TABLE class=MsoTableGrid style="BORDER-RIGHT: medium none; BORDER-TOP: medium none; BACKGROUND: #e3ddeb; BORDER-LEFT: medium none; BORDER-BOTTOM: medium none; BORDER-COLLAPSE: collapse; mso-padding-alt: 0in 5.4pt 0in 5.4pt; mso-yfti-tbllook: 1184; mso-border-insideh: none; mso-border-insidev: none" cellSpacing=0 cellPadding=0 border=0&gt;
&lt;TBODY&gt;
&lt;TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes"&gt;
&lt;TD style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 5.4pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: #f0f0f0; WIDTH: 6.65in; PADDING-TOP: 0in; BORDER-BOTTOM: #f0f0f0; BACKGROUND-COLOR: transparent" vAlign=top width=638&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;function&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;AreCardsSupported&lt;B&gt;()&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;var&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;IEVer&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;=&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;-&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: #007f7f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;1&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;;&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;(&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;navigator&lt;B&gt;.&lt;/B&gt;appName&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;==&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;'Microsoft Internet Explorer'&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;(&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;new&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;RegExp&lt;B&gt;(&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"MSIE ([0-9]{1,}[\.0-9]{0,})"&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt 0.5in; TEXT-INDENT: 0.5in; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;.&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;exec&lt;B&gt;(&lt;/B&gt;navigator&lt;B&gt;.&lt;/B&gt;userAgent&lt;B&gt;)&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;!=&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;null&lt;B&gt;)&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;IEVer&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;=&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;parseFloat&lt;B&gt;(&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;RegExp&lt;B&gt;.&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;$&lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;1&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;);&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;FONT size=2&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;(&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;IEVer&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;gt;=&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;6&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;var&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;embed&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;=&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;document&lt;B&gt;.&lt;/B&gt;createElement&lt;B&gt;(&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"object"&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;);&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;embed&lt;B&gt;.&lt;/B&gt;setAttribute&lt;B&gt;(&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"type"&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;,&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"application/x-informationcard"&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;);&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;FONT size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;(&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;""&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;+&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;embed&lt;B&gt;.&lt;/B&gt;issuerPolicy&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;!=&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"undefined"&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;return&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;true&lt;B&gt;;&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;return&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;false&lt;B&gt;;&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;(&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;IEVer&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;0&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;amp;&amp;amp;&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;navigator&lt;B&gt;.&lt;/B&gt;mimeTypes&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;amp;&amp;amp;&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;navigator&lt;B&gt;.&lt;/B&gt;mimeTypes&lt;B&gt;.&lt;/B&gt;length&lt;B&gt;)&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;x&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;=&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;navigator&lt;B&gt;.&lt;/B&gt;mimeTypes&lt;B&gt;[&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;'application/x-informationcard'&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;];&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;(&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;x&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;amp;&amp;amp;&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;x&lt;B&gt;.&lt;/B&gt;enabledPlugin&lt;B&gt;)&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;return&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;true&lt;B&gt;;&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;return&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;false&lt;B&gt;;&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;}&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;FONT size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;function&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;ShowDetection&lt;B&gt;()&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;{&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;(&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;AreCardsSupported&lt;B&gt;()&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;alert&lt;B&gt;(&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"Information Cards are supported by this browser :D"&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;);&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;else&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;alert&lt;B&gt;(&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"Information Cards are NOT supported by this browser :("&lt;/SPAN&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;);&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: gray; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;B&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;FONT size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;/SCRIPT&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;body&lt;/SPAN&gt;&lt;SPAN style="COLOR: purple; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: teal; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;onload&lt;/SPAN&gt;&lt;SPAN style="COLOR: purple; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"ShowDetection()"&lt;/SPAN&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;FONT size=2&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;/body&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; LINE-HEIGHT: normal; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: navy; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;lt;/head&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;HR&gt;

&lt;P class=MsoNormal style="MARGIN: 0in 0in 8pt"&gt;&lt;o:p&gt;&lt;FONT face=Calibri&gt;&lt;/FONT&gt;&lt;/o:p&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 8pt"&gt;&lt;o:p&gt;
&lt;TABLE class=MsoNormalTable style="WIDTH: 6.45in; BORDER-COLLAPSE: collapse; mso-padding-alt: 0in 0in 0in 0in; mso-yfti-tbllook: 1184" cellSpacing=0 cellPadding=0 width=619 border=0&gt;
&lt;TBODY&gt;
&lt;TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes"&gt;
&lt;TD style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 5.4pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: #f0f0f0; WIDTH: 77.4pt; PADDING-TOP: 0in; BORDER-BOTTOM: #f0f0f0; BACKGROUND-COLOR: transparent" vAlign=top width=103&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt; TEXT-ALIGN: center; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto" align=center&gt;&lt;A name=_MailAutoSig&gt;&lt;SPAN style="FONT-SIZE: 72pt; FONT-FAMILY: 'Elephant','serif'; mso-bidi-font-family: Tunga; mso-font-kerning: 8.0pt; mso-no-proof: yes"&gt;g&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 72pt; FONT-FAMILY: 'Elephant','serif'; mso-bidi-font-family: Tunga; mso-font-kerning: 8.0pt; mso-no-proof: yes; mso-fareast-font-family: Calibri"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;
&lt;TD style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 5.4pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: #f0f0f0; WIDTH: 387pt; PADDING-TOP: 0in; BORDER-BOTTOM: #f0f0f0; BACKGROUND-COLOR: transparent" vAlign=top width=516&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto"&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="mso-no-proof: yes"&gt;&lt;BR&gt;&lt;BR style="mso-special-character: line-break"&gt;&lt;BR style="mso-special-character: line-break"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="mso-ascii-font-family: Calibri; mso-hansi-font-family: Calibri; mso-no-proof: yes"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto"&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;Garrett Serack&amp;nbsp;|&amp;nbsp;Program Manager&amp;nbsp;| Connected Identity and Directory| Microsoft Corporation&lt;BR&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;A title=mailto:garretts@microsoft.com href="mailto:garretts@microsoft.comblog" target=_blank&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;blog&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;: &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;A title=http://blogs.msdn.com/garretts href="http://blogs.msdn.com/garretts" target=_blank&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: purple; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;http://blogs.msdn.com/garretts&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 12pt; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes; mso-fareast-font-family: Calibri"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/o:p&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=688971" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx">scripting</category><category domain="http://blogs.msdn.com/garretts/archive/tags/CardSpace/default.aspx">CardSpace</category></item><item><title>Scripting: Detecting the host architecture vs the process architecture</title><link>http://blogs.msdn.com/garretts/archive/2006/08/04/688788.aspx</link><pubDate>Fri, 04 Aug 2006 22:06:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:688788</guid><dc:creator>GarrettS</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/garretts/comments/688788.aspx</comments><wfw:commentRss>http://blogs.msdn.com/garretts/commentrss.aspx?PostID=688788</wfw:commentRss><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt"&gt;&lt;SPAN style="mso-fareast-language: ZH-CN"&gt;&lt;FONT face=Calibri&gt;I had some trouble lately with scripts running on a 64bit version of Vista, when they were run with a 32 bit parent host process.&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt"&gt;&lt;SPAN style="mso-fareast-language: ZH-CN"&gt;&lt;FONT face=Calibri&gt;After figuring out what was wrong, I wanted to be able to detect if I was running a 32-bit script engine under a 64-bit OS. With a bit of crafty (crufty?) coding, I came up with the following VBScript which I put at the top of my script:&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;sub&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; EnsureNativeScriptEngine&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;On&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;Error&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;resume&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;next&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;dim&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; WshShell,WshProcEnv,system_architecture, process_architecture&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;Set&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; WshShell =&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;CreateObject(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"WScript.Shell"&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;Set&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; WshProcEnv = WshShell.Environment(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"Process"&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;process_architecture= WshProcEnv(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"PROCESSOR_ARCHITECTURE"&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; process_architecture = &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"x86"&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;then&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;system_architecture= WshProcEnv(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"PROCESSOR_ARCHITEW6432"&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; system_architecture = &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;""&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;then&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;system_architecture = &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"x86"&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;end&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;else&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;FONT size=2&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;system_architecture = process_architecture&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;end&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;FONT size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;NOT&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; system_architecture = process_architecture &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;then&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;WshShell.popup &lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"This script should be run as a "&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;amp; system_architecture &amp;amp; _&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; TEXT-INDENT: 0.5in; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;"process, but is running as a "&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&amp;amp; process_architecture &amp;amp;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #7f007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;" process."&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;WScript.quit &lt;/SPAN&gt;&lt;SPAN style="COLOR: #007f7f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;1&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;end&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;if&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;end&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #00007f; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;sub&lt;/SPAN&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt"&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;FONT size=2&gt;EnsureNativeScriptEngine&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt"&gt;&lt;SPAN style="COLOR: black; FONT-FAMILY: Consolas; mso-bidi-font-family: Consolas"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt"&gt;&lt;SPAN style="mso-fareast-language: ZH-CN"&gt;&lt;FONT face=Calibri&gt;Which is fine and dandy, except I’d really have liked to just transparently execute the script with the right version of the script host.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt"&gt;&lt;SPAN style="mso-fareast-language: ZH-CN"&gt;&lt;o:p&gt;&lt;FONT face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt"&gt;&lt;SPAN style="mso-fareast-language: ZH-CN"&gt;&lt;FONT face=Calibri&gt;Ah well, at least this tells me what’s going on. &lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: Wingdings; mso-ascii-font-family: Calibri; mso-hansi-font-family: Calibri; mso-char-type: symbol; mso-symbol-font-family: Wingdings; mso-fareast-language: ZH-CN; mso-ascii-theme-font: minor-latin; mso-hansi-theme-font: minor-latin"&gt;&lt;SPAN style="mso-char-type: symbol; mso-symbol-font-family: Wingdings"&gt;J&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-fareast-language: ZH-CN"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;TABLE class=MsoNormalTable style="WIDTH: 6.45in; BORDER-COLLAPSE: collapse; mso-padding-alt: 0in 0in 0in 0in; mso-yfti-tbllook: 1184" cellSpacing=0 cellPadding=0 width=619 border=0&gt;
&lt;TBODY&gt;
&lt;TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes"&gt;
&lt;TD style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 5.4pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: #f0f0f0; WIDTH: 77.4pt; PADDING-TOP: 0in; BORDER-BOTTOM: #f0f0f0; BACKGROUND-COLOR: transparent" vAlign=top width=103&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt; TEXT-ALIGN: center; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto" align=center&gt;&lt;A name=_MailAutoSig&gt;&lt;SPAN style="FONT-SIZE: 72pt; FONT-FAMILY: 'Elephant','serif'; mso-bidi-font-family: Tunga; mso-font-kerning: 8.0pt; mso-no-proof: yes"&gt;g&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 72pt; FONT-FAMILY: 'Elephant','serif'; mso-bidi-font-family: Tunga; mso-font-kerning: 8.0pt; mso-no-proof: yes; mso-fareast-font-family: Calibri"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;
&lt;TD style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 5.4pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: #f0f0f0; WIDTH: 387pt; PADDING-TOP: 0in; BORDER-BOTTOM: #f0f0f0; BACKGROUND-COLOR: transparent" vAlign=top width=516&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto"&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="mso-no-proof: yes"&gt;&lt;BR&gt;&lt;BR style="mso-special-character: line-break"&gt;&lt;BR style="mso-special-character: line-break"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="mso-no-proof: yes; mso-ascii-font-family: Calibri; mso-hansi-font-family: Calibri"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 10pt; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto"&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;Garrett Serack&amp;nbsp;|&amp;nbsp;Program Manager&amp;nbsp;| Connected Identity and Directory| Microsoft Corporation&lt;BR&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;A title=mailto:garretts@microsoft.com href="mailto:garretts@microsoft.comblog" target=_blank&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;blog&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;: &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;A title=http://blogs.msdn.com/garretts href="http://blogs.msdn.com/garretts" target=_blank&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: purple; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;http://blogs.msdn.com/garretts&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 12pt; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes; mso-fareast-font-family: Calibri"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=688788" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx">scripting</category><category domain="http://blogs.msdn.com/garretts/archive/tags/Vista/default.aspx">Vista</category></item><item><title>Self compiling scripts for .NET languages: C#, VB.NET and JScript.NET</title><link>http://blogs.msdn.com/garretts/archive/2006/07/31/684874.aspx</link><pubDate>Tue, 01 Aug 2006 07:53:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:684874</guid><dc:creator>GarrettS</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/garretts/comments/684874.aspx</comments><wfw:commentRss>http://blogs.msdn.com/garretts/commentrss.aspx?PostID=684874</wfw:commentRss><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Ok, these ones are pretty cool. It took me a few more hours than I thought, but it was worth it.&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;The scripts in the zip file are javascripts which surround another language, and allow you to write .NET applications, but distribute simple text files as scripts.&lt;o:p&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;The C# and JScript.net wrappers are perfectly identical, the VB.NET one required a little more playing to get right. – and it’s just the smuggling lines that are different, the script itself is the same.&lt;o:p&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;I’ve coded a simple hello world example into each of the languages.&lt;o:p&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;The ‘trimmed’ versions allow you to simply add the five lines at the top, and the last line to your source file and have it run anywhere .NET 2.0 is installed.&lt;o:p&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;Oh, and even better: &lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;if you drop the .JS on the end, the script loads in Visual Studio just fine as a class—you can do all of your testing with the script header in place and then just rename it when you want to redistribute it.&lt;o:p&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;A href="http://serack.org/SelfCompilingScriptExamples.zip"&gt;&lt;FONT color=#800080&gt;http://serack.org/SelfCompilingScriptExamples.zip&lt;/FONT&gt;&lt;/A&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;TABLE class=MsoNormalTable style="WIDTH: 6.45in; BORDER-COLLAPSE: collapse; mso-padding-alt: 0in 0in 0in 0in" cellSpacing=0 cellPadding=0 width=619 border=0&gt;
&lt;TBODY&gt;
&lt;TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes"&gt;
&lt;TD style="BORDER-RIGHT: #ebe9ed; PADDING-RIGHT: 5.4pt; BORDER-TOP: #ebe9ed; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: #ebe9ed; WIDTH: 77.4pt; PADDING-TOP: 0in; BORDER-BOTTOM: #ebe9ed; BACKGROUND-COLOR: transparent" vAlign=top width=103&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; TEXT-ALIGN: center; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto" align=center&gt;&lt;A name=_MailAutoSig&gt;&lt;SPAN style="FONT-SIZE: 72pt; FONT-FAMILY: 'Elephant','serif'; mso-bidi-font-family: Tunga; mso-font-kerning: 8.0pt; mso-no-proof: yes"&gt;g&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 72pt; FONT-FAMILY: 'Elephant','serif'; mso-bidi-font-family: Tunga; mso-fareast-font-family: Calibri; mso-font-kerning: 8.0pt; mso-no-proof: yes"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;
&lt;TD style="BORDER-RIGHT: #ebe9ed; PADDING-RIGHT: 5.4pt; BORDER-TOP: #ebe9ed; PADDING-LEFT: 5.4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: #ebe9ed; WIDTH: 387pt; PADDING-TOP: 0in; BORDER-BOTTOM: #ebe9ed; BACKGROUND-COLOR: transparent" vAlign=top width=516&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto"&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="mso-no-proof: yes"&gt;&lt;BR style="mso-special-character: line-break"&gt;&lt;BR style="mso-special-character: line-break"&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="mso-ascii-font-family: Calibri; mso-hansi-font-family: Calibri; mso-no-proof: yes"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto"&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;Garrett Serack&amp;nbsp;|&amp;nbsp;Program Manager&amp;nbsp;| Connected Identity and Directory| Microsoft Corporation&lt;BR&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;A title=mailto:garretts@microsoft.com href="mailto:garretts@microsoft.comblog" target=_blank&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;blog&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;: &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;A title=http://blogs.msdn.com/garretts href="http://blogs.msdn.com/garretts" target=_blank&gt;&lt;FONT color=#800080&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;http://blogs.msdn.com/garretts&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/A&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: #999999; FONT-FAMILY: 'Arial','sans-serif'; mso-no-proof: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;SPAN style="FONT-SIZE: 12pt; FONT-FAMILY: 'Arial','sans-serif'; mso-fareast-font-family: Calibri; mso-no-proof: yes"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;SPAN style="mso-bookmark: _MailAutoSig"&gt;&lt;/SPAN&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=684874" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/garretts/archive/tags/scripting/default.aspx">scripting</category></item></channel></rss>