<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://msmvps.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>El blog de Lluis Franco : .NET</title><link>http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx</link><description>Tags: .NET</description><dc:language>en</dc:language><generator>CommunityServer 2008.5 SP2 (Build: 40407.4157)</generator><item><title>HowTo: Agrupando grupos :-)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/11/26/howto-agrupando-grupos.aspx</link><pubDate>Thu, 26 Nov 2009 11:53:51 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1742271</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1742271</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/11/26/howto-agrupando-grupos.aspx#comments</comments><description>&lt;p&gt;Una entrada rápida, no como la de &lt;a href="http://geeks.ms/blogs/lfranco/archive/2009/11/25/how-to-191-como-saber-si-el-usuario-actual-es-administrador-del-dominio.aspx" target="_blank"&gt;ayer&lt;/a&gt;. Aunque el tema está bastante relacionado ya que ambos tratan de Active Directory e identidades.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.uyssoft.com/blog/images/HowToAgrupandogrupos_9B56/GroupPolicy.jpg"&gt;&lt;img style="border-bottom:0px;border-left:0px;display:inline;border-top:0px;border-right:0px;" title="GroupPolicy" border="0" alt="GroupPolicy" src="http://www.uyssoft.com/blog/images/HowToAgrupandogrupos_9B56/GroupPolicy_thumb.jpg" width="244" height="142" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;p&gt;Hoy vamos a ver una forma sencilla de obtener todos los grupos a los que pertenece un usuario, y agruparlos por su nombre de dominio. Y todo esto mediante una sola sentencia LINQ to objects. A ver quién es el guapo o guapa que me dice que LINQ to objects no es una maravilla!&lt;/p&gt;  &lt;p&gt;El resultado que vamos a obtener es el siguiente (algunos nombres se han omitido por razones obvias :-P):&lt;/p&gt;  &lt;p&gt;&lt;font size="2" face="Lucida Console"&gt;Groups under:      &lt;br /&gt;&amp;#160; - Group name: Todos      &lt;br /&gt;&amp;#160; - Group name: LOCAL      &lt;br /&gt;Groups under: BUILTIN      &lt;br /&gt;&amp;#160; - Group name: Usuarios      &lt;br /&gt;&amp;#160; - Group name: Administradores      &lt;br /&gt;Groups under: PRIMARY_DOMAIN_NAME      &lt;br /&gt;&amp;#160; - Group name: xxx1      &lt;br /&gt;&amp;#160; - Group name: xxx2      &lt;br /&gt;&amp;#160; - Group name: xxx3      &lt;br /&gt;&amp;#160; - Group name: xxx4      &lt;br /&gt;&amp;#160; - Group name: xxxN      &lt;br /&gt;Groups under: NT AUTHORITY      &lt;br /&gt;&amp;#160; - Group name: INTERACTIVE      &lt;br /&gt;&amp;#160; - Group name: Usuarios autentificados&lt;/font&gt;&lt;/p&gt;  &lt;p&gt;Y el código resultante es un método extensor para la clase WindowsIdentity, con dos funciones auxiliares en forma de métodos extensores de la clase NTAccount:&lt;/p&gt;  &lt;p&gt;&lt;/p&gt;  &lt;div&gt;   &lt;div style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;     &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Collections.Generic;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.DirectoryServices;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.DirectoryServices.ActiveDirectory;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Linq;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Net.NetworkInformation;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Runtime.InteropServices;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Security.Principal;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Text;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;namespace&lt;/span&gt; Alpha.Code&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;{&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SecurityExtensions&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;    {&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; IOrderedEnumerable&amp;lt;IGrouping &amp;lt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;, NTAccount&amp;gt;&amp;gt; &lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;            GetGroupsUnderDomains(&lt;span style="color:#0000ff;"&gt;this&lt;/span&gt; WindowsIdentity identity)&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        {&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;            var groups =&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        from grIdentity &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; identity.Groups&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        &lt;span style="color:#0000ff;"&gt;where&lt;/span&gt; grIdentity.IsValidTargetType(&lt;span style="color:#0000ff;"&gt;typeof&lt;/span&gt;(NTAccount))&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        select grIdentity.Translate(&lt;span style="color:#0000ff;"&gt;typeof&lt;/span&gt;(NTAccount)) &lt;span style="color:#0000ff;"&gt;as&lt;/span&gt; NTAccount into ntAccounts&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        let domainName = ntAccounts.GetDomainName()&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        let groupName = ntAccounts.GetAccountName()&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        orderby domainName&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        group ntAccounts by domainName into domainGroups&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        orderby domainGroups.Key&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;                        select domainGroups;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; groups;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        }&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; GetDomainName(&lt;span style="color:#0000ff;"&gt;this&lt;/span&gt; NTAccount account)&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        {&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;[] split = account.Value.Split(&lt;span style="color:#006080;"&gt;&amp;#39;\\&amp;#39;);&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;            return split.Length == 1 ? string.Empty : split[0];&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        }&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        public static string GetAccountName(this NTAccount account)&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        {&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;            string[] split = account.Value.Split(&amp;#39;&lt;/span&gt;\\&amp;#39;);&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; split[split.Length - 1];&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        }&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;    }&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;}&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;Para probarlo y ver el resultado:&lt;/p&gt;

&lt;div&gt;
  &lt;div style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;
    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;var groups = WindowsIdentity.GetCurrent().GetGroupsUnderDomains();&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;&lt;span style="color:#0000ff;"&gt;foreach&lt;/span&gt; (var dg &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; groups)&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;{&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;    Console.WriteLine(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(&lt;span style="color:#006080;"&gt;&amp;quot;Groups under: {0}&amp;quot;&lt;/span&gt;, dg.Key));&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;foreach&lt;/span&gt; (var g &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; dg)&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;    {&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;        Console.WriteLine(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(&lt;span style="color:#006080;"&gt;&amp;quot;  - Group name: {0}&amp;quot;&lt;/span&gt;, g.GetAccountName()));&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:#f4f4f4;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;    }&lt;/pre&gt;

    &lt;pre style="border-bottom-style:none;padding-bottom:0px;line-height:12pt;border-right-style:none;background-color:white;margin:0em;padding-left:0px;width:100%;padding-right:0px;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;border-top-style:none;color:black;font-size:8pt;border-left-style:none;overflow:visible;padding-top:0px;"&gt;}&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;Un saludo desde las frías tierras de Andorra :-)&lt;/p&gt;

&lt;p&gt;Noviembre 2009&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1742271" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/LDAP/default.aspx">LDAP</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/HowTo/default.aspx">HowTo</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2009/default.aspx">2009</category></item><item><title>How To: ¿Como saber si el usuario actual es administrador del dominio?</title><link>http://msmvps.com/blogs/lfranco/archive/2009/11/25/how-to-191-como-saber-si-el-usuario-actual-es-administrador-del-dominio.aspx</link><pubDate>Wed, 25 Nov 2009 18:03:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1742245</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1742245</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/11/25/how-to-191-como-saber-si-el-usuario-actual-es-administrador-del-dominio.aspx#comments</comments><description>&lt;blockquote&gt;
&lt;p align="justify"&gt;&lt;strong&gt;Nota:&lt;/strong&gt; Es una pregunta que me encuentro de forma recurrente en los foros de desarrollo, as&amp;iacute; que lo apunto aqu&amp;iacute; para tener una referencia.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h4&gt;El escenario&lt;/h4&gt;
&lt;p align="justify"&gt;Cuando desarrollamos una aplicaci&amp;oacute;n de escritorio, puede ser interesante saber a qu&amp;eacute; grupos pertenece el usuario que est&amp;aacute; ejecutando nuestra aplicaci&amp;oacute;n, para mostrar / ocultar / permitir / revocar ciertas acciones, u opciones. Por ejemplo, yo acostumbro a tener un bot&amp;oacute;n en la barra de estado de mis aplicaciones que permite cambiar la cadena de conexi&amp;oacute;n, y evidentemente, solo est&amp;aacute; visible cuando el usuario pertenece al grupo &amp;ldquo;Administradores del dominio&amp;rdquo;.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://www.uyssoft.com/blog/images/HowToComosabersielusuarioactualesadminis_EA12/privileges.jpg"&gt;&lt;img height="244" width="244" src="http://www.uyssoft.com/blog/images/HowToComosabersielusuarioactualesadminis_EA12/privileges_thumb.jpg" alt="privileges" border="0" title="privileges" style="border-right-width:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;h4&gt;IsInRole&lt;/h4&gt;
&lt;p align="justify"&gt;Para ello, el objeto &lt;a target="_blank" href="http://msdn.microsoft.com/es-es/library/system.security.principal.windowsprincipal(VS.80).aspx"&gt;WindowsPrincipal&lt;/a&gt; dispone de un m&amp;eacute;todo &lt;a target="_blank" href="http://msdn.microsoft.com/es-es/library/system.security.principal.windowsprincipal.isinrole(VS.80).aspx"&gt;IsInRole&lt;/a&gt;, que nos dir&amp;agrave; si un usuario pertenece a un grupo determinado. Genial, adem&amp;aacute;s este m&amp;eacute;todo tiene varias sobrecargas, de modo que podemos usarlo pasando el RID, SID, el nombre e incluso una constante basada en la enumeraci&amp;oacute;n &lt;a target="_blank" href="http://msdn.microsoft.com/es-es/library/system.security.principal.windowsbuiltinrole(VS.80).aspx"&gt;WindowsBuiltIOnRole&lt;/a&gt;: &lt;/p&gt;
&lt;table cellpadding="0" cellspacing="0" border="0"&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td width="179"&gt;&lt;strong&gt;Nombre de miembro&lt;/strong&gt;&lt;/td&gt;
&lt;td width="1693"&gt;&lt;strong&gt;Descripci&amp;oacute;n&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountOperator&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los operadores de cuentas administran las cuentas de los usuarios de un equipo o dominio. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Administrator&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los administradores tienen acceso completo y sin restricciones al equipo o dominio. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BackupOperator&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los operadores de copia de seguridad pueden reemplazar las restricciones de seguridad con el &amp;uacute;nico prop&amp;oacute;sito de hacer copias de seguridad de los archivos o de restaurarlas. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Guest&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los invitados tienen m&amp;aacute;s restricciones que los usuarios. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;PowerUser&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los usuarios avanzados poseen la mayor&amp;iacute;a de los permisos administrativos, con algunas restricciones. De este modo, los usuarios avanzados pueden ejecutar aplicaciones heredadas, adem&amp;aacute;s de aplicaciones certificadas. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;PrintOperator&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los operadores de impresi&amp;oacute;n pueden tomar el control de una impresora. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Replicator&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los replicadores permiten la duplicaci&amp;oacute;n de archivos en un dominio. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;SystemOperator&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los operadores del sistema administran un equipo en particular. &lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;User&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Los usuarios no pueden realizar cambios accidentales o intencionados en todo el sistema. En consecuencia, pueden ejecutar aplicaciones certificadas, pero no la mayor&amp;iacute;a de las aplicaciones heredadas.&amp;nbsp; &lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p align="justify"&gt;De modo que para saber si nuestro usuario es administrador local, basta con hacer esto:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;WindowsPrincipal wp = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; WindowsPrincipal(WindowsIdentity.GetCurrent());&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; wp.IsInRole(WindowsBuiltInRole.Administrator);&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Sencillo, verdad? A partir del usuario que ejecuta nuestra aplicaci&amp;oacute;n (v&amp;aacute;lido tambi&amp;eacute;n en caso de impersonaci&amp;oacute;n), creamos un objeto Principal e invocamos al m&amp;eacute;todo pas&amp;aacute;ndole el grupo contra el que deseamos validar.&lt;/p&gt;
&lt;p&gt;El problema de esta enumeraci&amp;oacute;n es que como su nombre indica, &lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;s&amp;oacute;lo contempla los grupos locales&lt;/span&gt;&lt;/strong&gt;. As&amp;iacute; que si queremos saber si pertenece a un grupo del dominio parece que tendremos que buscar el SID del grupo, o el nombre, y hardcodearlo &amp;lsquo;a mano&amp;rsquo; en nuestra aplicaci&amp;oacute;n. &lt;/p&gt;
&lt;p&gt;Feo verdad? Pues la verdad es que si, muy feo&amp;hellip; vamos a investigar un poco m&amp;aacute;s, a ver si encontramos otra forma.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Nota&lt;/strong&gt;: Por motivos de rendimiento, para determinar la funci&amp;oacute;n del usuario se recomienda utilizar la sobrecarga de &lt;a href="http://msdn.microsoft.com/es-es/library/wak3kd03(VS.80).aspx"&gt;IsInRole(SecurityIdentifier)&lt;/a&gt; como sobrecarga preferible.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h4&gt;WellKnownSidType&lt;/h4&gt;
&lt;p&gt;Existe una enumeraci&amp;oacute;n llamada &lt;a target="_blank" href="http://msdn.microsoft.com/en-us/library/system.security.principal.wellknownsidtype.aspx"&gt;WellKnownSidType&lt;/a&gt;, que devuelve los identificadores de seguridad m&amp;aacute;s utilizados, vamos a darle un vistazo:&lt;/p&gt;
&lt;table cellpadding="0" cellspacing="0" border="0"&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td width="385"&gt;
&lt;p&gt;&lt;strong&gt;Member name&lt;/strong&gt;&lt;/p&gt;
&lt;/td&gt;
&lt;td width="1737"&gt;&lt;strong&gt;Description&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;NullSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a null SID.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;WorldSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches everyone.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;LocalSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a local SID.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;CreatorOwnerSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the owner or creator of an object.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;CreatorGroupSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the creator group of an object.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;CreatorOwnerServerSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a creator owner server SID.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;CreatorGroupServerSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a creator group server SID.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;NTAuthoritySid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for the Windows NT authority.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;DialupSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for a dial-up account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;NetworkSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for a network account. This SID is added to the process of a token when it logs on across a network.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BatchSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for a batch process. This SID is added to the process of a token when it logs on as a batch job.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;InteractiveSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for an interactive account. This SID is added to the process of a token when it logs on interactively.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;ServiceSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for a service. This SID is added to the process of a token when it logs on as a service.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AnonymousSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for the anonymous account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;ProxySid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a proxy SID.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;EnterpriseControllersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for an enterprise controller.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;SelfSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for self.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AuthenticatedUserSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for an authenticated user.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;RestrictedCodeSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID for restricted code.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;TerminalServerSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches a terminal server account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;RemoteLogonIdSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches remote logons.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;LogonIdsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches logon IDs.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;LocalSystemSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the local system.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;LocalServiceSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches a local service.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;NetworkServiceSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches a network service.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinDomainSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the domain account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinAdministratorsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the administrator account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinUsersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches built-in user accounts.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinGuestsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the guest account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinPowerUsersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the power users group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinAccountOperatorsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account operators account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinSystemOperatorsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the system operators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinPrintOperatorsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the print operators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinBackupOperatorsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the backup operators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinReplicatorSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the replicator account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinPreWindows2000CompatibleAccessSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches pre-Windows 2000 compatible accounts.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinRemoteDesktopUsersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches remote desktop users.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinNetworkConfigurationOperatorsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the network operators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountAdministratorSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account administrators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountGuestSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account guest group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountKrbtgtSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account Kerberos target group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;&lt;span style="color:#ff0000;"&gt;AccountDomainAdminsSid&lt;/span&gt;&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;span style="color:#ff0000;"&gt;Indicates a SID that matches the account domain administrator group.&lt;/span&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountDomainUsersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account domain users group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountDomainGuestsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account domain guests group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountComputersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account computer group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountControllersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the account controller group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountCertAdminsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the certificate administrators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountSchemaAdminsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the schema administrators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountEnterpriseAdminsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the enterprise administrators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountPolicyAdminsSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the policy administrators group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;AccountRasAndIasServersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the RAS and IAS server account.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;NtlmAuthenticationSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID present when the Microsoft NTLM authentication package authenticated the client.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;DigestAuthenticationSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID present when the Microsoft Digest authentication package authenticated the client.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;SChannelAuthenticationSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID present when the Secure Channel (SSL/TLS) authentication package authenticated the client.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;ThisOrganizationSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID present when the user authenticated from within the forest or across a trust that does not have the selective authentication option enabled. If this SID is present, then OtherOrganizationSid cannot be present.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;OtherOrganizationSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID present when the user authenticated across a forest with the selective authentication option enabled. If this SID is present, then ThisOrganizationSid cannot be present.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinIncomingForestTrustBuildersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that allows a user to create incoming forest trusts. It is added to the token of users who are a member of the Incoming Forest Trust Builders built-in group in the root domain of the forest.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinPerformanceMonitoringUsersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the group of users that have remote access to schedule logging of performance counters on this computer.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinPerformanceLoggingUsersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the group of users that have remote access to monitor the computer.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;BuiltinAuthorizationAccessSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID that matches the Windows Authorization Access group.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;WinBuiltinTerminalServerLicenseServersSid&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates a SID is present in a server that can issue Terminal Server licenses.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;MaxDefined&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Indicates the maximum defined SID in the WellKnownSidType enumeration.&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;BINGO!!! Parece que tenemos el SID del grupo de admnistradores del dominio (lo he marcado en rojo en la tabla anterior).&lt;/p&gt;
&lt;p&gt;Ahora vamos a generar el SID del grupo de adminstradores del dominio y ya podemos volver a probar el m&amp;eacute;todo IsInRole:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;WindowsPrincipal wp = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; WindowsPrincipal(WindowsIdentity.GetCurrent());&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;SecurityIdentifier sid = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SecurityIdentifier(WellKnownSidType.AccountDomainAdminsSid, &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; wp.IsInRole(sid);&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Ops! Nuestro gozo en un pozo&amp;hellip; se necesita informar el segundo argumento del constructor para el SID del grupo:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.uyssoft.com/blog/images/HowToComosabersielusuarioactualesadminis_EA12/DomainSidError.png"&gt;&lt;img height="126" width="798" src="http://www.uyssoft.com/blog/images/HowToComosabersielusuarioactualesadminis_EA12/DomainSidError_thumb.png" alt="DomainSidError" border="0" title="DomainSidError" style="border-right-width:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;h4&gt;DomainSid&lt;/h4&gt;
&lt;p align="justify"&gt;&amp;iquest;Y que &lt;strong&gt;kkgrnn$#&lt;/strong&gt; representa que es este identificador? Pues seg&amp;uacute;n pone en &lt;a target="_blank" href="http://msdn.microsoft.com/en-us/library/214122bs.aspx"&gt;la ayuda del constructor&lt;/a&gt;, debe proporcionarse el SID del dominio para que el constructor pueda devolver algunos identificadores de WellKnownSidType, entre los cuales est&amp;aacute; el de los administradores del dominio. &lt;/p&gt;
&lt;p align="justify"&gt;Dicho de otro modo, o sabemos el SID de nuestro dominio o todo lo anterior no vale para nada&amp;hellip; :-(&lt;/p&gt;
&lt;p align="justify"&gt;&amp;iquest;Y c&amp;oacute;mo podemos saber el SID de dominio? Despu&amp;eacute;s de buscar un ratito, lo &amp;uacute;nico que he encontrado es una utilidad de consola llamada &lt;a href="http://www.microsoft.com/technet/sysinternals/utilities/psgetsid.mspx"&gt;PsGetSid&lt;/a&gt;, que forma parte de las PSTools del inefable Mark Russinovich. Basta descargar esta utilidad y ejecutarla desde la consola de este modo para saber el SID de nuestro dominio (el nombre de dominio en formato &amp;ldquo;microsoft.com&amp;rdquo; o &amp;ldquo;net.volvo.com&amp;rdquo;):&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://www.uyssoft.com/blog/images/HowToComosabersielusuarioactualesadminis_EA12/DomainSidConsole.png"&gt;&lt;img height="342" width="673" src="http://www.uyssoft.com/blog/images/HowToComosabersielusuarioactualesadminis_EA12/DomainSidConsole_thumb.png" alt="DomainSidConsole" border="0" title="DomainSidConsole" style="border-right-width:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Sin embargo, me niego a tener que hacer esto para saber el identificador del dominio. As&amp;iacute; que vamos a probar si podemos recuperar esta propiedad del esquema de AD mediante un DirectoryEntry. Para ello utilizaremos la clase Domain:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;Domain d = Domain.GetDomain(&lt;span style="color:#0000ff;"&gt;new&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    DirectoryContext(DirectoryContextType.Domain, getDomainName()));&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; (DirectoryEntry de = d.GetDirectoryEntry())&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] domSid = (&lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[])de.Properties[&lt;span style="color:#006080;"&gt;&amp;quot;objectSid&amp;quot;&lt;/span&gt;].Value;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; sdomainSid = sIDtoString(domSid);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    Console.WriteLine(sdomainSid);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;}   &lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Nota: Aqu&amp;iacute; necesitaremos dos funciones de apoyo, la primera nos devuelve el nombre del domino, y la segunda transforma el array de bits del SID en su representaci&amp;oacute;n textual:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; getDomainName()&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; IPGlobalProperties.GetIPGlobalProperties().DomainName;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; sIDtoString(&lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] sidBinary)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    SecurityIdentifier sid = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SecurityIdentifier(sidBinary, 0);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; sid.ToString();&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;A todo esto el valor de la variable &lt;strong&gt;sdomainSid&lt;/strong&gt; es el esperado!!! :-D&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;h4&gt;Poni&amp;eacute;ndolo todo junto&lt;/h4&gt;
&lt;p&gt;Al igual que &lt;a target="_blank" href="http://msmvps.com/blogs/jmtorres/default.aspx"&gt;el alegre bandolero&lt;/a&gt;, tambi&amp;eacute;n soy un fan&amp;aacute;tico de los m&amp;eacute;todos extensores, as&amp;iacute; que vamos a encapsular todo esto en un m&amp;eacute;todo que extienda la clase WindowsIdentity. Aqu&amp;iacute; va todo el c&amp;oacute;digo junto:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.DirectoryServices;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.DirectoryServices.ActiveDirectory;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Net.NetworkInformation;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; System.Security.Principal;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;namespace&lt;/span&gt; Alpha.Code&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SecurityExtensions&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; IsDomainAdmin (&lt;span style="color:#0000ff;"&gt;this&lt;/span&gt; WindowsIdentity identity)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            Domain d = Domain.GetDomain(&lt;span style="color:#0000ff;"&gt;new&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                DirectoryContext(DirectoryContextType.Domain, getDomainName()));&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; (DirectoryEntry de = d.GetDirectoryEntry())&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] bdomSid = (&lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[])de.Properties[&lt;span style="color:#006080;"&gt;&amp;quot;objectSid&amp;quot;&lt;/span&gt;].Value;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; sdomainSid = sIDtoString(bdomSid);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                WindowsPrincipal wp = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; WindowsPrincipal(identity);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                SecurityIdentifier dsid = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SecurityIdentifier(sdomainSid);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                SecurityIdentifier dasid = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SecurityIdentifier(&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    WellKnownSidType.AccountDomainAdminsSid, dsid);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; wp.IsInRole(dasid);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; getDomainName()&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; IPGlobalProperties.GetIPGlobalProperties().DomainName;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; sIDtoString(&lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] sidBinary)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            SecurityIdentifier sid = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SecurityIdentifier(sidBinary, 0);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; sid.ToString();&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Y la forma de usarlo es tan sencilla como esto:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (WindowsIdentity.GetCurrent().IsDomainAdmin())&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#008000;"&gt;//Acciones a realizar si el usuario es administrador de dominio... &lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Un saludo desde las fr&amp;iacute;as tierras de Andorra :-)&lt;/p&gt;
&lt;p&gt;Noviembre 2009&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1742245" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/LDAP/default.aspx">LDAP</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/HowTo/default.aspx">HowTo</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2009/default.aspx">2009</category></item><item><title>VS2010: Aleluya! Mejoras en Project –&gt; Refrences</title><link>http://msmvps.com/blogs/lfranco/archive/2009/10/29/vs2010-aleluya-mejoras-en-project-gt-refrences.aspx</link><pubDate>Thu, 29 Oct 2009 08:01:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1736060</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1736060</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/10/29/vs2010-aleluya-mejoras-en-project-gt-refrences.aspx#comments</comments><description>&lt;p&gt;Leo en el blog de &lt;a target="_blank" href="http://weblogs.asp.net/scottgu/default.aspx"&gt;Scott&lt;/a&gt;, que por fin alguien me ha hecho caso :-)&lt;/p&gt;
&lt;p align="justify"&gt;Ya en las betas de la versi&amp;oacute;n 2003 mand&amp;eacute; una petici&amp;oacute;n para que el cuadro de di&amp;aacute;logo de referencias se cargara de forma as&amp;iacute;ncrona, y desde entonces no se puede decir que me hubi&amp;eacute;sen hecho demasiado caso. La verdad es que tampoco creo que me lo hayan hecho ahora, pero al menos alguien debe haber llegado a la misma conclusi&amp;oacute;n: El cuadro de di&amp;aacute;logo de agregar referencias tardaba horrores en cargar. &lt;/p&gt;
&lt;p align="justify"&gt;La verdad es que es normal, ya que en la versi&amp;oacute;n 2008 todav&amp;iacute;a tenemos el mismo di&amp;aacute;logo que en Visual Studio 6.0, ya ha llovido un poco.&lt;/p&gt;
&lt;p align="justify"&gt;Ahora, a partir de la beta 2 de 2010, este cuadro de di&amp;aacute;logo se abre por defecto en la pesta&amp;ntilde;a &amp;lsquo;Projects&amp;rsquo; en lugar de mostrar las referencias de .NET, y esto es mucho m&amp;aacute;s r&amp;aacute;pido.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://www.uyssoft.com/blog/images/VS2010AleluyaMejorasenProjectRefrences_7E14/ref1.png"&gt;&lt;img height="412" width="486" src="http://www.uyssoft.com/blog/images/VS2010AleluyaMejorasenProjectRefrences_7E14/ref1_thumb.png" alt="ref1" border="0" title="ref1" style="border-right-width:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Pero eso no es todo, ahora en las dos primeras pesta&amp;ntilde;as, la carga de ensamblados se realiza ahora de forma as&amp;iacute;ncrona, de forma que no paraliza el IDE hasta que estan todos los ensamblados cargados en la lista.&lt;/p&gt;
&lt;p align="justify"&gt;Si, se que es una tonteria&amp;hellip; pero a veces estos peque&amp;ntilde;os cambios hacen que uno sea bastante m&amp;aacute;s productivo, o que al menos no se cabree con la herramienta cuando por error le das a esta ventana :-P&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://www.uyssoft.com/blog/images/VS2010AleluyaMejorasenProjectRefrences_7E14/ref2.png"&gt;&lt;img height="412" width="486" src="http://www.uyssoft.com/blog/images/VS2010AleluyaMejorasenProjectRefrences_7E14/ref2_thumb.png" alt="ref2" border="0" title="ref2" style="border-right-width:0px;display:inline;border-top-width:0px;border-bottom-width:0px;border-left-width:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Art&amp;iacute;culo original:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://weblogs.asp.net/scottgu/archive/2009/10/29/add-reference-dialog-improvements-vs-2010-and-net-4-0-series.aspx" title="http://weblogs.asp.net/scottgu/archive/2009/10/29/add-reference-dialog-improvements-vs-2010-and-net-4-0-series.aspx"&gt;http://weblogs.asp.net/scottgu/archive/2009/10/29/add-reference-dialog-improvements-vs-2010-and-net-4-0-series.aspx&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Saludos a todos!&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1736060" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Visual+Studio/default.aspx">Visual Studio</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2010/default.aspx">2010</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beta/default.aspx">Beta</category></item><item><title>El CodeCamp ha muerto… ¡viva el codeCamp!</title><link>http://msmvps.com/blogs/lfranco/archive/2009/10/20/el-codecamp-ha-muerto-161-viva-el-codecamp.aspx</link><pubDate>Tue, 20 Oct 2009 17:53:36 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1733697</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1733697</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/10/20/el-codecamp-ha-muerto-161-viva-el-codecamp.aspx#comments</comments><description>&lt;p&gt;Que nadie se asuste... :-)&lt;/p&gt;  &lt;p align="justify"&gt;...que aquí no se ha muerto nadie. Simplemente se ha terminado el &lt;a href="http://www.codecamp.es/" target="_blank"&gt;CodeCamp 2009&lt;/a&gt; y ya estamos pensando en el próximo: Dónde se va a celebrar? Cuándo lo va a hacer? Qué cosas podemos mejorar? Y en fin, todas esas cuestiones habituales.&lt;/p&gt;  &lt;p align="justify"&gt;Y el evento... ah, el evento... ha salido estupendamente! Puedo decir sin temor a equivocarme que ha sido el mejor CodeCamp hasta ahora, e incluso me atrevería a decir que ha sido mejor evento montado jamás por la comunidad (al menos el mejor que he visto jamás): El número de inscritos ha sobrepasado todas las previsiones, ya que en las primeras reuniones se hablaba de 100 personas y al final se registraron más de 300. El cartel de ponentes ha sido de auténtico lujo, tanto por parte de MSDN como de MONO, y en ocasiones ha sido bastante complicado decidir a qué sesión asistir. Y cómo no, el ambiente y el networking ha sido una auténtica pasada. Daba gusto estar cenando o tomando una copa con alguno de los gurús, o con varios de los estudiantes que vinieron al TTT y se quedaron el resto del fin de semana.&lt;/p&gt;  &lt;p align="justify"&gt;&amp;#160;&lt;img src="http://photos-a.ak.fbcdn.net/hphotos-ak-snc1/hs241.snc1/8835_1250762036283_1446455179_30701183_8116769_n.jpg" width="240" height="180" alt="" /&gt; &lt;img src="http://photos-f.ak.fbcdn.net/hphotos-ak-snc1/hs261.snc1/8835_1250762116285_1446455179_30701185_3232056_n.jpg" width="240" height="180" alt="" /&gt; &lt;/p&gt;  &lt;p align="justify"&gt;Evidentemente también hay varias cosas a mejorar, como algunos aspectos técnicos, la wifi, o el audio en el Webcast con &lt;a href="http://blogs.msdn.com/lisa/" target="_blank"&gt;Lisa Feigenbaum&lt;/a&gt;. Sin embargo, lo importante es que aunque ha sido un curro tremendo, el resultado compensa de sobras, y cuando Vicenç nos ha empezando a mandar algunas de las primeras impresiones no he podido evitar leerlas con una sonrisa de satisfacción en los labios. &lt;/p&gt;  &lt;p align="justify"&gt;&lt;img src="http://photos-a.ak.fbcdn.net/hphotos-ak-snc1/hs241.snc1/8835_1250762276289_1446455179_30701188_5755957_n.jpg" width="240" height="180" alt="" /&gt; &lt;img src="http://photos-b.ak.fbcdn.net/hphotos-ak-snc1/hs261.snc1/8835_1250762676299_1446455179_30701198_452995_n.jpg" width="240" height="180" alt="" /&gt; &lt;/p&gt;  &lt;p align="justify"&gt;Desde aquí agradecer los esfuerzos de todos los que han contribuido a este fin de semana, en el que no todo ha sido el CodeCamp. Ya arrancábamos el viernes con otro eventazo, el TTT o Train The Trainers, que Microsoft ha tenido a bien hacerlo coincidir con el CodeCamp, para que muchos de los ponentes e incluso asistentes no nos tuviéramos que desplazar. Por otro lado, mis agradecimientos a los sponsors, a los ponentes, a la organización (pedazo de curro os habéis pegado!), al hotel, a los asistentes, etc. &lt;/p&gt;  &lt;blockquote&gt;   &lt;p align="justify"&gt;&lt;strong&gt;GRACIAS A TODOS POR HABERLO HECHO POSIBLE!!!&lt;/strong&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p align="justify"&gt;&lt;img src="http://photos-d.ak.fbcdn.net/hphotos-ak-snc1/hs261.snc1/8835_1250762756301_1446455179_30701200_2723350_n.jpg" width="240" height="180" alt="" /&gt; &lt;img src="http://photos-g.ak.fbcdn.net/hphotos-ak-snc1/hs241.snc1/8835_1250762996307_1446455179_30701206_8256466_n.jpg" width="240" height="180" alt="" /&gt; &lt;/p&gt;  &lt;p align="justify"&gt;Ahora, a pensar en el próximo CodeCamp... bueno, tal vez dejemos pasar un par de semanas :-P&lt;/p&gt;  &lt;p align="justify"&gt;Por cierto, este fin de semana he conocido a mucha gente, y a muchos de vosotros os prometí contactar por FaceBook. Os dejo aquí el &lt;a href="http://www.facebook.com/lluis.franco" target="_blank"&gt;enlace a mi perfil&lt;/a&gt;, por si queréis agregarme a vuestra lista de amigos (agradecería que pusiérais una nota “CodeCamp” para saber de dónde habéis salido :-P).&lt;/p&gt;  &lt;p align="justify"&gt;PD – A ver si mañana puedo publicar sobre las cenas: “La cara oscura del CodeCamp: Sexo, Cerveza y Rock &amp;amp; Roll” :-D&lt;/p&gt;  &lt;p align="justify"&gt;Andorra, Octubre 2009&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1733697" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Tecnologia/default.aspx">Tecnologia</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Event/default.aspx">Event</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Grupo/default.aspx">Grupo</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2009/default.aspx">2009</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Felicidades/default.aspx">Felicidades</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/CodeCamp/default.aspx">CodeCamp</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Comunidad/default.aspx">Comunidad</category></item><item><title>CodeCamp – Extra, extra, última hora (WebCast Lisa)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/10/14/codecamp-extra-extra-250-ltima-hora-webcast-lisa.aspx</link><pubDate>Wed, 14 Oct 2009 14:21:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1732313</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1732313</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/10/14/codecamp-extra-extra-250-ltima-hora-webcast-lisa.aspx#comments</comments><description>&lt;p align="justify"&gt;Webcast online con Lisa Feigenbaum, Community Program Manager de VS - mi&amp;eacute;rcoles, 14 de octubre de 2009 a las 17:30.&lt;/p&gt;
&lt;p align="justify"&gt;Gracias al buen trabajo del colega &lt;a target="_blank" href="http://msmvps.com/blogs/peplluis/default.aspx"&gt;Pep Llu&amp;iacute;s&lt;/a&gt;, el s&amp;aacute;bado por la tarde vamos a tener la suerte de poder contar en directo (v&amp;iacute;a WebCast online) con &lt;strong&gt;&lt;a target="_blank" href="http://blogs.msdn.com/lisa/"&gt;Lisa Feigenbaum&lt;/a&gt; (Community Program Manager for Visual Studio Managed Languages)&lt;/strong&gt;. Lisa nos guiar&amp;aacute; a trav&amp;eacute;s de las novedades que la nueva versi&amp;oacute;n de Visual Basic nos va a traer.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/AgendaCodeCampLisa_5F00_66DDC6FE.png"&gt;&lt;img height="474" width="644" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/AgendaCodeCampLisa_5F00_thumb_5F00_23BC8B95.png" alt="CodeCamp Lisa" border="0" title="CodeCamp Lisa" style="display:inline;border-width:0px;border:0;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Si vas a estar por all&amp;iacute; no puedes perd&amp;eacute;rtelo, y si no vas a estar... &amp;iquest;a qu&amp;eacute; demonios est&amp;aacute;s esperando? :-)&lt;/p&gt;
&lt;p align="justify"&gt;Por cierto, en el &lt;a target="_blank" href="http://blogs.msdn.com/lisa/"&gt;nuevo blog de Lisa&lt;/a&gt; hoy aparece Pep, en una foto de la entrevista para &lt;a target="_blank" href="http://www.dotnetmania.com/Articulos/061/index.html"&gt;DotNetMania&lt;/a&gt; que le hicieron &amp;eacute;l y Octavio a Lisa el pasado verano.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/pep_5F00_lisa_5F00_271AD0E5.png"&gt;&lt;img height="244" width="242" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/pep_5F00_lisa_5F00_thumb_5F00_4F9B8203.png" alt="pep_lisa" border="0" title="pep_lisa" style="display:inline;border-width:0px;border:0;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;No os pod&amp;eacute;is imaginar que ganas tengo de que llegue el CodeCamp! :-D&lt;/p&gt;
&lt;p&gt;Saludos @Andorra&lt;/p&gt;
&lt;p&gt;L&lt;/p&gt;
&lt;p&gt;** crossposting desde el blog de Llu&amp;iacute;s Franco en geeks.ms **&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1732313" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/MVP/default.aspx">MVP</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Event/default.aspx">Event</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Entrevista/default.aspx">Entrevista</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2009/default.aspx">2009</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/noticia/default.aspx">noticia</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/CodeCamp/default.aspx">CodeCamp</category></item><item><title>MVP por séptimo año consecutivo! :-D</title><link>http://msmvps.com/blogs/lfranco/archive/2009/10/01/mvp-por-s-233-ptimo-a-241-o-consecutivo-d.aspx</link><pubDate>Thu, 01 Oct 2009 15:02:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1728766</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1728766</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/10/01/mvp-por-s-233-ptimo-a-241-o-consecutivo-d.aspx#comments</comments><description>&lt;p&gt;Oh! Que detalle m&amp;aacute;s bonito!&lt;/p&gt;
&lt;p&gt;Han querido hacerlo coincidir con el lanzamiento oficial de Windows 7 (supongo que adivin&amp;aacute;is porque se llama 7, no? :-P).&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/mvp_5F00_hor_5F00_4557EB3E.png"&gt;&lt;img height="94" width="227" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/mvp_5F00_hor_5F00_thumb_5F00_3D62D98D.png" alt="mvp_hor" border="0" title="mvp_hor" style="display:inline;border-width:0px;border:0;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Bromas aparte y como cada a&amp;ntilde;o que pasa, recibir esta notificaci&amp;oacute;n me produce una tremenda alegr&amp;iacute;a, no s&amp;oacute;lo por el reconocimiento que significa (y que no estoy muy seguro de merecer), sino porque me permite estar en contacto con un grupo de una tremenda calidad, tanto t&amp;eacute;cnica como humana. Esto es sin duda alguna lo mejor del programa MVP.&lt;/p&gt;
&lt;p align="justify"&gt;El programa MVP&amp;hellip; casi nada. Cada a&amp;ntilde;o Microsoft reconoce a un grupo de expertos independientes que han colaborado con la comunidad a nivel mundial. Ya sea contestando las preguntas de otros usuarios en los foros p&amp;uacute;blicos, posteando art&amp;iacute;culos en webs o blogs, organizando reuniones de grupos de usuarios o participando como ponente en diferentes sesiones. No es de extra&amp;ntilde;ar que cuando nos reunimos mire a mi alrededor y piense &amp;ldquo;jo, qu&amp;eacute; nivel! La de gente realmente buena que hay... no s&amp;eacute; exactamente que pinto yo aqu&amp;iacute;!&amp;rdquo;.&lt;/p&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/openday2005200510_5F00_3C8D0454.jpg"&gt;&lt;img height="184" width="244" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/openday2005200510_5F00_thumb_5F00_6DB16056.jpg" alt="openday20052005 (10)" border="0" title="openday20052005 (10)" style="display:inline;margin-left:0px;margin-right:0px;border:0;" /&gt;&lt;/a&gt; &lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/photo11_5F00_71BE3ED9.jpg"&gt;&lt;img height="184" width="244" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/photo11_5F00_thumb_5F00_5C65AAD3.jpg" alt="photo11" border="0" title="photo11" style="display:inline;border:0;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Todav&amp;iacute;a recuerdo mi primera incursi&amp;oacute;n en el programa &lt;a target="_blank" href="https://mvp.support.microsoft.com/"&gt;MVP&lt;/a&gt;. Fue en 2003, y estaba en Madrid a ra&amp;iacute;z de mi primera nominaci&amp;oacute;n como MVP y de un viaje por trabajo al SIMO. Yo llegu&amp;eacute; un mi&amp;eacute;rcoles y el viernes ten&amp;iacute;amos un Open Day en las instalaciones de Microsoft. Iba a ser mi primera visita a la compa&amp;ntilde;&amp;iacute;a, y la verdad es que no ten&amp;iacute;a ni idea de c&amp;oacute;mo iba a resultar... ni qu&amp;eacute; tipo de gente me iba a encontrar :-)&lt;/p&gt;
&lt;p align="justify"&gt;Despu&amp;eacute;s de visitar durante un par de d&amp;iacute;as un mont&amp;oacute;n de stands y de mantener algunas reuniones con proveedores en el SIMO, lleg&amp;oacute; el viernes y baj&amp;eacute; a desayunar al hotel, para despu&amp;eacute;s dirigirme al autocar que deb&amp;iacute;a llevarnos a las antiguas instalaciones de Microsoft. En aquellos momentos lo &amp;uacute;nico que sab&amp;iacute;a era que iba a conocer a un mont&amp;oacute;n de gente interesante, otros MVPs, empleados de MS, que obtendr&amp;iacute;a informaci&amp;oacute;n &amp;lsquo;privilegiada&amp;rsquo; de futuros productos y tendencias, y que por la noche tendr&amp;iacute;amos una cena, lo cual ya bastaba de sobras para justificar el viaje.&lt;/p&gt;
&lt;p align="justify"&gt;Como no conoc&amp;iacute;a a nadie, ni sab&amp;iacute;a de qu&amp;eacute; iba el tema sal&amp;iacute; con el mismo uniforme que los dos d&amp;iacute;as anteriores, es decir, con traje y corbata (sip, soy de esos t&amp;iacute;os a los que deben ir a trabajar de esta guisa, y al final te acostumbras :-P). Pues no os pod&amp;eacute;is imaginar el cachondeito que hubo en el autocar! De hecho, con los a&amp;ntilde;os mi prima Evas, ex-MVP, llego a contarme que otros MVPs se pensaron que yo era alg&amp;uacute;n cargo de Microsoft que aprovechaba el viaje, jejeje... Nada m&amp;aacute;s lejos, y nada m&amp;aacute;s iniciar el viaje y empezar a charlar ya me di cuenta (demasiado tarde) de mi error, pero ya estaba hecho, as&amp;iacute; que tuve que apechugar todo el d&amp;iacute;a con la corbata como un campe&amp;oacute;n. &lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/openday200520053_5F00_2B65FA26.jpg"&gt;&lt;img height="184" width="244" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/openday200520053_5F00_thumb_5F00_438E85E3.jpg" alt="openday20052005 (3)" border="0" title="openday20052005 (3)" style="display:inline;border:0;" /&gt;&lt;/a&gt; &lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/openday200520052_5F00_7C3BC0A1.jpg"&gt;&lt;img height="184" width="244" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/openday200520052_5F00_thumb_5F00_58A4B3AB.jpg" alt="openday20052005 (2)" border="0" title="openday20052005 (2)" style="display:inline;border:0;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Aquel mismo d&amp;iacute;a conoc&amp;iacute; a muchos compa&amp;ntilde;eros MVP que a d&amp;iacute;a de hoy son muy buenos amigos, y a algunos de ellos que ya no lo son, pero contin&amp;uacute;an siendo muy buenos amigos. Si un d&amp;iacute;a tengo tiempo y me siento inspirado os contar&amp;eacute; algunas aventuras que hemos compartido a lo largo de los a&amp;ntilde;os...&lt;/p&gt;
&lt;p align="justify"&gt;Un abrazo enorme a todos, los que son, los que no, y en general a todos aquellos que dedican su tiempo a hacer m&amp;aacute;s grande la comunidad. Todos son MVP, tengan o no tengan la distinci&amp;oacute;n. Entre todos estamos contribuyendo a hacer algo grande.&lt;/p&gt;
&lt;p align="justify"&gt;Nos vemos en las comunidades, eventos, charlas de grupos, etc.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p align="justify"&gt;Llu&amp;iacute;s Franco&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p align="justify"&gt;Octubre 2009&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;PD &amp;ndash; Acabo de encontrarme con unas viejas fotos de pasados MVP Open Days, las colgar&amp;eacute; en FaceBook en breve :-D&lt;/p&gt;
&lt;p&gt;** crossposting desde el blog de Llu&amp;iacute;s Franco en geeks.ms **&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1728766" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/MVP/default.aspx">MVP</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2009/default.aspx">2009</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Award/default.aspx">Award</category></item><item><title>El CodeCamp 2009 se acerca…</title><link>http://msmvps.com/blogs/lfranco/archive/2009/09/21/el-codecamp-2009-se-acerca.aspx</link><pubDate>Mon, 21 Sep 2009 12:36:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1725428</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1725428</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/09/21/el-codecamp-2009-se-acerca.aspx#comments</comments><description>&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/banner3_5F00_5B557B29.png"&gt;&lt;img height="77" width="500" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/banner3_5F00_5B557B29.png" alt="banner3" border="0" title="banner3" style="display:block;margin-left:NaNpx;margin-right:NaNpx;border:0;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Hola a todos,&lt;/p&gt;
&lt;p align="justify"&gt;Ya queda menos de un mes para uno de los eventos m&amp;aacute;s esperados de este a&amp;ntilde;o: el &lt;a target="_blank" href="http://www.codecamp.es/"&gt;CodeCamp 2009&lt;/a&gt;. Este evento ha sido organizado por varios grupos de usuarios de Espa&amp;ntilde;a y del extranjero (&lt;a target="_blank" href="http://andorradotnet.com/"&gt;Andorra&lt;/a&gt; tambi&amp;eacute;n existe!), y se realizar&amp;aacute; en Salou (Tarragona), durante el fin de semana del 17 y 18 de Octubre.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p align="justify"&gt;El &lt;strong&gt;CodeCamp Tarragona 2009 &lt;/strong&gt;es un evento &lt;strong&gt;gratuito &lt;/strong&gt;organizado por y para la comunidad de .NET, cuyo objetivo es reunir a profesionales, usuarios y entusiastas interesados en la &lt;strong&gt;plataforma .NET &lt;/strong&gt;y &lt;strong&gt;Mono &lt;/strong&gt;para intercambiar experiencias y asistir a un conjunto de ponencias realizadas por especialistas de reconocido prestigio.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p align="justify"&gt;El Code Camp estar&amp;aacute; compuesto por una serie de sesiones divididas en varios tracks. Las sesiones abarcar&amp;aacute;n presentaciones, charlas informales y sesiones pr&amp;aacute;cticas. Est&amp;aacute;is todos invitados a asistir, hablar y participar.&lt;/p&gt;
&lt;p align="justify"&gt;Tendremos una mezcla de ponentes, desde MVPs, directores, autores y, los m&amp;aacute;s importante, desarrolladores como t&amp;uacute;, ya que nos interesa tratar temas y problemas reales a los que los profesionales se enfrentan en el trabajo diario.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p align="justify"&gt;En esta ocasi&amp;oacute;n, voy a participar como ponente en uno de los tracks, conjuntamente con mis buenos amigos &lt;a target="_blank" href="http://msmvps.com/blogs/jorge/"&gt;Jorge Serrano&lt;/a&gt; y &lt;a target="_blank" href="http://msmvps.com/blogs/peplluis/default.aspx"&gt;Pep Llu&amp;iacute;s Bano&lt;/a&gt;. De modo que si te quieres divertir y estar al loro de las &amp;uacute;ltimas novedades de VB2010 p&amp;aacute;sate por all&amp;iacute; y hablamos un rato.&lt;/p&gt;
&lt;p align="justify"&gt;M&amp;aacute;s informaci&amp;oacute;n en:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://www.codecamp.es/" title="http://www.codecamp.es/"&gt;http://www.codecamp.es/&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/sticker3_5F00_1CF24827.png"&gt;&lt;img height="65" width="112" src="http://geeks.ms/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/sticker3_5F00_1CF24827.png" alt="sticker3" border="0" title="sticker3" style="display:inline;border:0;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;PD &amp;ndash; El d&amp;iacute;a anterior celebraremos el TTT (Train the trainers), de modo que si vas a ir nos vemos all&amp;iacute; :-)&lt;/p&gt;
&lt;p&gt;** crossposting desde el blog de Llu&amp;iacute;s Franco en geeks.ms **&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1725428" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VB/default.aspx">VB</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Visual+Studio/default.aspx">Visual Studio</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Event/default.aspx">Event</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2009/default.aspx">2009</category></item><item><title>Haciendo prototipos con SketchFlow</title><link>http://msmvps.com/blogs/lfranco/archive/2009/04/27/haciendo-prototipos-con-sketchflow.aspx</link><pubDate>Mon, 27 Apr 2009 09:07:02 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1691372</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1691372</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/04/27/haciendo-prototipos-con-sketchflow.aspx#comments</comments><description>&lt;p align="justify"&gt;Según leo esta mañana en el blog de &lt;a href="http://blogs.msdn.com/somasegar/default.aspx"&gt;Somasegar&lt;/a&gt;, existe un nuevo conjunto de herramientas muy chulo para Expression Blend 3 llamado SketchFlow, pensado para la realización de prototipos en las primeras etapas del diseño de software.&lt;/p&gt;  &lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/HaciendoprototiposconSketchFlow_8DF2/proto1.png"&gt;&lt;img style="border-bottom:0px;border-left:0px;display:inline;border-top:0px;border-right:0px;" title="proto1" border="0" alt="proto1" src="http://blogimages.uyssoft.com/HaciendoprototiposconSketchFlow_8DF2/proto1_thumb.png" width="557" height="421" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p align="justify"&gt;Con SketchFlow podemos:&lt;/p&gt;  &lt;p align="justify"&gt;a) Esbozar las ideas    &lt;br /&gt;b) Convertir esas ideas en prototipos de trabajo.     &lt;br /&gt;c) Presentar y compartir estas experiencias de usuario interactivo mediante el SketchFlow player.&lt;/p&gt;  &lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/HaciendoprototiposconSketchFlow_8DF2/proto2.png"&gt;&lt;img style="border-bottom:0px;border-left:0px;display:inline;border-top:0px;border-right:0px;" title="proto2" border="0" alt="proto2" src="http://blogimages.uyssoft.com/HaciendoprototiposconSketchFlow_8DF2/proto2_thumb.png" width="553" height="241" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p align="justify"&gt;Darle un vistazo al artículo original que vale la pena:&lt;/p&gt;  &lt;p align="justify"&gt;&lt;a title="http://blogs.msdn.com/somasegar/archive/2009/04/25/prototyping-with-sketchflow.aspx" href="http://blogs.msdn.com/somasegar/archive/2009/04/25/prototyping-with-sketchflow.aspx"&gt;http://blogs.msdn.com/somasegar/archive/2009/04/25/prototyping-with-sketchflow.aspx&lt;/a&gt;&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1691372" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Expression/default.aspx">Expression</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Design/default.aspx">Design</category></item><item><title>Google Chrome usa ClickOnce :-)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/04/06/google-chrome-usa-clickonce.aspx</link><pubDate>Mon, 06 Apr 2009 11:02:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1685032</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1685032</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/04/06/google-chrome-usa-clickonce.aspx#comments</comments><description>&lt;p align="justify"&gt;Pues eso. Tal vez muchos de vosotros ya lo sab&amp;iacute;ais pero esta ma&amp;ntilde;ana me he quedado de piedra al comprobar que la instalaci&amp;oacute;n de Google Chrome se realiza mediante la tecnolog&amp;iacute;a &lt;a target="_blank" href="http://msdn.microsoft.com/es-es/library/wh45kb66.aspx"&gt;ClickOnce&lt;/a&gt; de Microsoft. Curioso verdad? Para muestra un bot&amp;oacute;n:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/GoogleChromeusaClickOnce_9B10/Chrome_Clickonce1.png"&gt;&lt;img height="150" width="386" src="http://blogimages.uyssoft.com/GoogleChromeusaClickOnce_9B10/Chrome_Clickonce1_thumb.png" alt="Chrome_Clickonce1" border="0" title="Chrome_Clickonce1" style="border-bottom:0px;border-left:0px;display:inline;border-top:0px;border-right:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/GoogleChromeusaClickOnce_9B10/Chrome_Clickonce2.png"&gt;&lt;img height="295" width="520" src="http://blogimages.uyssoft.com/GoogleChromeusaClickOnce_9B10/Chrome_Clickonce2_thumb.png" alt="Chrome_Clickonce2" border="0" title="Chrome_Clickonce2" style="border-bottom:0px;border-left:0px;display:inline;border-top:0px;border-right:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Si lo piensas es normal, ya que el c&amp;oacute;digo del producto para Windows no deja de ser una soluci&amp;oacute;n de Visual Studio 2005 (15 proyectos si no recuerdo mal), de modo que es relativamente normal que se hayan aprovechado de una tecnolog&amp;iacute;a tan *cojonuda* (y perd&amp;oacute;n por la expresi&amp;oacute;n) com es &lt;a href="http://msdn.microsoft.com/es-es/library/wh45kb66.aspx"&gt;ClickOnce&lt;/a&gt; para el despliegue de aplicaciones.&lt;/p&gt;
&lt;p align="justify"&gt;Lo que no deja de ser gracioso es que de momento Chrome no tenga versiones estables para Mac ni para Linux (de hecho &lt;a href="http://dev.chromium.org/developers/how-tos/build-instructions-os-x"&gt;seg&amp;uacute;n los mismos desarrolladores&lt;/a&gt; &amp;quot;Esta mas cerca del comienzo que del fin&amp;quot;), y la &amp;uacute;nica versi&amp;oacute;n que funciona m&amp;aacute;s o menos bien est&amp;eacute; desarrollada con la herramienta de desarrollo m&amp;aacute;s popular de la competencia :-P&lt;/p&gt;
&lt;p align="justify"&gt;En fin, como dije antes&amp;hellip; curioso, verdad?&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1685032" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/General/default.aspx">General</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Tecnologia/default.aspx">Tecnologia</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Frikadas/default.aspx">Frikadas</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Visual+Studio/default.aspx">Visual Studio</category></item><item><title>ClickOnce, actualizar una aplicación ‘on demand’</title><link>http://msmvps.com/blogs/lfranco/archive/2009/04/02/clickonce-actualizar-una-aplicaci-243-n-on-demand.aspx</link><pubDate>Thu, 02 Apr 2009 15:47:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1684186</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1684186</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/04/02/clickonce-actualizar-una-aplicaci-243-n-on-demand.aspx#comments</comments><description>&lt;p align="justify"&gt;Una de las grandes caracter&amp;iacute;sticas disponibles a partir de VS2005 fue la tecnolog&amp;iacute;a &lt;a target="_blank" href="http://msdn.microsoft.com/es-es/library/wh45kb66.aspx"&gt;ClickOnce&lt;/a&gt;, que permit&amp;iacute;a distribuir aplicaciones de forma asombrosamente sencilla. Hoy no nos vamos a dedicar a explicar con detalle esta tecnolog&amp;iacute;a (supongo que muchos de vosotros ya la estar&amp;eacute;is utilizando), si no que nos vamos a centrar en extender su funcionalidad para comprobar por c&amp;oacute;digo si existen nuevas versiones publicadas, y en caso afirmativo actualizar la misma.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/ClickOnceactualizarunaaplicacinondemand_DE24/ClickOnceAPI.png"&gt;&lt;img height="288" width="462" src="http://blogimages.uyssoft.com/ClickOnceactualizarunaaplicacinondemand_DE24/ClickOnceAPI_thumb.png" alt="ClickOnceAPI" border="0" title="ClickOnceAPI" style="border-bottom:0px;border-left:0px;display:inline;border-top:0px;border-right:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;La verdad es que utilizar la API de ClickOnce est&amp;aacute; tirado, y nos permite hacer cosas tan chulas como esta:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/ClickOnceactualizarunaaplicacinondemand_DE24/UpdateAvailable.png"&gt;&lt;img height="130" width="573" src="http://blogimages.uyssoft.com/ClickOnceactualizarunaaplicacinondemand_DE24/UpdateAvailable_thumb.png" alt="UpdateAvailable" border="0" title="UpdateAvailable" style="border-bottom:0px;border-left:0px;display:inline;border-top:0px;border-right:0px;" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;El c&amp;oacute;digo para comprobar si existen actualizaciones es el siguiente:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;private&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; InstallUpdateSyncWithInfo()&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    UpdateCheckInfo info = &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (ApplicationDeployment.IsNetworkDeployed)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        ApplicationDeployment ad = ApplicationDeployment.CurrentDeployment;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            info = ad.CheckForDetailedUpdate();&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (DeploymentDownloadException dde)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            MessageBox.Show(String.Format(&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.CLICKONCE_CANT_DOWNLOAD_UPDATE, &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                dde.Message, MessageBoxButtons.OK,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                MessageBoxIcon.Exclamation));&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (InvalidDeploymentException ide)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            MessageBox.Show(String.Format(&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.CLICKONCE_CORRUPT_DEPLOYMENT, &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                ide.Message, MessageBoxButtons.OK,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                MessageBoxIcon.Exclamation));&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (InvalidOperationException ioe)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            MessageBox.Show(String.Format(&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.CLICKONCE_NO_CLICKONCE_DEPLOYMENT, &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                ioe.Message, MessageBoxButtons.OK,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                MessageBoxIcon.Exclamation));&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (info.UpdateAvailable)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            Boolean doUpdate = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!info.IsUpdateRequired)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                DialogResult dr = MessageBox.Show(&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(Properties.Settings.Default.CLICKONCE_UPDATE_AVAILABLE, &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    info.AvailableVersion.ToString()),&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    Application.ProductName, MessageBoxButtons.OKCancel,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    MessageBoxIcon.Information);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!(DialogResult.OK == dr))&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    doUpdate = &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;else&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                MessageBox.Show(&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    String.Format(Properties.Settings.Default.CLICKONCE_MANDATORY_UPDATE,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    info.MinimumRequiredVersion.ToString(),&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    ApplicationDeployment.CurrentDeployment.CurrentVersion.ToString()),&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    Application.ProductName, MessageBoxButtons.OK,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    MessageBoxIcon.Information);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (doUpdate)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    ad.Update();&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    MessageBox.Show(Properties.Settings.Default.CLICKONCE_UPDATE_SUCCESSFULLY,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                        Application.ProductName, MessageBoxButtons.OK,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                        MessageBoxIcon.Information);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    Application.Restart();&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (DeploymentDownloadException dde)&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    MessageBox.Show(String.Format(&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                        Properties.Settings.Default.CLICKONCE_CANT_INSTALL_UPDATE, &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                        dde.Message, MessageBoxButtons.OK,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                        MessageBoxIcon.Exclamation));&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;else&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;            MessageBox.Show(Properties.Settings.Default.CLICKONCE_NO_UPDATES_AVAILABLES,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                Application.ProductName, MessageBoxButtons.OK,&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;                MessageBoxIcon.Information);&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Basta acompa&amp;ntilde;ar este c&amp;oacute;digo con unas constantes definidas en los settings de nuestra aplicaci&amp;oacute;n y voil&amp;aacute;! &lt;/p&gt;
&lt;p align="justify"&gt;A continuaci&amp;oacute;n os muestro un ejemplo del fichero de settings por si alguno se lo quiere personalizar:&lt;/p&gt;
&lt;div&gt;
&lt;div style="line-height:12pt;background-color:#f4f4f4;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;&amp;lt;?&lt;/span&gt;&lt;span style="color:#800000;"&gt;xml&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;version&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;#39;1.0&amp;#39;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;encoding&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;#39;utf-8&amp;#39;&lt;/span&gt;?&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;SettingsFile&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;xmlns&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;http://schemas.microsoft.com/VisualStudio/2004/01/settings&amp;quot;&lt;/span&gt; &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;  &lt;span style="color:#ff0000;"&gt;CurrentProfile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;GeneratedClassNamespace&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;TestClickOnceDeployment.Properties&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;GeneratedClassName&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Settings&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;  &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Profiles&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;  &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Settings&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_CANT_DOWNLOAD_UPDATE&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      La nueva versi&amp;oacute;n de la aplicaci&amp;oacute;n no puede ser descargada en estos momentos.\n\&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      Por favor, revise la connexi&amp;oacute;n de red o pru&amp;eacute;belo un poco m&amp;aacute;s tarde. Error: {0}&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_CORRUPT_DEPLOYMENT&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      No se puede verificar la nueva versi&amp;oacute;n de la aplicaci&amp;oacute;n. La publicaci&amp;oacute;n ClickOnce est&amp;aacute; corrupta. &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      Por favor, redistribuya de nuevo la aplicaci&amp;oacute;n i pru&amp;eacute;belo un poco m&amp;aacute;s tarde. Error: {0}&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_NO_CLICKONCE_DEPLOYMENT&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      La aplicaci&amp;oacute;n no se puede actualizar. Parece ser que la publicaci&amp;oacute;n no es una aplicaci&amp;oacute;n ClickOnce v&amp;aacute;lida. Error: {0}&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_UPDATE_AVAILABLE&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      Se ha encontrado disponible una actualizaci&amp;oacute;n. Desea actualitzar la aplicaci&amp;oacute;n a la versi&amp;oacute;n &amp;#39;{0}&amp;#39;?&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_MANDATORY_UPDATE&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      Esta aplicaci&amp;oacute;n ha detectado que la versi&amp;oacute;n m&amp;iacute;nima de l&amp;#39;aplicaci&amp;oacute; es la versi&amp;oacute;n &amp;#39;{0}&amp;#39;, &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      i actualmente se est&amp;aacute; utilizando la versi&amp;oacute;n &amp;#39;{1}&amp;#39;. &lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      A continuaci&amp;oacute;n la aplicaci&amp;oacute;n se actualitzar&amp;aacute; y reiniciar&amp;aacute;.&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_UPDATE_SUCCESSFULLY&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      La aplicaci&amp;oacute;n se ha actualitzado correctamente, y a continuaci&amp;oacute;n se reiniciar&amp;aacute;.&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_CANT_INSTALL_UPDATE&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      La nueva versi&amp;oacute;n de la aplicaci&amp;oacute;n no se puede instalar en estos momentos.\n\n&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      Por favor, revise la connexi&amp;oacute;n de red o pru&amp;eacute;belo un poco m&amp;aacute;s tarde. Error: {0}&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Name&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;CLICKONCE_NO_UPDATES_AVAILABLES&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Type&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;System.String&amp;quot;&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Scope&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;Application&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;      &lt;span style="color:#0000ff;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt; &lt;span style="color:#ff0000;"&gt;Profile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;=&amp;quot;(Default)&amp;quot;&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;No se han encontrado actualitzacions disponibles de la aplicaci&amp;oacute;n.&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Value&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Setting&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:#f4f4f4;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;  &lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;Settings&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="line-height:12pt;background-color:white;margin:0em;width:100%;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;color:black;font-size:8pt;overflow:visible;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color:#800000;"&gt;SettingsFile&lt;/span&gt;&lt;span style="color:#0000ff;"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Y eso es todo&amp;hellip; Un saludo desde Andorra!&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1684186" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/API/default.aspx">API</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Tip/default.aspx">Tip</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/ClickOnce/default.aspx">ClickOnce</category></item><item><title>SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (VII)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/03/20/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-vii.aspx</link><pubDate>Fri, 20 Mar 2009 08:07:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1679840</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1679840</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/03/20/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-vii.aspx#comments</comments><description>&lt;p align="justify"&gt;Entradas anteriores de la serie:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (I)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-ii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (II)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (III)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iv.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (IV)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-v.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (V)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-vi.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (VI)&lt;/a&gt;&lt;/p&gt;
&lt;div align="justify"&gt;
&lt;hr /&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_C4F0/bender3.jpg"&gt;&lt;img border="0" width="244" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_C4F0/bender3_thumb.jpg" alt="bender3" height="182" title="bender3" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Han pasado unos d&amp;iacute;as desde que publiqu&amp;eacute; la &amp;uacute;ltima entrada, y es que voy absolutamente desbordado de curro.&lt;/p&gt;
&lt;p align="justify"&gt;Pero como lo prometido es deuda, vamos a proseguir con el tema, ya quedan un par de temas por ver antes de concluir la serie:&lt;/p&gt;
&lt;li&gt;
&lt;p align="justify"&gt;C&amp;oacute;mo ejecutar distintos threads y mostrar el progreso (&lt;strong&gt;Callbacks&lt;/strong&gt;). &lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p align="justify"&gt;C&amp;oacute;mo distribuir nuestro complemento, creando un archivo MSI (&lt;strong&gt;Windows Installer packages&lt;/strong&gt;).&lt;/p&gt;
&lt;/li&gt;
&lt;p align="justify"&gt;Adem&amp;aacute;s, os dije que en el &amp;uacute;ltimo post publicar&amp;iacute;a el c&amp;oacute;digo fuente del proyecto&amp;hellip; y varios de vosotros ya lo hab&amp;eacute;is reclamado con insistencia :-P&lt;/p&gt;
&lt;p align="justify"&gt;De modo que vamos a hacerlo al rev&amp;eacute;s: Hoy publico el c&amp;oacute;digo fuente del proyecto, y ma&amp;ntilde;ana (espero) continuar&amp;eacute; el resto de la serie. De este modo al menos ya tendreis el c&amp;oacute;digo para jugar con &amp;eacute;l, y poder machacarme a preguntas&amp;hellip;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_7F07/ProjectExplorer.png"&gt;&lt;img border="0" width="328" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_7F07/ProjectExplorer_thumb.png" alt="ProjectExplorer" height="421" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="ProjectExplorer" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;El proyecto incluye el c&amp;oacute;digo de ejemplo del Add-In y el proyecto de instalaci&amp;oacute;n, y lo pod&amp;eacute;is descargar desde este enlace de Skydrive:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://cid-f3a970280830b5fe.skydrive.live.com/self.aspx/MSDN%20Samples/OutlookToMOSS/OutlookToMOSS.zip" title="http://cid-f3a970280830b5fe.skydrive.live.com/self.aspx/MSDN%20Samples/OutlookToMOSS/OutlookToMOSS.zip"&gt;http://cid-f3a970280830b5fe.skydrive.live.com/self.aspx/MSDN%20Samples/OutlookToMOSS/OutlookToMOSS.zip&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Saludos desde Andorra,&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1679840" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Sharepoint/default.aspx">Sharepoint</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Utilidad/default.aspx">Utilidad</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Ejemplo/default.aspx">Ejemplo</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Serie/default.aspx">Serie</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/HowTo/default.aspx">HowTo</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beerware/default.aspx">Beerware</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Add-In/default.aspx">Add-In</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VSTO/default.aspx">VSTO</category></item><item><title>SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (VI)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/03/05/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-vi.aspx</link><pubDate>Thu, 05 Mar 2009 14:57:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1675827</guid><dc:creator>lfranco</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1675827</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/03/05/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-vi.aspx#comments</comments><description>&lt;h4 align="justify"&gt;Entradas anteriores de la serie:&lt;/h4&gt;
&lt;p align="justify"&gt;&lt;a target="_blank" href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (I)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a target="_blank" href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-ii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (II)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a target="_blank" href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (III)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a target="_blank" href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iv.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (IV)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a target="_blank" href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-v.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (V)&lt;/a&gt;&lt;/p&gt;
&lt;div align="justify"&gt;
&lt;hr /&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_C4F0/bender3.jpg"&gt;&lt;img border="0" width="244" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_C4F0/bender3_thumb.jpg" alt="bender3" height="182" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="bender3" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Ahora que parece que &lt;a target="_blank" href="http://en.wikipedia.org/wiki/Bender_(Futurama)"&gt;Bender&lt;/a&gt; est&amp;aacute; un poco m&amp;aacute;s sobrio que de costumbre, prosigamos con la serie... que sab&amp;eacute;is como se pone cuando no bebe.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Men&amp;uacute; del d&amp;iacute;a:&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;span style="text-decoration:underline;"&gt;De primero:&lt;/span&gt; C&amp;oacute;mo guardar un fichero en una biblioteca de documentos de SharePoint manteniendo el control de versiones.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;span style="text-decoration:underline;"&gt;De segundo:&lt;/span&gt; C&amp;oacute;mo modificar los metadatos del fichero una vez subido a la biblioteca (From, To, Subject).&lt;/p&gt;
&lt;p align="justify"&gt;&lt;span style="text-decoration:underline;"&gt;Postre:&lt;/span&gt; Pastel especial de la casa.&lt;/p&gt;
&lt;p align="justify"&gt;Pan, Vino y Caf&amp;eacute; incluidos&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;El primero:&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Es curioso, pero SharePoint en la versi&amp;oacute;n actual no implementa &amp;ldquo;de serie&amp;rdquo; ning&amp;uacute;n mecanismo para subir documentos a una librer&amp;iacute;a de documentos. Ahora que nos hemos quedado con la boca abierta, vamos a explicar algunos mecanismos para hacerlo por nuestra cuenta.&lt;/p&gt;
&lt;p align="justify"&gt;El bueno de mi t&amp;iacute;o &lt;a target="_blank" href="http://msmvps.com/blogs/rcorral/"&gt;Rodrigo&lt;/a&gt; hace un tiempo que public&amp;oacute; un post al respecto, en el cual se mostraba c&amp;oacute;mo &lt;a target="_blank" href="http://msmvps.com/blogs/rcorral/archive/2006/10/08/Subir-achivos-a-Sharepoint-desde-un-programa-en-un-equipo-remoto.aspx"&gt;subir ficheros a un SharePoint&lt;/a&gt;. Pero como &amp;eacute;l mismo dec&amp;iacute;a, la pega estaba en que usando esta t&amp;eacute;cnica no se dispon&amp;iacute;a de historial de versiones. La alternativa era crearse un WebService propio, tal y como se explica en &lt;a target="_blank" href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/odc_sp2003_ta/html/odc_writingcustomwebservicesforsppt.asp"&gt;este art&amp;iacute;culo&lt;/a&gt;, aunque es una soluci&amp;oacute;n que no siempre se puede usar. Hoy veremos una tercera alternativa que permite hacerlo sin tener que recurrir a la creaci&amp;oacute;n de un WebService. La he probado en un servidor MOSS y en un par de WSS, uno local y el otro hospedado en un hosting en USA. Y en ambos funciona perfectamente, aunque en el segundo los tiempos se demoran un poco... &lt;/p&gt;
&lt;p align="justify"&gt;Describamos los elementos que necesitamos a continuaci&amp;oacute;n:&lt;/p&gt;
&lt;p align="justify"&gt;Para empezar vamos a crear una clase &lt;strong&gt;FileInfo&lt;/strong&gt; para encapsular lo relativo al fichero que vamos a subir (nombre, propiedades, URI, y por supuesto los bytes):&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; FileInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; m_URL;            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] m_bytes;            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; Dictionary&amp;lt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;, &lt;span style="color:#0000ff;"&gt;object&lt;/span&gt;&amp;gt; m_properties;            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; ListInfo m_listInfo;            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; m_ensureFolders = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;private&lt;/span&gt; Uri m_uri;    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; HasProperties            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {                &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        get &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        { &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; m_properties != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; m_properties.Count &amp;gt; 0; &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; RelativeFilePath            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {                &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        get &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        { &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; m_URL.Substring(m_URL.IndexOf(m_listInfo.m_rootFolder) + 1); &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }          &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; Uri URI      &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {               &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        get                &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {                    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (m_uri == &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;) m_uri = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; Uri(m_URL);                    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; m_uri;                &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; LookupName            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {                &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        get  &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {                    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (m_listInfo != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; !&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.IsNullOrEmpty(m_listInfo.m_listName))   &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; m_listInfo.m_listName;      &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; URI.LocalPath;           &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; FileInfo(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; url, &lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] bytes, Dictionary&amp;lt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;, &lt;span style="color:#0000ff;"&gt;object&lt;/span&gt;&amp;gt; properties)    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {                &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        m_URL = url.Replace(&lt;span style="color:#006080;"&gt;&amp;quot;%20&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot; &amp;quot;&lt;/span&gt;);     &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        m_bytes = bytes;               &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        m_properties = properties;     &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }                    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;A continuaci&amp;oacute;n un m&amp;eacute;todo &lt;strong&gt;Upload&lt;/strong&gt; con dos sobrecargas, que ser&amp;aacute; el que invocaremos desde la ventana encargada de mostrar el progreso de la operaci&amp;oacute;n. &amp;Eacute;ste ser&amp;aacute; el encargado de recibir la URL de destino, los bytes del fichero a subir (previamente debemos guardar el elemento de correo en un fichero o stream), las propiedades, y el elemento de correo para poder actualizar las columnas de metadatos. Este m&amp;eacute;todo &lt;strong&gt;Upload&lt;/strong&gt; ser&amp;aacute; el encargado de a su vez llamar al m&amp;eacute;todo &lt;strong&gt;TryToUpload&lt;/strong&gt;, que realmente ser&amp;aacute; el encargado de subir el fichero:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; Upload(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; destinationUrl, &lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] bytes, Dictionary&amp;lt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;, &lt;span style="color:#0000ff;"&gt;object&lt;/span&gt;&amp;gt; properties, Outlook.MailItem item) &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; Upload(&lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; FileInfo(destinationUrl, bytes, properties), item);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; Upload(FileInfo fileInfo, Outlook.MailItem item)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (fileInfo.HasProperties)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        fileInfo.m_listInfo = m_lists.Find(fileInfo);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; result = TryToUpload(fileInfo, item);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!result &amp;amp;&amp;amp; fileInfo.m_ensureFolders)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; root = fileInfo.URI.AbsoluteUri.Replace(fileInfo.URI.AbsolutePath, &lt;span style="color:#006080;"&gt;&amp;quot;&amp;quot;&lt;/span&gt;);  &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;for&lt;/span&gt; (&lt;span style="color:#0000ff;"&gt;int&lt;/span&gt; i = 0; i &amp;lt; fileInfo.URI.Segments.Length - 1; i++)     &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            root += fileInfo.URI.Segments;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (i &amp;gt; 1) CreateFolder(root);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        result = TryToUpload(fileInfo, item);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; result;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Y para terminar, el m&amp;eacute;todo &lt;strong&gt;TryToUpload&lt;/strong&gt; que se encarga de crear el objeto &lt;strong&gt;WebRequest&lt;/strong&gt; necesario, crear el stream y actualizar los valores de las propiedades de los campos, para invocar finalmente el m&amp;eacute;todo &lt;strong&gt;UpdateListItems&lt;/strong&gt; del servicio Web:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;private&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; TryToUpload(FileInfo fileInfo, Outlook.MailItem item)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        WebRequest request = WebRequest.Create(fileInfo.m_URL);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        request.Credentials = sharePointLists.Credentials;  &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        request.Method = &lt;span style="color:#006080;"&gt;&amp;quot;PUT&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[] buffer = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;byte&lt;/span&gt;[1024];&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; (Stream stream = request.GetRequestStream())&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; (MemoryStream ms = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; MemoryStream(fileInfo.m_bytes))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;for&lt;/span&gt; (&lt;span style="color:#0000ff;"&gt;int&lt;/span&gt; i = ms.Read(buffer, 0, buffer.Length); i &amp;gt; 0; i = ms.Read(buffer, 0, buffer.Length))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                stream.Write(buffer, 0, i);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        WebResponse response = request.GetResponse();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        response.Close();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (fileInfo.HasProperties)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            StringBuilder sb = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; StringBuilder();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            sb.Append(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Method ID=&amp;#39;1&amp;#39; Cmd=&amp;#39;Update&amp;#39;&amp;gt;&amp;lt;Field Name=&amp;#39;ID&amp;#39;/&amp;gt;&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;FileRef&amp;#39;&amp;gt;{0}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;, fileInfo.m_URL);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;foreach&lt;/span&gt; (KeyValuePair&amp;lt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;, &lt;span style="color:#0000ff;"&gt;object&lt;/span&gt;&amp;gt; property &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; fileInfo.m_properties)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;, property.Key, property.Value);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            updateMetadataColumns(fileInfo, item, sb);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            sb.Append(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            System.Xml.XmlElement updates = (&lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; System.Xml.XmlDocument()).CreateElement(&lt;span style="color:#006080;"&gt;&amp;quot;Batch&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            updates.SetAttribute(&lt;span style="color:#006080;"&gt;&amp;quot;OnError&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;Continue&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            updates.SetAttribute(&lt;span style="color:#006080;"&gt;&amp;quot;ListVersion&amp;quot;&lt;/span&gt;, fileInfo.m_listInfo.m_version);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            updates.SetAttribute(&lt;span style="color:#006080;"&gt;&amp;quot;PreCalc&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;TRUE&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            updates.InnerXml = sb.ToString();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            sharePointLists.Url = fileInfo.m_listInfo.m_webUrl + &lt;span style="color:#006080;"&gt;&amp;quot;/_vti_bin/Lists.asmx&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XmlNode updatesResponse = sharePointLists.UpdateListItems(fileInfo.m_listInfo.m_listName, updates);    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (updatesResponse.FirstChild.FirstChild.InnerText != &lt;span style="color:#006080;"&gt;&amp;quot;0x00000000&amp;quot;&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; Exception(&lt;span style="color:#006080;"&gt;&amp;quot;Could not update properties.&amp;quot;&lt;/span&gt;); &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (WebException ex)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; ex;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p align="justify"&gt;Lo juntamos todo, compilamos, probamos a subir algunos mensajes varias veces y voil&amp;aacute;! Si observamos el control de versiones veremos lo siguiente:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_C4F0/ControlVersiones.png"&gt;&lt;img border="0" width="509" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_C4F0/ControlVersiones_thumb.png" alt="ControlVersiones" height="319" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="ControlVersiones" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;El segundo:&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Si hemos observado con atenci&amp;oacute;n el c&amp;oacute;digo del m&amp;eacute;todo TryToUpload seguramente hemos visto una llamada a un m&amp;eacute;todo updateMetaDataColumns, al cual se le pasa el StringBuilder que estamos construyendo, para que nos agregue los valores de los metadatos (cuya sintaxis que expresarse en XML seg&amp;uacute;n la &lt;a target="_blank" href="http://msdn.microsoft.com/en-us/library/lists.lists.updatelistitems.aspx"&gt;ayuda del m&amp;eacute;todo UpdateListItems&lt;/a&gt;). El c&amp;oacute;digo es muy sencillo y b&amp;aacute;sicamente lo que hace es comprobar si en la lista destino existen las columnas de metadatos, y en caso afirmativo modificar su valor:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;private&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; updateMetadataColumns(FileInfo fileInfo, Outlook.MailItem item, StringBuilder sb)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    var cols = from c &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; SharePointExtensions.getListColumns(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;               sharePointLists, fileInfo.m_listInfo.m_listName)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;               &lt;span style="color:#0000ff;"&gt;where&lt;/span&gt; c.Hidden == &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt; &amp;amp;&amp;amp; c.Sealed == &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt; &amp;amp;&amp;amp; c.ReadOnly == &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;               select c;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    Dictionary&amp;lt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;, SPColumnInfo&amp;gt; columns = cols.ToDictionary(c =&amp;gt; c.Name);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_SUBJECT) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_SUBJECT, item.Subject);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_FROM) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_FROM, item.SenderName);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_TO) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_TO, item.To);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_CC) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_CC, item.CC);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_BCC) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_BCC, item.BCC);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_SIZE) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_SIZE, item.Size);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_SENT) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; dt = item.SentOn.ToString(&lt;span style="color:#006080;"&gt;&amp;quot;yyyy-MM-ddTHH:mm:ssZ&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_SENT, dt);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (columns.ContainsKey(Properties.Settings.Default.COL_IMPORTANCE) &amp;amp;&amp;amp; item != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; im = &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Empty;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;switch&lt;/span&gt; (item.Importance)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;case&lt;/span&gt; Microsoft.Office.Interop.Outlook.OlImportance.olImportanceHigh:&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                im = Properties.Settings.Default.COL_IMPORTANCE_HIGH;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;break&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;case&lt;/span&gt; Microsoft.Office.Interop.Outlook.OlImportance.olImportanceLow:&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                im = Properties.Settings.Default.COL_IMPORTANCE_LOW;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;break&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;case&lt;/span&gt; Microsoft.Office.Interop.Outlook.OlImportance.olImportanceNormal:&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;default&lt;/span&gt;:&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                im = Properties.Settings.Default.COL_IMPORTANCE_MEDIUM;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;break&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        sb.AppendFormat(&lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Field Name=&amp;#39;{0}&amp;#39;&amp;gt;{1}&amp;lt;/Field&amp;gt;&amp;quot;&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            Properties.Settings.Default.COL_IMPORTANCE, im);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&lt;span style="text-decoration:underline;"&gt;&lt;strong&gt;El postre:&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Ingredientes : &lt;br /&gt;125 gr. de chocolate &lt;br /&gt;60 gr. de mantequilla &lt;br /&gt;125 gr. de az&amp;uacute;car &lt;br /&gt;3 huevos &lt;br /&gt;60 gr. de maizena &lt;/p&gt;
&lt;p align="justify"&gt;Receta : &lt;br /&gt;Fundir el chocolate con la mantequilla a fuego lento. &lt;br /&gt;Separar las yemas y las claras. &lt;br /&gt;Mezclar el az&amp;uacute;car con las yemas de los huevos. &lt;br /&gt;A&amp;ntilde;adir la maicena y despu&amp;eacute;s el chocolate fundido. &lt;br /&gt;Montar las claras de huevo a punto de nieve y a&amp;ntilde;adirlas lentamente a la mezcla. &lt;br /&gt;Verter la mezcla en un molde donde se ha extendido la mantequilla previamente. &lt;br /&gt;Hornearlo entre 20 &amp;oacute; 25 minutos a 180&amp;ordm;. &lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Para terminar:&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;En los pr&amp;oacute;ximos art&amp;iacute;culos veremos c&amp;oacute;mo realizar este proceso de subida de ficheros de forma as&amp;iacute;ncrona usando callbacks, para poder continuar trabajando con Outlook y mostrar el progreso en una barra. Tambi&amp;eacute;n para cerrar la serie, veremos los pasos que hay que hacer para construir el proyecto de instalaci&amp;oacute;n de nuestro Add-In, y as&amp;iacute; poder distribuirlo.&lt;/p&gt;
&lt;p align="justify"&gt;Nos vemos!&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1675827" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Utilidad/default.aspx">Utilidad</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/XML/default.aspx">XML</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Serie/default.aspx">Serie</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beerware/default.aspx">Beerware</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2009/default.aspx">2009</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Add-In/default.aspx">Add-In</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VSTO/default.aspx">VSTO</category></item><item><title>SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (V)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/03/03/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-v.aspx</link><pubDate>Tue, 03 Mar 2009 17:28:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1675383</guid><dc:creator>lfranco</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1675383</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/03/03/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-v.aspx#comments</comments><description>&lt;p align="justify"&gt;Entradas anteriores de la serie:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (I)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-ii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (II)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (III)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iv.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (IV)&lt;/a&gt;&lt;/p&gt;
&lt;div align="justify"&gt;
&lt;hr /&gt;
&lt;/div&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_D1F9/bender2.jpg"&gt;&lt;img border="0" width="126" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_D1F9/bender2_thumb.jpg" alt="bender2" height="123" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="bender2" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;Despu&amp;eacute;s de algunos d&amp;iacute;as sin poder seguir con la serie porque &lt;span style="text-decoration:line-through;"&gt;han detenido a &lt;/span&gt;&lt;a target="_blank" href="http://en.wikipedia.org/wiki/Bender_(Futurama)"&gt;&lt;span style="text-decoration:line-through;"&gt;Bender&lt;/span&gt;&lt;/a&gt; hay que sacar adelante otros proyectos, volvemos a la carga con lo que promete ser la serie de art&amp;iacute;culos m&amp;aacute;s larga que he publicado hasta ahora en este blog.&lt;/p&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p align="justify"&gt;Antes de nada vamos a ponernos al d&amp;iacute;a:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;Que pretendemos?&lt;/strong&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Crear un add-in de Outlook que permita guardar nuestros correos en una librer&amp;iacute;a de documentos de SharePoint (tanto MOSS como WSS).&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;Que necesitamos?&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;span style="text-decoration:line-through;"&gt;&lt;span style="color:#ff0000;"&gt;C&amp;oacute;mo crear un complemento para Office (&lt;strong&gt;VSTO&lt;/strong&gt;). visto&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;span style="text-decoration:line-through;"&gt;&lt;span style="color:#ff0000;"&gt;C&amp;oacute;mo registrar acciones en los men&amp;uacute;s de la aplicaci&amp;oacute;n host (Outlook). visto&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;span style="text-decoration:line-through;"&gt;&lt;span style="color:#ff0000;"&gt;C&amp;oacute;mo conectar con un servidor MOSS/WSS con diferentes credenciales de usuario (&lt;strong&gt;System.Net.NetworkCredential&lt;/strong&gt;) visto&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;span style="text-decoration:line-through;"&gt;&lt;span style="color:#ff0000;"&gt;C&amp;oacute;mo acceder a los sitios y listas de un site de MOSS/WSS (&lt;strong&gt;servicios Web de SharePoint&lt;/strong&gt;). visto&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;span style="text-decoration:line-through;"&gt;&lt;span style="color:#ff0000;"&gt;C&amp;oacute;mo interpretar la informaci&amp;oacute;n XML devuelta por los servicios (&lt;strong&gt;LINQ to XML&lt;/strong&gt;). visto&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo extender el modelo de objetos de SharePoint para acceder los valores devueltos por los servicios Web.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo crear las columnas necesarias en una lista para guardar los metadatos del elementos de correo (From, To, Subject).&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo guardar un fichero en una biblioteca de documentos de SharePoint con control de versiones (&lt;strong&gt;DocLibHelper&lt;/strong&gt;). &lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo ejecutar distintos threads y mostrar el progreso (&lt;strong&gt;Callbacks&lt;/strong&gt;). &lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo distribuir nuestro complemento, creando un archivo MSI (&lt;strong&gt;Windows Installer packages&lt;/strong&gt;). &lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p align="justify"&gt;&lt;strong&gt;Que vamos a ver hoy?&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;En este post vamos a centrarnos en c&amp;oacute;mo obtener datos de los servicios Web de SharePoint. En nuestro caso necesitamos obtener las colecciones de sitios, las librer&amp;iacute;as de cada uno de los sitios, y las carpetas de cada librer&amp;iacute;a para mostrarlos en una ventana que permita al usuario seleccionar la ubicaci&amp;oacute;n en la que desea guardar los elementos de coreo:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_D1F9/AddIn_Step2.png"&gt;&lt;img border="0" width="644" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_D1F9/AddIn_Step2_thumb.png" alt="AddIn_Step2" height="446" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddIn_Step2" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Del mismo modo, vamos a necesitar obtener las columnas de la librer&amp;iacute;a seleccionada, para comprobar si ya existen las columnas para almacenar los metadatos de los elementos de correo, y en caso contrario proceder a crearlas (esto va a ir muy bien para posteriormente poder clasificar los elementos).&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_D1F9/Correos1.png"&gt;&lt;img border="0" width="644" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_D1F9/Correos1_thumb.png" alt="Correos1" height="212" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="Correos1" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;Extendiendo el modelo de objetos de SharePoint&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;En el &lt;a target="_blank" href="http://msmvps.com/blogs/lfranco/archive/2009/02/10/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iv.aspx"&gt;post anterior&lt;/a&gt; ya vimos que hab&amp;iacute;amos declarado algunas clases de apoyo (como la clase &amp;lsquo;SPSiteInfo&amp;rsquo;) para que nuestros m&amp;eacute;todos (como el m&amp;eacute;todo &amp;lsquo;getSiteSubSites&amp;rsquo; que tambi&amp;eacute;n vimos en el anterior post) pudiesen devolver colecciones gen&amp;eacute;ricas de &amp;eacute;estos tipos de datos, lo cual es mucho m&amp;aacute;s manejable que pelearnos con el XML que devuelven los servicios Web de SharePoint.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;span style="text-decoration:underline;"&gt;Los m&amp;eacute;todos que vamos a crear son:&lt;/span&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div align="justify"&gt;getSiteSubSites: Devuelve una lista gen&amp;eacute;rica de objetos &amp;lsquo;SPSiteInfo&amp;rsquo;, a partir de un servicio Web&lt;strong&gt; websProxy.Webs&lt;/strong&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;getSiteLists: Devuelve una lista gen&amp;eacute;rica de objetos &amp;lsquo;SPListInfo&amp;rsquo;, a partir de un servicio Web &lt;strong&gt;listsProxy.Lists&lt;/strong&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;getListFolders: Devuelve una lista gen&amp;eacute;rica de objetos &amp;lsquo;SPFolderInfo&amp;rsquo;, a partir de un servicio Web &lt;strong&gt;listsProxy.Lists&lt;/strong&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;getListColumns: Devuelve una lista gen&amp;eacute;rica de objetos &amp;lsquo;SPFolderInfo&amp;rsquo;, a partir de un servicio Web &lt;strong&gt;listsProxy.Lists&lt;/strong&gt; y de un &lt;strong&gt;listID &lt;/strong&gt;(GUID)&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;createMetadataColumns: Crea las columnas de metadatos definidas en los settings del add-in en una lista, a partir de un servicio Web &lt;strong&gt;listsProxy.Lists&lt;/strong&gt; y de un &lt;strong&gt;listID&lt;/strong&gt; (GUID).&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p align="justify"&gt;Las clases de apoyo son:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SPSiteInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; Title { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; URL { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPSiteInfo()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;//&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPSiteInfo(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; title, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; url)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        Title = title;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        URL = url;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SPListInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; Guid ID { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; Title { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; URL { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPListInfo()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;//&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPListInfo(Guid id, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; title, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; url)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        ID = id;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        Title = title;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        URL = url;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SPFolderInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; Title { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; URL { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPFolderInfo()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;//&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPFolderInfo(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; title, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; url)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        Title = title;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        URL = url;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SPColumnInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; ID { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; Type { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; DisplayName { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; Name { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; Hidden { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; Sealed { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; ReadOnly { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPColumnInfo()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;//&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPColumnInfo(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; id, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; type,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; displayName, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; name, &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; hidden, &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; issealed, &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; isreadonly)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        ID = id;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        Type = type;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        DisplayName = displayName;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        Name = name;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        Hidden = hidden;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        Sealed = issealed;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        ReadOnly = isreadonly;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&lt;span style="text-decoration:underline;"&gt;Y el c&amp;oacute;digo de los m&amp;eacute;todos ser&amp;aacute; el siguiente:&lt;/span&gt;&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SharePointExtensions&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; List&amp;lt;SPSiteInfo&amp;gt; getSiteSubSites(websProxy.Webs sharePointWebs)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XmlNode websResult = sharePointWebs.GetWebCollection();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XDocument results = XDocument.Parse(websResult.OuterXml);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XName name = XName.Get(&lt;span style="color:#006080;"&gt;&amp;quot;Web&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;http://schemas.microsoft.com/sharepoint/soap/&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            var webs = from item &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; results.Descendants(name)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                       select &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SPSiteInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                           (&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                           item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Title&amp;quot;&lt;/span&gt;).Value,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                           item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Url&amp;quot;&lt;/span&gt;).Value&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                           );&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; webs.ToList();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (Exception ex)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; ex;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; List&amp;lt;SPListInfo&amp;gt; getSiteLists(listsProxy.Lists sharePointLists)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XmlNode listsResult = sharePointLists.GetListCollection();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XDocument results = XDocument.Parse(listsResult.OuterXml);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XName name = XName.Get(&lt;span style="color:#006080;"&gt;&amp;quot;List&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;http://schemas.microsoft.com/sharepoint/soap/&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            var lists = from item &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; results.Descendants(name)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                        &lt;span style="color:#0000ff;"&gt;where&lt;/span&gt; item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;ServerTemplate&amp;quot;&lt;/span&gt;).Value.ToString() ==&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                            Properties.Settings.Default.SERVER_TEMPLATE&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                        select &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SPListInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                            (&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                            &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; Guid(item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;ID&amp;quot;&lt;/span&gt;).Value),&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                            item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Title&amp;quot;&lt;/span&gt;).Value,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                            item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;DefaultViewUrl&amp;quot;&lt;/span&gt;).Value&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                            );&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; lists.ToList();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (Exception ex)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; ex;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; List&amp;lt;SPFolderInfo&amp;gt; getListFolders(listsProxy.Lists sharePointLists, &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; listName, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; listText, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; folderURL)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XmlDocument xmlDoc = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; System.Xml.XmlDocument();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XmlNode ndQuery = xmlDoc.CreateNode(XmlNodeType.Element, &lt;span style="color:#006080;"&gt;&amp;quot;Query&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XmlNode ndViewFields =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;              xmlDoc.CreateNode(XmlNodeType.Element, &lt;span style="color:#006080;"&gt;&amp;quot;ViewFields&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XmlNode ndQueryOptions = &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (listName != folderURL)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                ndQueryOptions = xmlDoc.CreateNode(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    XmlNodeType.Element, &lt;span style="color:#006080;"&gt;&amp;quot;QueryOptions&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                ndQueryOptions.InnerXml = &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#006080;"&gt;&amp;quot;&amp;lt;Folder&amp;gt;{0}/{1}&amp;lt;/Folder&amp;gt;&amp;quot;&lt;/span&gt;, listName, folderURL);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XName name = XName.Get(&lt;span style="color:#006080;"&gt;&amp;quot;data&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;urn:schemas-microsoft-com:rowset&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XmlNode ndListItems =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    sharePointLists.GetListItems(listText, &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;, ndQuery,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    ndViewFields, &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;, ndQueryOptions, &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XDocument results = XDocument.Parse(ndListItems.OuterXml);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            var folders = from item &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; results.Descendants(name).Elements()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                          &lt;span style="color:#0000ff;"&gt;where&lt;/span&gt; item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;ows_ContentType&amp;quot;&lt;/span&gt;).Value == &lt;span style="color:#006080;"&gt;&amp;quot;Carpeta&amp;quot;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                          select &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SPFolderInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                             (&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                             item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;ows_BaseName&amp;quot;&lt;/span&gt;).Value,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                             item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;ows_ServerUrl&amp;quot;&lt;/span&gt;).Value&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                             );&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; folders.ToList();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (Exception ex)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; ex;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; List&amp;lt;SPColumnInfo&amp;gt; getListColumns(listsProxy.Lists sharePointLists, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; siteID)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            List&amp;lt;SPColumnInfo&amp;gt; columns =&lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; List&amp;lt;SPColumnInfo&amp;gt;();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XmlNode listsResult = sharePointLists.GetList(siteID);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XDocument results = XDocument.Parse(listsResult.OuterXml);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XName name = XName.Get(&lt;span style="color:#006080;"&gt;&amp;quot;Field&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;http://schemas.microsoft.com/sharepoint/soap/&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            var lists = from item &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; results.Descendants(name)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                        select item;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;foreach&lt;/span&gt; (var item &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; lists.ToList())&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                XAttribute aID = item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;ID&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                XAttribute aType = item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Type&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                XAttribute aDisplayName = item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;DisplayName&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                XAttribute aName = item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Name&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                XAttribute aHidden = item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Hidden&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                XAttribute aSealed = item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Sealed&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                XAttribute aReadOnly = item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;ReadOnly&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (aID != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; aType != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; aDisplayName != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    aName != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; ishidden = &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; issealed = &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; isreadonly = &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (aHidden != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; aHidden.Value.ToString() == &lt;span style="color:#006080;"&gt;&amp;quot;TRUE&amp;quot;&lt;/span&gt;) ishidden = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (aSealed != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; aSealed.Value.ToString() == &lt;span style="color:#006080;"&gt;&amp;quot;TRUE&amp;quot;&lt;/span&gt;) issealed = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (aReadOnly != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt; &amp;amp;&amp;amp; aReadOnly.Value.ToString() == &lt;span style="color:#006080;"&gt;&amp;quot;TRUE&amp;quot;&lt;/span&gt;) isreadonly = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    columns.Add(&lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SPColumnInfo(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                        aID.Value.ToString(),&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                        aType.Value.ToString(),&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                        aDisplayName.Value.ToString(),&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                        aName.Value.ToString(),&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                        ishidden, issealed, isreadonly));&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; columns;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (Exception ex)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {                &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; ex;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; createMetadataColumns(listsProxy.Lists sharePointLists, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; listID)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;int&lt;/span&gt; createColumnsCount = 0;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!Properties.Settings.Default.OPTION_CREATE_METADATA_COLUMNS) &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        var cols = from c &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; SharePointExtensions.getListColumns(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                   sharePointLists, listID)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                   &lt;span style="color:#0000ff;"&gt;where&lt;/span&gt; c.Hidden == &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt; &amp;amp;&amp;amp; c.Sealed == &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt; &amp;amp;&amp;amp; c.ReadOnly == &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                   select c;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        Dictionary&amp;lt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;, SPColumnInfo&amp;gt; columns = cols.ToDictionary(c =&amp;gt; c.Name);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; newFieldsList = &lt;span style="color:#006080;"&gt;&amp;quot;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_SUBJECT))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;1&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;Text&amp;#39; DisplayName=&amp;#39;{0}&amp;#39; MaxLength=&amp;#39;255&amp;#39;/&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield, Properties.Settings.Default.COL_SUBJECT);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_TO))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;2&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;Text&amp;#39; DisplayName=&amp;#39;{0}&amp;#39; MaxLength=&amp;#39;255&amp;#39;/&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield, Properties.Settings.Default.COL_TO);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_CC))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;3&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;Text&amp;#39; DisplayName=&amp;#39;{0}&amp;#39; MaxLength=&amp;#39;255&amp;#39;/&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield, Properties.Settings.Default.COL_CC);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_BCC))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;4&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;Text&amp;#39; DisplayName=&amp;#39;{0}&amp;#39; MaxLength=&amp;#39;255&amp;#39;/&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield, Properties.Settings.Default.COL_BCC);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_FROM))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;5&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;Text&amp;#39; DisplayName=&amp;#39;{0}&amp;#39; MaxLength=&amp;#39;255&amp;#39;/&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield, Properties.Settings.Default.COL_FROM);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_SENT))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;6&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;DateTime&amp;#39; DateOnly=&amp;#39;FALSE&amp;#39; DisplayName=&amp;#39;{0}&amp;#39;/&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield, Properties.Settings.Default.COL_SENT);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_SIZE))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;7&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;Number&amp;#39; DisplayName=&amp;#39;{0}&amp;#39;/&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield, Properties.Settings.Default.COL_SIZE);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (!columns.ContainsKey(Properties.Settings.Default.COL_IMPORTANCE))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; subjectfield =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                &lt;span style="color:#006080;"&gt;@&amp;quot;&amp;lt;Method ID=&amp;#39;8&amp;#39;&amp;gt;&amp;lt;Field Type=&amp;#39;Choice&amp;#39; DisplayName=&amp;#39;{0}&amp;#39;&amp;gt;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                  &amp;lt;Default&amp;gt;{1}&amp;lt;/Default&amp;gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                  &amp;lt;CHOICES&amp;gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    &amp;lt;CHOICE&amp;gt;{2}&amp;lt;/CHOICE&amp;gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    &amp;lt;CHOICE&amp;gt;{3}&amp;lt;/CHOICE&amp;gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    &amp;lt;CHOICE&amp;gt;{4}&amp;lt;/CHOICE&amp;gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                  &amp;lt;/CHOICES&amp;gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &amp;lt;/Field&amp;gt;&amp;lt;/Method&amp;gt;&amp;quot;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            newFieldsList += &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt;.Format(subjectfield,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.COL_IMPORTANCE,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.COL_IMPORTANCE_MEDIUM,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.COL_IMPORTANCE_HIGH,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.COL_IMPORTANCE_MEDIUM,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                Properties.Settings.Default.COL_IMPORTANCE_LOW);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            createColumnsCount++;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (createColumnsCount &amp;gt; 0)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XmlNode ndList = sharePointLists.GetList(listID);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XmlNode ndVersion = ndList.Attributes[&lt;span style="color:#006080;"&gt;&amp;quot;Version&amp;quot;&lt;/span&gt;];&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XmlDocument xmlDoc = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; System.Xml.XmlDocument();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            XmlNode ndNewFields = xmlDoc.CreateNode(XmlNodeType.Element, &lt;span style="color:#006080;"&gt;&amp;quot;Fields&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            ndNewFields.InnerXml = newFieldsList;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                XmlNode ndReturn =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                   sharePointLists.UpdateList(listID,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                   &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;, ndNewFields, &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;, &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                   ndVersion.Value);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (Exception ex)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; ex;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Y con esto ya estamos en disposici&amp;oacute;n de mostrar un cuadro de di&amp;aacute;logo al usuario, para que seleccione la ubicaci&amp;oacute;n en el servidor de SharePoint d&amp;oacute;nde quiere guardar los elementos de correo.&lt;/p&gt;
&lt;p align="justify"&gt;En el pr&amp;oacute;ximo post veremos c&amp;oacute;mo guardar los elementos de corro en la ubicaci&amp;oacute;n seleccionada, creando las columnas de metadatos (si as&amp;iacute; lo hemos definido), y actualizando el valor de &amp;eacute;stas columnas para guardar los valores de los campos de correo (Asunto, De, Para, Fecha, Tama&amp;ntilde;o, etc.).&lt;/p&gt;
&lt;p align="justify"&gt;Os recuerdo que al terminar la serie publicar&amp;eacute; la soluci&amp;oacute;n con el c&amp;oacute;digo completo, por si a alguien le sirve.&lt;/p&gt;
&lt;p align="justify"&gt;Espero no demorarme tanto en escribir el pr&amp;oacute;ximo post!&lt;/p&gt;
&lt;p align="justify"&gt;Nos vemos, un saludo desde Andorra!&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1675383" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Sharepoint/default.aspx">Sharepoint</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Utilidad/default.aspx">Utilidad</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/XML/default.aspx">XML</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Serie/default.aspx">Serie</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/LINQ/default.aspx">LINQ</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beerware/default.aspx">Beerware</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Add-In/default.aspx">Add-In</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VSTO/default.aspx">VSTO</category></item><item><title>LINQ to SQL (SQL compaq también existe!)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/02/24/linq-to-sql-sql-compaq-tambi-233-n-existe.aspx</link><pubDate>Tue, 24 Feb 2009 12:58:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1673489</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1673489</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/02/24/linq-to-sql-sql-compaq-tambi-233-n-existe.aspx#comments</comments><description>&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/sqlserver2008logo.gif"&gt;&lt;img border="0" width="363" src="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/sqlserver2008logo_thumb.gif" alt="sqlserver2008logo" height="75" style="border-top-width:0px;display:inline;border-left-width:0px;border-bottom-width:0px;border-right-width:0px;" title="sqlserver2008logo" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Esta ma&amp;ntilde;ana mi colega de penurias Toni Sala me preguntaba acerca de las posibilidades de usar LINQ to SQL con bases de datos SQL Compaq. Efectivamente, se puede hacer, es algo que prob&amp;eacute; en su momento y no hab&amp;iacute;a utilizado m&amp;aacute;s. Sin embargo, lo que si que recordaba era que no es tan evidente como con sus hermanos mayores.&lt;/p&gt;
&lt;p align="justify"&gt;Bueno, al l&amp;iacute;o. Para este ejemplo vamos a usar la BD de ejemplo &lt;strong&gt;Northwind.sdf&lt;/strong&gt; que instala Visual Studio 2008 (en mi caso la tengo ubicada en &amp;lsquo;C:\Archivos de programa\Microsoft SQL Server Compact Edition\v3.5\Samples&amp;rsquo;).&lt;/p&gt;
&lt;p align="justify"&gt;Una vez creado el proyecto de ejemplo (en mi caso lo llamar&amp;eacute; &amp;lsquo;SqlCompaqLINQ&amp;rsquo;), creamos una carpeta &amp;lsquo;Data&amp;rsquo; dentro de nuestro proyecto y agregamos la BD a nuestro proyecto mediante &amp;lsquo;Project/Add existing Item&amp;rsquo;:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQPE.png"&gt;&lt;img border="0" width="244" src="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQPE_thumb.png" alt="SqlCompaqLINQPE" height="238" style="border-top-width:0px;display:inline;border-left-width:0px;border-bottom-width:0px;border-right-width:0px;" title="SqlCompaqLINQPE" /&gt;&lt;/a&gt;&amp;nbsp;&lt;a href="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQAddDB.png"&gt;&lt;img border="0" width="314" src="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQAddDB_thumb.png" alt="SqlCompaqLINQAddDB" height="236" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="SqlCompaqLINQAddDB" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Hasta aqu&amp;iacute; todo normal, pero la diferencia de SQlCompaq respecto a sus hermanos mayores est&amp;aacute; en que si ahora creamos un DataContext e intentamos arrastrar una tabla sobre &amp;eacute;l, aparecer&amp;aacute; un mensaje de error un poco descorazonador:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQError.png"&gt;&lt;img border="0" width="358" src="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQError_thumb.png" alt="SqlCompaqLINQError" height="130" style="border-top-width:0px;display:inline;border-left-width:0px;border-bottom-width:0px;border-right-width:0px;" title="SqlCompaqLINQError" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;No pasa nada, para estos casos podemos ir directamente a la herramienta &lt;a target="_blank" href="http://msdn.microsoft.com/es-es/library/bb386987.aspx"&gt;SqlMetal&lt;/a&gt; (ya sab&amp;eacute;is lo del &lt;a target="_blank" href="http://www.google.com/search?hl=es&amp;amp;q=el+poder+del+metal&amp;amp;lr="&gt;poder del metal&lt;/a&gt; :-P), y generar el correspondiente fichero DBML mediante la l&amp;iacute;nea de comandos. Para ello abrimos la consola de Visual Studio y ejecutamos el siguiente comando (desde nuestra carpeta &amp;lsquo;Data&amp;rsquo;):&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="font-family:Lucida Console;"&gt;SqlMetal.exe Northwind.sdf /dbml:NorthwindCE.dbml&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Esto generar&amp;aacute; el dise&amp;ntilde;ador con las clases correspondientes a las tablas de la BD de SQL Compaq, que a continuaci&amp;oacute;n agegaremos a nuestro proyecto tambi&amp;eacute;n mediante &amp;lsquo;Project/Add existing Item&amp;rsquo;:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQDataContext.png"&gt;&lt;img border="0" width="487" src="http://blogimages.uyssoft.com/LINQtoSQLSQLcompaqtambinexiste_B4FB/SqlCompaqLINQDataContext_thumb.png" alt="SqlCompaqLINQDataContext" height="484" style="border-top-width:0px;display:inline;border-left-width:0px;border-bottom-width:0px;border-right-width:0px;" title="SqlCompaqLINQDataContext" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Ahora basta con crear una instancia del dise&amp;ntilde;ador, generar nuestra instrucci&amp;oacute;n LINQ to SQL y &amp;iexcl;a jugar!:&lt;/p&gt;
&lt;div align="justify"&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; SqlCompaqLINQ.Data;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;...&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; path = &lt;span style="color:#006080;"&gt;&amp;quot;Data Source=|DataDirectory|\\Data\\Northwind.sdf&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt;(Northwind dc = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; Northwind(path))&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    var customers = from c &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; dc.Customers&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                    orderby c.CompanyName&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                    select c;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    listBox1.DataSource = customers.ToList();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    listBox1.DisplayMember = &lt;span style="color:#006080;"&gt;&amp;quot;CompanyName&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    listBox1.ValueMember = &lt;span style="color:#006080;"&gt;&amp;quot;CustomerID&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Un saludo desde Andorra,&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1673489" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2008/default.aspx">2008</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/LINQ/default.aspx">LINQ</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/SQL+Server/default.aspx">SQL Server</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/SQL+Compaq/default.aspx">SQL Compaq</category></item><item><title>SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (IV)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/02/10/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iv.aspx</link><pubDate>Tue, 10 Feb 2009 15:31:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1671214</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1671214</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/02/10/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iv.aspx#comments</comments><description>&lt;p align="justify"&gt;Entradas anteriores de la serie:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (I)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-ii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (II)&lt;/a&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (III)&lt;/a&gt;&lt;/p&gt;
&lt;div align="justify"&gt;
&lt;hr /&gt;
&lt;/div&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/bendervitruvio.jpg"&gt;&lt;img border="0" width="243" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/bendervitruvio_thumb.jpg" alt="bendervitruvio" height="244" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="bendervitruvio" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;He estado un par de d&amp;iacute;as sin poder continuar con la serie, pero es que el trabajo aprieta y no siempre nos podemos dedicar a lo que m&amp;aacute;s nos gusta...&lt;/p&gt;
&lt;p align="justify"&gt;Recapitulando: Cosas que necesitamos para nuestro add-in:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;span style="text-decoration:line-through;"&gt;C&amp;oacute;mo crear un complemento para Office (&lt;strong&gt;VSTO&lt;/strong&gt;).&lt;/span&gt; visto en el &lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;post anterior&lt;/a&gt;.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo registrar acciones en los men&amp;uacute;s de la aplicaci&amp;oacute;n host (Outlook). &lt;span style="color:#ff0000;"&gt;Lo veremos ahora.&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo conectar con un servidor MOSS/WSS con diferentes credenciales de usuario (&lt;strong&gt;System.Net.NetworkCredential&lt;/strong&gt;) &lt;span style="color:#ff0000;"&gt;Esto tambi&amp;eacute;n lo veremos ahora.&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;span style="text-decoration:line-through;"&gt;C&amp;oacute;mo acceder a los sitios y listas de un site de MOSS/WSS (&lt;strong&gt;servicios Web de SharePoint&lt;/strong&gt;).&lt;/span&gt; visto en el &lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;post anterior&lt;/a&gt;.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;C&amp;oacute;mo interpretar la informaci&amp;oacute;n XML devuelta por los servicios (&lt;strong&gt;LINQ to XML&lt;/strong&gt;). &lt;span style="color:#ff0000;"&gt;Y esto tambi&amp;eacute;n lo veremos ahora.&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;El resto de cosas las veremos en los pr&amp;oacute;ximos d&amp;iacute;as...&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p align="justify"&gt;Hoy nos centraremos en mostrar c&amp;oacute;mo agregar opciones a los men&amp;uacute;s de Outlook (para lanzar nuestras acciones personalizadas), ver c&amp;oacute;mo conectar con un sitio de SharePoint con las credenciales predeterminadas, o bien proporcionando un usuario y password. Y adem&amp;aacute;s veremos c&amp;oacute;mo interpretar el resultado devuelto por los servicios Web, ya que el usar LINQ to XML va a facilitarnos en mucho la tarea de lidiar con XML puro y duro.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Demos un vistazo al futuro, a lo que va a ser este Add-In (solo &lt;a target="_blank" href="http://en.wikipedia.org/wiki/Bender_(Futurama)"&gt;Bender&lt;/a&gt; puede viajar al futuro):&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;1 - Una vez registradas nuestras propias acciones en el men&amp;uacute; de Outlook, &amp;eacute;stas permitir&amp;aacute;n guardar los elementos selecionados:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step1.png"&gt;&lt;img border="0" width="631" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step1_thumb.png" alt="AddIn_Step1" height="402" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddIn_Step1" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;2 &amp;ndash; Aparecer&amp;aacute; una ventana en la que podremos se leccionar la biblioteca de documentos y la carpeta destino:&lt;/p&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step2.png"&gt;&lt;img border="0" width="707" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step2_thumb.png" alt="AddIn_Step2" height="490" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddIn_Step2" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;3 &amp;ndash; Una vez seleccionada la carpeta, mostraremos una ventana de progreso en un hilo separado para que el usuario pueda seguir interactuando con Outlook:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step3.png"&gt;&lt;img border="0" width="439" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step3_thumb.png" alt="AddIn_Step3" height="194" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddIn_Step3" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;4 &amp;ndash; Una vez terminado, si vamos a la biblioteca de documentos aparecer&amp;aacute;n los documentos (y m&amp;aacute;s adelante tambi&amp;eacute;n los metadatos):&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step4.png"&gt;&lt;img border="0" width="573" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/AddIn_Step4_thumb.png" alt="AddIn_Step4" height="233" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddIn_Step4" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Vayamos por partes:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Registrar acciones en un men&amp;uacute; de Outlook:&lt;/span&gt;&lt;/strong&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Registrar el men&amp;uacute; es sencillo, s&amp;oacute;lo debemos modificar el c&amp;oacute;digo del evento &amp;lsquo;ItemContextMenuDisplay&amp;rsquo; (como ya vimos en el &lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;post anterior&lt;/a&gt;), y llamar a un m&amp;eacute;todo &amp;lsquo;RegisterMenu&amp;rsquo; que se encarga de agregar nuestras acciones al men&amp;uacute; contextual de Outlook.&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; Application_ItemContextMenuDisplay(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    Microsoft.Office.Core.CommandBar CommandBar, &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    Microsoft.Office.Interop.Outlook.Selection Selection)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    RegisterMenu(CommandBar, &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; RegisterMenu(Microsoft.Office.Core.CommandBar CommandBar, &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; IsFolder)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    Office.CommandBarPopup cmdSaveToMOSS = &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        (Office.CommandBarPopup)CommandBar.FindControl(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        missing, missing, &lt;span style="color:#006080;"&gt;&amp;quot;STSMOSS&amp;quot;&lt;/span&gt;, missing, missing);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (cmdSaveToMOSS == &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        cmdSaveToMOSS = (Office.CommandBarPopup)CommandBar.Controls.Add(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                Office.MsoControlType.msoControlPopup, missing,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                missing, missing, &lt;span style="color:#0000ff;"&gt;false&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (cmdSaveToMOSS != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            cmdSaveToMOSS.Caption = Properties.Resources.CONTEXT_MENU_CAPTION;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            cmdSaveToMOSS.Tag = &lt;span style="color:#006080;"&gt;&amp;quot;STMOSS&amp;quot;&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            cmdSaveToMOSS.BeginGroup = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            Office.CommandBarButton btnSaveToMOSS =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                (Office.CommandBarButton)cmdSaveToMOSS.Controls.Add(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                Office.MsoControlType.msoControlButton, missing, missing, missing, missing);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            btnSaveToMOSS.Caption = Properties.Resources.CONTEXT_MENU_SENDBUTTON;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            btnSaveToMOSS.FaceId = 65;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            btnSaveToMOSS.Tag = IsFolder.ToString();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            btnSaveToMOSS.Style = MsoButtonStyle.msoButtonIconAndCaption;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            btnSaveToMOSS.Picture = getImage();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            btnSaveToMOSS.Click += &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; Microsoft.Office.Core.&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                _CommandBarButtonEvents_ClickEventHandler(saveToMOSS_Click);  &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            Office.CommandBarButton btnConfigurationMOSS =&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                (Office.CommandBarButton)cmdSaveToMOSS.Controls.Add(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                Office.MsoControlType.msoControlButton, missing, missing, missing, missing);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            btnConfigurationMOSS.Caption = Properties.Resources.CONTEXT_MENU_CONFIGURATIONBUTTON;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            btnConfigurationMOSS.BeginGroup = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            btnConfigurationMOSS.Style = MsoButtonStyle.msoButtonIconAndCaption;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            btnConfigurationMOSS.Click += &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; Microsoft.Office.Core.&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                _CommandBarButtonEvents_ClickEventHandler(configurationMOSS_Click);  &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            cmdSaveToMOSS.Visible = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&amp;nbsp;&lt;/p&gt;
&lt;p align="justify"&gt;Este c&amp;oacute;digo crea un elemento men&amp;uacute; y le agrega dos opciones (&amp;lsquo;btnSaveToMOSS&amp;rsquo; y &amp;lsquo;btnConfigurationMOSS&amp;rsquo;). A continuaci&amp;oacute;n establece sus propiedades y asigna los event handlers a sendas rutinas que se ejecutar&amp;aacute;n al pulsar sobre ellas.&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; saveToMOSS_Click(Microsoft.Office.Core.CommandBarButton Ctrl, &lt;span style="color:#0000ff;"&gt;ref&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; CancelDefault)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{     &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    CancelDefault = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    MessageBox.Show(&lt;span style="color:#006080;"&gt;&amp;quot;Save&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; configurationMOSS_Click(Microsoft.Office.Core.CommandBarButton Ctrl, &lt;span style="color:#0000ff;"&gt;ref&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;bool&lt;/span&gt; CancelDefault)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    CancelDefault = &lt;span style="color:#0000ff;"&gt;true&lt;/span&gt;;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    MessageBox.Show(&lt;span style="color:#006080;"&gt;&amp;quot;Config&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Conectar con un servidor MOSS/WSS con diferentes credenciales de usuario:&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;En algunas ocasiones tal vez nos interese conectar con un sitio de SharePoint y no hacer uso de las credenciales predeterminadas (por defecto el token del usuario de Windows). En estos casos, debemos hacer uso de la clase &amp;lsquo;System.Net.NetworkCredential&amp;rsquo;, pasando los valores de usuario y password (y opcionalmente dominio) para acceder al sitio. En este caso he creado unas sencillas funciones que devuelven un objeto de tipo &amp;lsquo;ICredentials&amp;rsquo; que posteriormente usaremos en la propiedad &amp;lsquo;Credentials&amp;rsquo; de los proxies de los servicios Web:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; System.Net.ICredentials getCredentials()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; System.Net.CredentialCache.DefaultCredentials;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; System.Net.ICredentials getCredentials(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; user, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; password, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; domain)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; System.Net.NetworkCredential(user, password, domain);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Interpretar el resultado devuelto por los servicios Web (LINQ to XML):&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;En el &lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx"&gt;post anterior&lt;/a&gt; vimos que el resultado devuelto por los m&amp;eacute;todos de un servicio Web dista mucho de ser f&amp;aacute;cilmente interpretable, ya que nos devuelve un objeto de tipo XmlNode, de modo que debemos analizar el DOM para obtener el resultado deseado. En nuestro caso, vamos a realizar una llamada al m&amp;eacute;todo &amp;lsquo;GetWebCollection()&amp;rsquo;, que devuelve un XmlNode con los nombres de las webs (sites) de un sitio de SharePoint. Pero vamos a utilizar LINQ to XML para obtener s&amp;oacute;lo los elementos de un tipo determinado, y adem&amp;aacute;s vamos a obtener aquellos atributos que nos interesan. Y lo mejor es que todo se hace una sola sentencia:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;static&lt;/span&gt; List&amp;lt;SPSiteInfo&amp;gt; getSiteSubSites(websProxy.Webs sharePointWebs)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;try&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        XmlNode websResult = sharePointWebs.GetWebCollection();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        XDocument results = XDocument.Parse(websResult.OuterXml);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        XName name = XName.Get(&lt;span style="color:#006080;"&gt;&amp;quot;Web&amp;quot;&lt;/span&gt;, &lt;span style="color:#006080;"&gt;&amp;quot;http://schemas.microsoft.com/sharepoint/soap/&amp;quot;&lt;/span&gt;);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        var webs = from item &lt;span style="color:#0000ff;"&gt;in&lt;/span&gt; results.Descendants(name)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                   select &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; SPSiteInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                       (&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                       item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Title&amp;quot;&lt;/span&gt;).Value,&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;                       item.Attribute(&lt;span style="color:#006080;"&gt;&amp;quot;Url&amp;quot;&lt;/span&gt;).Value&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;                       );&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; webs.ToList();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;catch&lt;/span&gt; (Exception ex)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;throw&lt;/span&gt; ex;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;A destacar en el c&amp;oacute;digo anterior el uso de un elemento &lt;a href="http://msdn.microsoft.com/en-us/library/system.xml.linq.xname.aspx"&gt;XName&lt;/a&gt; para obtener s&amp;oacute;lo los elementos de tipo Web:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/XName_Web.png"&gt;&lt;img border="0" width="696" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B86B/XName_Web_thumb.png" alt="XName_Web" height="415" title="XName_Web" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;A continuaci&amp;oacute;n basta con seleccionar los atributos deseados de cada elemento XML (en nuestro caso t&amp;iacute;tulo y url) e ir creando objetos que almacenaremos en una colecci&amp;oacute;n. Aqu&amp;iacute; utilizo una sencilla clase llamada &amp;lsquo;SPSiteInfo&amp;rsquo; para devolver una lista gen&amp;eacute;rica. Esta clase tiene s&amp;oacute;lo dos propiedades de tipo string (Title y URL) y un constructor en el que le pasamos ambos valores:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; SPSiteInfo&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; Title { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; URL { get; set; }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPSiteInfo()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;//&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; SPSiteInfo(&lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; title, &lt;span style="color:#0000ff;"&gt;string&lt;/span&gt; url)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        Title = title;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        URL = url;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;De este modo, ya tenemos una funci&amp;oacute;n que nos devuelve una colecci&amp;oacute;n de objetos &amp;lsquo;SPSiteInfo&amp;rsquo;. Emplearemos este mismo procedimiento para recuperar las bibliotecas de documentos de un sitio, las carpetas de una biblioteca de documentos, e incluso las columnas de una biblioteca de documentos.&lt;/p&gt;
&lt;p align="justify"&gt;Pero ello lo veremos en el pr&amp;oacute;ximo post, que hay que volver a las trincheras... :-)&lt;/p&gt;
&lt;p align="justify"&gt;PD &amp;ndash; Os recuerdo que al final de la serie publicar&amp;eacute; el c&amp;oacute;digo fuente del proyecto de ejemplo.&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1671214" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Sharepoint/default.aspx">Sharepoint</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Utilidad/default.aspx">Utilidad</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/XML/default.aspx">XML</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Serie/default.aspx">Serie</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/LINQ/default.aspx">LINQ</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beerware/default.aspx">Beerware</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Add-In/default.aspx">Add-In</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VSTO/default.aspx">VSTO</category></item><item><title>SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (III)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/02/04/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx</link><pubDate>Wed, 04 Feb 2009 16:22:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1668891</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1668891</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/02/04/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-iii.aspx#comments</comments><description>&lt;p&gt;Entradas anteriores de la serie:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (I)&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-ii.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (II)&lt;/a&gt;&lt;/p&gt;
&lt;hr /&gt;
&lt;p&gt;&amp;nbsp;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/BenderDrinking.gif"&gt;&lt;img border="0" width="244" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/BenderDrinking_thumb.gif" alt="BenderDrinking" height="235" style="border-top-width:0px;display:inline;border-left-width:0px;border-bottom-width:0px;border-right-width:0px;" title="BenderDrinking" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Bueno, vamos a empezar a trabajar en nuestro Add-In!&lt;/p&gt;
&lt;p align="justify"&gt;Aunque antes, una aclaraci&amp;oacute;n: Como la mayor&amp;iacute;a de vosotros ya sab&amp;eacute;is, en realidad qui&amp;eacute;n hace el trabajo sucio no soy yo. Yo s&amp;oacute;lo me llevo los millones y la fama, mientras que la ingrata tarea de picar c&amp;oacute;digo (que no gusta a nadie :-P) se la dejo a mi &lt;a target="_blank" href="http://en.wikipedia.org/wiki/Bender_(Futurama)"&gt;Bender&lt;/a&gt;. Efectivamente, acab&amp;aacute;is de descubrir uno de los secretos mejor guardados: Detr&amp;aacute;s de un &lt;a target="_blank" href="https://mvp.support.microsoft.com/"&gt;MVP&lt;/a&gt; siempre hay alguien haciendo el trabajo real mientras ellos se llevan el m&amp;eacute;rito... Esto ha sido as&amp;iacute; desde que el pionero &lt;a target="_blank" href="http://vigon.mvps.org/"&gt;Rub&amp;eacute;n Vig&amp;oacute;n&lt;/a&gt; ense&amp;ntilde;&amp;oacute; a codificar a su gato con Visual Basic 3.0, y poco a poco la mayor&amp;iacute;a hemos ido &amp;lsquo;adoptando&amp;rsquo; esta acertada filosof&amp;iacute;a, que en mi caso me ha permitido apartarme de estas tareas mundanas y dedicarme a mis vi&amp;ntilde;edos y mi afici&amp;oacute;n desmedida por la calceta.&lt;/p&gt;
&lt;p align="justify"&gt;As&amp;iacute; que en cuanto le propuse la idea del Add-In a &lt;a href="http://en.wikipedia.org/wiki/Bender_(Futurama)"&gt;Bender&lt;/a&gt;, le pareci&amp;oacute; que deb&amp;iacute;amos ponernos a ello en seguida (seguramente animado por la visi&amp;oacute;n de las 2 cajas de un &lt;a target="_blank" href="http://es.wikipedia.org/wiki/Chardonnay"&gt;chardonnay&lt;/a&gt; excelente que recibir&amp;aacute; como compensaci&amp;oacute;n al terminar). De modo que vamos a empezar en seguida.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p align="justify"&gt;&lt;strong&gt;Nota: Al terminar la serie publicar&amp;eacute; el proyecto de ejemplo con todo el c&amp;oacute;digo al completo. &lt;br /&gt;Un poco de paci&amp;eacute;ncia porque lo voy a ir haciendo sobre la marcha, ok?&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Creando un proyecto Add-In para Outlook 2007&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Esta es la parte m&amp;aacute;s sencilla, ya que con Visual Studio 2008 (supongo que todos lo ten&amp;eacute;is actualizado con el SP1) se incorporan las plantillas b&amp;aacute;sicas para crear un proyecto de este tipo. Basta con iniciar un proyecto nuevo, y dentro de la categor&amp;iacute;a &amp;lsquo;Office&amp;rsquo; encontrar&amp;eacute;is las plantillas para la versi&amp;oacute;n 2007.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/OutlookAddInNewProject.png"&gt;&lt;img border="0" width="484" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/OutlookAddInNewProject_thumb.png" alt="OutlookAddInNewProject" height="354" style="border-top-width:0px;display:inline;border-left-width:0px;border-bottom-width:0px;border-right-width:0px;" title="OutlookAddInNewProject" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Esto crea un proyecto C# con las referencias necesarias para ejecutarse como complemento de Outlook, y proporciona el esqueleto b&amp;aacute;sico para interceptar los eventos que se producen al cargar y descargar nuestro complemento.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/ProjectReferences.png"&gt;&lt;img border="0" width="244" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/ProjectReferences_thumb.png" alt="ProjectReferences" height="213" style="border-top-width:0px;display:inline;border-left-width:0px;border-bottom-width:0px;border-right-width:0px;" title="ProjectReferences" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; Outlook = Microsoft.Office.Interop.Outlook;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;using&lt;/span&gt; Office = Microsoft.Office.Core;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;namespace&lt;/span&gt; OutlookToMOSS&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;{&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;partial&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;class&lt;/span&gt; ThisAddIn&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;private&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; ThisAddIn_Startup(&lt;span style="color:#0000ff;"&gt;object&lt;/span&gt; sender, System.EventArgs e)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;private&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; ThisAddIn_Shutdown(&lt;span style="color:#0000ff;"&gt;object&lt;/span&gt; sender, System.EventArgs e)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#cc6633;"&gt;#region&lt;/span&gt; VSTO generated code&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;/// Required method for Designer support - do not modify&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;/// the contents of this method with the code editor.&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#008000;"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;private&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; InternalStartup()&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;.Startup += &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; System.EventHandler(ThisAddIn_Startup);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            &lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;.Shutdown += &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; System.EventHandler(ThisAddIn_Shutdown);&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        &lt;span style="color:#cc6633;"&gt;#endregion&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    }&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;}&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Observar que hay una regi&amp;oacute;n de c&amp;oacute;digo generado por el dise&amp;ntilde;ador, que es la encargada de suscribir los eventos &amp;lsquo;&lt;strong&gt;StartUp&amp;rsquo;&lt;/strong&gt; y &lt;strong&gt;&amp;lsquo;StartDown&amp;rsquo;&lt;/strong&gt;. En estos eventos, posteriormente agregaremos el c&amp;oacute;digo para inicializar y destruir nuestras referencias a los servicios Web de SharePoint. Adem&amp;aacute;s para poder interactuar con Outlook interceptaremos adem&amp;aacute;s un par de eventos m&amp;aacute;s llamados &lt;strong&gt;&amp;lsquo;ItemContextMenuDisplay&amp;rsquo;&lt;/strong&gt; y &lt;strong&gt;&amp;rsquo;FolderContextMenuDisplay&amp;rsquo;&lt;/strong&gt;, que se producen al mostrar los men&amp;uacute;s contextuales de Outlook (por ejemplo, al pulsar el bot&amp;oacute;n derecho sobre una selecci&amp;oacute;n de elementos de correo).&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Agregando referencias a los servicios Web de SharePoint&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Lo primero es lo primero, as&amp;iacute; que ya que vamos a interactuar con SharePoint, vamos a agregar referencias Web a aquellos servicios que vamos a consumir. Aunque tenemos una &lt;a target="_blank" href="http://msdn.microsoft.com/en-us/library/ms479390.aspx"&gt;lista de varios servicios Web&lt;/a&gt;, de entrada vamos a trabajar con estos dos, aunque probablemente a&amp;ntilde;adiremos otros m&amp;aacute;s adelante:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;a target="_blank" href="http://msdn.microsoft.com/en-us/library/webs.aspx"&gt;Webs Web Service&lt;/a&gt;: Para acceder a la colecci&amp;oacute;n de sitios Web de un sitio de SharePoint.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;a target="_blank" href="http://msdn.microsoft.com/en-us/library/lists.aspx"&gt;Lists Web Service&lt;/a&gt;: Para acceder a la colecci&amp;oacute;n de bibliotecas de documentos de un sitio.&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p align="justify"&gt;Para crear la referencia debemos conocer la URL de nuestro SharePoint (por ejemplo &lt;a href="http://moss"&gt;http://moss&lt;/a&gt;). Y agregar una &amp;lsquo;Service Reference&amp;rsquo; al proyecto. Esto mostrar&amp;aacute; el cuadro de di&amp;aacute;logo para agregar servicios WCF, pero como en nuestro caso vamos a agregar una referencia a un servicio Web 2.0 hay que dar un rodeo, ir a la parte avanzada y especificar que queremos crear una &amp;lsquo;Web reference&amp;lsquo;:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/AddWebReference1.png"&gt;&lt;img border="0" width="540" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/AddWebReference1_thumb.png" alt="AddWebReference1" height="449" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddWebReference1" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Pulsar en el bot&amp;oacute;n para mostrar las caracter&amp;iacute;sticas avanzadas:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/AddWebReference2.png"&gt;&lt;img border="0" width="555" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/AddWebReference2_thumb.png" alt="AddWebReference2" height="528" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddWebReference2" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Especificar que deseamos agregar una &amp;lsquo;Web reference&amp;rsquo; y en la nueva ventana especificar la URL del servicio, que siempre sigue esta nomenclatura:&lt;/p&gt;
&lt;p align="justify"&gt;&amp;lt;URL Servidor SharePoint&amp;gt;/_vti_bin/&amp;lt;Nombre del servicio Web&amp;gt;&lt;/p&gt;
&lt;p align="justify"&gt;En nuestro caso:&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;http://moss/_vti_bin/Webs.asmx&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;http://moss/_vti_bin/Lists.asmx&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Especificando el nombre (en mi caso tengo por costumbre llamarlos websProxy y listsProxy).&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/AddWebReference3.png"&gt;&lt;img border="0" width="704" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/AddWebReference3_thumb.png" alt="AddWebReference3" height="503" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="AddWebReference3" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Una vez a&amp;ntilde;adidas veremos que en el &amp;aacute;rbol del proyecto aparece un elemento llamado &amp;lsquo;Web References&amp;rsquo; que contiene las dos referencias a los servicios Web.&lt;/p&gt;
&lt;p align="justify"&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Interceptando eventos de Outlook&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p align="justify"&gt;Ahora, para hacerlo m&amp;aacute;s interesante, antes de ejecutar vamos a interceptar el evento &lt;strong&gt;&amp;lsquo;ItemContextMenuDisplay&amp;rsquo;&lt;/strong&gt; que se produce cuando el usuario muestra el men&amp;uacute; contextual de los elementos de correo (dicho de otro modo, selecciona uno o varios emails y pulsa bot&amp;oacute;n derecho). Para ello modificaremos la secci&amp;oacute;n generada por el dise&amp;ntilde;ador, agergando la siguiente l&amp;iacute;nea al m&amp;eacute;todo &lt;strong&gt;InternalStartUp()&lt;/strong&gt;:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;.Application.ItemContextMenuDisplay += &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;    &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; Microsoft.Office.Interop.Outlook.ApplicationEvents_11_ItemContextMenuDisplayEventHandler(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;    Application_ItemContextMenuDisplay);&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;&amp;nbsp;Y l&amp;oacute;gicamente ahora crearemos el m&amp;eacute;todo que ser&amp;aacute; llamado al dispararse el evento:&lt;/p&gt;
&lt;div&gt;
&lt;div style="font-size:8pt;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;&amp;nbsp;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        &lt;span style="color:#0000ff;"&gt;void&lt;/span&gt; Application_ItemContextMenuDisplay(&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            Microsoft.Office.Core.CommandBar CommandBar, &lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            Microsoft.Office.Interop.Outlook.Selection Selection)&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;        {&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            websProxy.Webs sharePointWebs;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            sharePointWebs = &lt;span style="color:#0000ff;"&gt;new&lt;/span&gt; websProxy.Webs();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;            sharePointWebs.Credentials = System.Net.CredentialCache.DefaultCredentials;&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:white;border-style:none;padding:0px;"&gt;            XmlNode webs = sharePointWebs.GetWebCollection();&lt;/pre&gt;
&lt;pre style="font-size:8pt;margin:0em;overflow:visible;width:100%;color:black;line-height:12pt;font-family:consolas, &amp;#39;Courier New&amp;#39;, courier, monospace;background-color:#f4f4f4;border-style:none;padding:0px;"&gt;        }&lt;/pre&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;p align="justify"&gt;Este c&amp;oacute;digo es provisional, pero nos servir&amp;aacute; para ver como se debe llamar a un m&amp;eacute;todo de un servicio Web. Primeramente se declara y se crea el objeto, a continuaci&amp;oacute;n se especifican las credenciales (en este caso las predeterminadas) y a continuaci&amp;oacute;n se llama al m&amp;eacute;todo &lt;strong&gt;GetWebCollection()&lt;/strong&gt;, el cual nos devuelve un objeto... &lt;em&gt;&amp;ldquo;oh sorpresa! oh dolor! oh campos de soledad, mustios collados...&amp;rdquo;&lt;/em&gt;, un objeto de tipo XmlNode. Efectivamente, los servicios Web de SharePoint trabajan con XML a tutipl&amp;eacute;n, con lo cual ya te aviso de que si no te gusta trabajar con XML tienes dos opciones: Dejar ahora mismo de leer este art&amp;iacute;culo escrito por &lt;a target="_blank" href="http://en.wikipedia.org/wiki/Bender_(Futurama)"&gt;Bender&lt;/a&gt; y hacer como yo disfrutando la de vida alegre, o bien esperar al pr&amp;oacute;ximo post, en el que veremos como LINQ to XML puede hacernos la vida un poco m&amp;aacute;s f&amp;aacute;cil.&lt;/p&gt;
&lt;p align="justify"&gt;Ahoravamos a establecer un punto de ruptura en la &amp;uacute;ltima l&amp;iacute;nea de c&amp;oacute;digo para ver que retorna el m&amp;eacute;todo &lt;strong&gt;GetWebCollection()&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;span style="text-decoration:underline;"&gt;Estamos listos para ejecutar?&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Pues si, ahora vamos a probar que sucede cuando ejecutamos nuestro proyecto. Como es un Add-In de Outlook va a arrancar &amp;eacute;ste primero y cuando hagamos click con el bot&amp;oacute;n derecho sobre un elemento de correo entrar&amp;aacute; en acci&amp;oacute;n el depurador permiti&amp;eacute;ndonos inspeccionar el valor de la variable &amp;lsquo;webs&amp;rsquo;, el cual os muestro a continuaci&amp;oacute;n, para que os asusteis un poco (hacer click en la imagen para verla m&amp;aacute;s grande):&lt;/p&gt;
&lt;p&gt;&lt;a target="_blank" href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/XmlNode_webs.png"&gt;&lt;img border="0" width="644" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_936B/XmlNode_webs_thumb.png" alt="XmlNode_webs" height="466" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="XmlNode_webs" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Ma&amp;ntilde;ana espero poder continuar con la serie. Y veremos c&amp;oacute;mo agregar elementos a los men&amp;uacute;s de Outlook, y c&amp;oacute;mo LINQ to XML nos va a permitir trabajar m&amp;aacute;s c&amp;oacute;modamente con los datos devueltos por los m&amp;eacute;todos de los servicios Web. Que todos sabemos de las bondades de XML, pero trabajar con atributos nunca resulta tan sencillo como trabajar con colecciones de objetos gen&amp;eacute;ricos, verdad?&lt;/p&gt;
&lt;p align="justify"&gt;Pues eso, ma&amp;ntilde;ana m&amp;aacute;s... que ahora me toca manicura y luego clase de tenis :-P&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1668891" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Sharepoint/default.aspx">Sharepoint</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Utilidad/default.aspx">Utilidad</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Serie/default.aspx">Serie</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beerware/default.aspx">Beerware</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Add-In/default.aspx">Add-In</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VSTO/default.aspx">VSTO</category></item><item><title>SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (II)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/02/03/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-ii.aspx</link><pubDate>Tue, 03 Feb 2009 14:08:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1668523</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1668523</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/02/03/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-ii.aspx#comments</comments><description>&lt;p align="justify"&gt;Entradas anteriores de la serie:&lt;/p&gt;
&lt;p&gt;&lt;a target="_blank" href="http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx"&gt;SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (I)&lt;/a&gt;&lt;/p&gt;
&lt;hr /&gt;
&lt;p align="justify"&gt;Vale, vamos a empezar a escribir la carta a los reyes magos:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B8A3/ReyesMagos.jpg"&gt;&lt;img border="0" width="244" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_B8A3/ReyesMagos_thumb.jpg" alt="Reyes-Magos" height="184" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="Reyes-Magos" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Queridos reyes magos,&lt;/p&gt;
&lt;p align="justify"&gt;Este a&amp;ntilde;o me he portado muy bien as&amp;iacute; que me pido un add-in para Outlook que sirva para guardar los correos en bibliotecas de documentos de SharePoint, y que tenga las siguientes cositas:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div align="justify"&gt;&lt;strong&gt;Que se integre con los men&amp;uacute;s de Outlook&lt;/strong&gt;, para poder seleccionar varios correos y copiarlos a la biblioteca que yo elija.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;Que funcione &lt;strong&gt;tanto para MOSS como para WSS&lt;/strong&gt;, para poder guardar correos en un servidor WSS que tengo en hosting en USA.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;Que permita &lt;strong&gt;cambiar la ubicaci&amp;oacute;n del servidor de SharePoint&lt;/strong&gt; para poder guardar los correos en el que me interese.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;div align="justify"&gt;Que permita &lt;strong&gt;cambiar las credenciales de usuario&lt;/strong&gt;, para permitir conectarme a diferentes sitios.&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;Que se encargue de &lt;strong&gt;crear las columnas necesarias para guardar los metadatos&lt;/strong&gt; del elementos de correo (De, Para, Asunto, Enviado).&lt;/li&gt;
&lt;li&gt;Que cuando guardemos una cantidad importante de correos &lt;strong&gt;no detenga la ejecuci&amp;oacute;n de Outlook&lt;/strong&gt;, y podamos seguir trabajando mientras &amp;eacute;stos se copian.&lt;/li&gt;
&lt;li&gt;Y un detalle importante:&lt;strong&gt; &lt;span style="text-decoration:underline;"&gt;Que tenga control de versiones&lt;/span&gt;&lt;/strong&gt;, por si guardo dos veces el mismo elemento que me mantenga un hist&amp;oacute;rico.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Y para desarrollar algo as&amp;iacute; necesitaremos saber varias cosas, por ejemplo:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;C&amp;oacute;mo crear un complemento para Office (&lt;strong&gt;VSTO&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;C&amp;oacute;mo conectar con un servidor MOSS/WSS con diferentes credenciales de usuario (&lt;strong&gt;System.Net.NetworkCredential&lt;/strong&gt;)&lt;/li&gt;
&lt;li&gt;C&amp;oacute;mo acceder a los sitios y listas de un site de MOSS/WSS (&lt;strong&gt;servicios Web de SharePoint&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;C&amp;oacute;mo interpretar la informaci&amp;oacute;n XML devuelta por los servicios (&lt;strong&gt;LINQ to XML&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;C&amp;oacute;mo guardar un fichero en una biblioteca de documentos de SharePoint con control de versiones (&lt;strong&gt;DocLibHelper&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;C&amp;oacute;mo ejecutar distintos threads y mostrar el progreso (&lt;strong&gt;Callbacks&lt;/strong&gt;).&lt;/li&gt;
&lt;li&gt;C&amp;oacute;mo distribuir nuestro complemento, creando un archivo MSI (&lt;strong&gt;Windows Installer packages&lt;/strong&gt;).&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Y seguramente me dejo unas cuantas cosillas&amp;hellip; pero ya las iremos abordando a medida que nos las encontremos. Al fin y al cabo esto es un proyecto de ejemplo y personal, as&amp;iacute; que sinti&amp;eacute;ndolo mucho no voy a utilizar SCRUM ;-)&lt;/p&gt;
&lt;p&gt;Un saludo y ma&amp;ntilde;ana prometo empezar con el tema!&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1668523" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Sharepoint/default.aspx">Sharepoint</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Utilidad/default.aspx">Utilidad</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Serie/default.aspx">Serie</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beerware/default.aspx">Beerware</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Add-In/default.aspx">Add-In</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VSTO/default.aspx">VSTO</category></item><item><title>SharePoint 2007 + Outlook 2007: Guardar correos de forma masiva (I)</title><link>http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx</link><pubDate>Mon, 02 Feb 2009 11:16:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1668103</guid><dc:creator>lfranco</dc:creator><slash:comments>4</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1668103</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/02/02/sharepoint-2007-outlook-2007-guardar-correos-de-forma-masiva-i.aspx#comments</comments><description>&lt;p&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_918C/SharePointServices.png"&gt;&lt;img border="0" width="145" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_918C/SharePointServices_thumb.png" alt="SharePointServices" height="146" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="SharePointServices" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;Es obvio que SharePoint es uno de los mayores productos de Microsoft, y que ha supuesto una revoluci&amp;oacute;n en el entorno colaborativo empresarial. Hoy en d&amp;iacute;a esta herramienta hace posible que la informaci&amp;oacute;n fluya entre los integrantes de una organizaci&amp;oacute;n, y eso ha aumentado mucho la productividad y los procesos de trabajo de la empresa, algo que siempre agradecen los gestores :-)&lt;/p&gt;
&lt;p&gt;Es obvio tambi&amp;eacute;n que una plataforma de este calibre tiene muchas cosas a mejorar, ya que es todav&amp;iacute;a un &amp;ldquo;reci&amp;eacute;n nacido&amp;rdquo; (aunque lleve ya tres versiones como producto). De forma que hay unos cuantos huecos que deben rellenarse con horas de ardua programaci&amp;oacute;n... algo que desespera a m&amp;aacute;s de uno. Mucha gente me pregunta &amp;ldquo;&amp;iquest;pero c&amp;oacute;mo es posible que esto no est&amp;eacute; implementado?&amp;rdquo;, y mi respuesta acostumbra a ser &amp;ldquo;pueeees... no tengo ni idea chico, pero lo bueno es que disponemos de un modelo de objetos que hace posible que lo implementes tu mismo.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;La verdad es que es m&amp;aacute;s que posible que muchas de estas peque&amp;ntilde;as cositas se implementen en la futura y deseada siguiente versi&amp;oacute;n (de la que muy pocos elegidos saben algo), pero hasta entonces nos encontramos con algunas cosas que hay que hacer &amp;lsquo;a mano&amp;rsquo;.&lt;/p&gt;
&lt;p align="justify"&gt;Precisamente la &amp;uacute;ltima con la que me he encontrado (para mi sorpresa) se trata de que la integraci&amp;oacute;n de Outlook 2007 con SharePoint 2007 no es todo lo buena que deber&amp;iacute;a, o m&amp;aacute;s bien que falta alguna caracter&amp;iacute;stica que encuentro &amp;ldquo;b&amp;aacute;sica&amp;rdquo;. &lt;/p&gt;
&lt;p align="justify"&gt;En este caso se trata de la clasificaci&amp;oacute;n de elementos de correo en bibliotecas de documentos de SharePoint. Ser&amp;iacute;a estupendo poder clasificar nuestros correos en bibliotecas de documentos con un simple &amp;ldquo;Guardar como&amp;hellip;&amp;rdquo;, pero esto s&amp;oacute;lo se puede realizar cuando guardamos los correos de forma individual, ya que deben guardarse como ficheros MSG. Resulta que por alg&amp;uacute;n designio divino esta opci&amp;oacute;n no est&amp;aacute; disponible cuando seleccionamos varios elementos, y claro, ya sabemos que no es una opci&amp;oacute;n v&amp;aacute;lida para un gestor que est&amp;aacute; muy ocupado intentando salvar el mundo ;-) y menos en los tiempos que corren, en los que hay que salir de esta crisis a golpe de reuniones de high-level y comit&amp;eacute;s de direcci&amp;oacute;n, y no estamos para dilapidar el tiempo en tareas repetitivas, verdad?&lt;/p&gt;
&lt;p align="justify"&gt;&lt;a href="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_918C/correo.jpg"&gt;&lt;img border="0" width="124" src="http://blogimages.uyssoft.com/SharePoint2007Outlook2007Guardarcorreosd_918C/correo_thumb.jpg" alt="correo" height="86" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="correo" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p align="justify"&gt;Bueno, al grano que me estoy yendo... el tema es que como no he encontrado una forma de hacerlo, me he propuesto &lt;strong&gt;crear un add-in para Outlook&lt;/strong&gt;, que permita &lt;strong&gt;guardar elementos de correo en bibliotecas de documentos de SharePoint&lt;/strong&gt;. Y a medida que lo vaya desarrollando ir&amp;eacute; posteando algunas de las cosas interesantes de este desarrollo (c&amp;oacute;mo crear un proyecto de add-in para Outlook con VSTO, c&amp;oacute;mo interactuar con la aplicaci&amp;oacute;n host, acceder a los servicios Web de SharePoint, c&amp;oacute;mo distribuir el Add-In, etc). Y al final postear el c&amp;oacute;digo de ejemplo o crear un proyecto en codeplex para la comunidad. De este modo servir&amp;aacute; de ejemplo (aunque sea malo :-P) y tal vez a alguien m&amp;aacute;s podr&amp;aacute; serle &amp;uacute;til.&lt;/p&gt;
&lt;p align="justify"&gt;En el pr&amp;oacute;ximo post empezaremos a planificar el desarrollo. Saludos y hasta pronto,&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1668103" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Sharepoint/default.aspx">Sharepoint</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Utilidad/default.aspx">Utilidad</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Serie/default.aspx">Serie</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Beerware/default.aspx">Beerware</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Add-In/default.aspx">Add-In</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/VSTO/default.aspx">VSTO</category></item><item><title>Tip: Mostrar objetos relacionados en DevExpress GridControl</title><link>http://msmvps.com/blogs/lfranco/archive/2009/01/23/tip-mostrar-objetos-relacionados-en-devexpress-gridcontrol.aspx</link><pubDate>Fri, 23 Jan 2009 12:15:00 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1665016</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1665016</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2009/01/23/tip-mostrar-objetos-relacionados-en-devexpress-gridcontrol.aspx#comments</comments><description>&lt;p&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/DevExpress_5F00_776005CE.jpg"&gt;&lt;img border="0" align="left" width="244" src="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/DevExpress_5F00_thumb_5F00_6271140C.jpg" alt="DevExpress" height="123" style="border-right:0px;border-top:0px;display:inline;margin:0px 10px 10px 0px;border-left:0px;border-bottom:0px;" title="DevExpress" /&gt;&lt;/a&gt;:-) &lt;br /&gt;Hola de nuevo,&lt;/p&gt;
&lt;p&gt;Hoy os voy a mostrar un peque&amp;ntilde;o tip, muy &amp;uacute;til si trabaj&amp;aacute;is con este fant&amp;aacute;stico control.&lt;/p&gt;
&lt;p&gt;En muchas ocasiones nos encontramos con la necesidad de mostrar una serie de registros de una tabla, y tambi&amp;eacute;n queremos mostrar informaci&amp;oacute;n de otras tablas relacionadas. En estos casos existen varias soluciones: Leer los datos de ambas tablas con una instrucci&amp;oacute;n JOIN en la base de datos y mostrar la informaci&amp;oacute;n extendida en el grid, agregar a la vista un &amp;lsquo;&lt;strong&gt;ColumnEdit&lt;/strong&gt;&amp;rsquo; de tipo ComboBox o LookUpEdit y cargar los datos de la tabla relacionada, interceptar el evento &amp;lsquo;CustomColumnDisplayText&amp;rsquo; de la columna y mostrar los valores que deseemos, y unos cuantos m&amp;aacute;s que no comentaremos aqu&amp;iacute;.&lt;/p&gt;
&lt;p&gt;Sin embargo existe una soluci&amp;oacute;n mucho m&amp;aacute;s sencilla (aunque no he encontrado nada de documentaci&amp;oacute;n al respecto). Se trata de extender la propiedad &lt;strong&gt;FieldName&lt;/strong&gt; de la columna siguiendo el esquema de nuestro DataContext (LINQ to SQL) o Model (LINQ to EF).&lt;/p&gt;
&lt;p&gt;Partiendo de la base de que disponemos de un modelo o un contexto de datos como el siguiente:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/Northwind_5F00_products_5F00_datacontext_5F00_78C6B951.png"&gt;&lt;img border="0" width="508" src="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/Northwind_5F00_products_5F00_datacontext_5F00_thumb_5F00_3173F410.png" alt="Northwind_products_datacontext" height="462" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="Northwind_products_datacontext" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;Y deseamos obtener el resultado siguiente (observar que las columnas &amp;lsquo;Category&amp;rsquo; y &amp;lsquo;Supplier&amp;rsquo; muestran valores de las tablas relacionadas):&lt;/p&gt;
&lt;p&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/northwind_5F00_products_5F00_form_5F00_310A51CC.png"&gt;&lt;img border="0" width="647" src="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/northwind_5F00_products_5F00_form_5F00_thumb_5F00_7CFAD3DA.png" alt="northwind_products_form" height="393" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="northwind_products_form" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;Pues es tan sencillo (*) como establecer la propiedad &lt;strong&gt;FieldName&lt;/strong&gt; de la columna, escribiendo el nombre del campo completo incluyendo los nombres de los objetos relacionados (en nuestro caso &lt;strong&gt;Category.CategoryName&lt;/strong&gt; y &lt;strong&gt;Supplier.CompanyName&lt;/strong&gt;). Nota: Es posible extender esto encadenando las clases de nuestro modelo (yo por lo menos he llegado a encadenar hasta 4 tablas).&lt;/p&gt;
&lt;p&gt;Y lo que m&amp;aacute;s me gusta de esta soluci&amp;oacute;n respecto a las otras es que permite incluso el filtrado de los resultados, algo que cuando hacemos interceptando el evento &amp;lsquo;CustomColumnDisplayText&amp;rsquo; no es posible.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/northwind_5F00_products_5F00_filtered_5F00_70FB7457.png"&gt;&lt;img border="0" width="346" src="http://msmvps.com/cfs-file.ashx/__key/CommunityServer.Blogs.Components.WeblogFiles/lfranco/northwind_5F00_products_5F00_filtered_5F00_thumb_5F00_4067F69F.png" alt="northwind_products_filtered" height="236" style="border-right:0px;border-top:0px;display:inline;border-left:0px;border-bottom:0px;" title="northwind_products_filtered" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;En fin, si alguien no conoc&amp;iacute;a este tip y usa este control, espero que le sea &amp;uacute;til&amp;hellip;&lt;/p&gt;
&lt;p&gt;Saludos desde Andorra,&lt;/p&gt;
&lt;p&gt;L&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Nota: Olvid&amp;eacute; mencionar que esta soluci&amp;oacute;n es idela para aquellos formularios de consulta, no en modo de entrada de datos (entonces usar&amp;iacute;amos un LookUpEdit).&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;(*) Supongo que es necesario que est&amp;eacute; activada la carga diferida, algo que en LINQ to SQL es as&amp;iacute; de forma predeterminada, aunque no en EF.&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1665016" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2008/default.aspx">2008</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Devexpress/default.aspx">Devexpress</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Tip/default.aspx">Tip</category></item><item><title>Material del evento: Asentando las bases</title><link>http://msmvps.com/blogs/lfranco/archive/2008/12/30/material-del-evento-asentando-las-bases.aspx</link><pubDate>Tue, 30 Dec 2008 10:34:04 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1658074</guid><dc:creator>lfranco</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://msmvps.com/blogs/lfranco/rsscomments.aspx?PostID=1658074</wfw:commentRss><comments>http://msmvps.com/blogs/lfranco/archive/2008/12/30/material-del-evento-asentando-las-bases.aspx#comments</comments><description>&lt;p&gt;Ayer tuvimos el último evento del año en &lt;a href="http://andorradotnet.com/"&gt;AndorraDotNet&lt;/a&gt;. Mientras llegan las fotos que hicieron algunos de los asistentes, aprovecho para publicar el material del evento, tanto la presentación como los proyectos de ejemplo.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;a href="http://andorradotnet.com/blogs/anug/image_296F1993.png"&gt;&lt;img title="image" height="184" alt="image" src="http://andorradotnet.com/blogs/anug/image_thumb_38CCBE66.png" width="244" border="0" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;La presentación la encontraréis aquí:&lt;/p&gt;  &lt;p&gt;&lt;iframe style="border-right:#dde5e9 1px solid;padding-right:0px;border-top:#dde5e9 1px solid;padding-left:0px;padding-bottom:0px;margin:3px;border-left:#dde5e9 1px solid;width:240px;padding-top:0px;border-bottom:#dde5e9 1px solid;height:66px;background-color:#ffffff;" src="http://cid-f3a970280830b5fe.skydrive.live.com/embedrowdetail.aspx/P%c3%bablico/AndorraDotNet/Events/PPTS/AndorraDotNet%7C_Event4%7C_AssentantBases[1].pptx" frameborder="0" scrolling="no"&gt;&lt;/iframe&gt;&lt;/p&gt;  &lt;p&gt;Y la solución de Visual Studio aquí:&lt;/p&gt;  &lt;p&gt;&lt;iframe style="border-right:#dde5e9 1px solid;padding-right:0px;border-top:#dde5e9 1px solid;padding-left:0px;padding-bottom:0px;margin:3px;border-left:#dde5e9 1px solid;width:240px;padding-top:0px;border-bottom:#dde5e9 1px solid;height:66px;background-color:#ffffff;" src="http://cid-f3a970280830b5fe.skydrive.live.com/embedrowdetail.aspx/P%c3%bablico/AndorraDotNet/Events/Code/TestDemosAndorraDotNet.zip" frameborder="0" scrolling="no"&gt;&lt;/iframe&gt;&lt;/p&gt;  &lt;p&gt;Gracias por todo y nos vemos pronto!&lt;/p&gt;
** crossposting desde el blog de Lluís Franco en geeks.ms **&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1658074" width="1" height="1"&gt;</description><category domain="http://msmvps.com/blogs/lfranco/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/.NET/default.aspx">.NET</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/2008/default.aspx">2008</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Visual+Studio/default.aspx">Visual Studio</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Event/default.aspx">Event</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/Grupo/default.aspx">Grupo</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/AndorraDotNet/default.aspx">AndorraDotNet</category><category domain="http://msmvps.com/blogs/lfranco/archive/tags/LINQ/default.aspx">LINQ</category></item></channel></rss>