<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	>

<channel>
	<title>ToM's Blog</title>
	<atom:link href="http://www.lionsdomain.ch/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://www.lionsdomain.ch</link>
	<description>Hello, World ! :-)</description>
	<pubDate>Mon, 02 Nov 2009 23:10:55 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Checking if cell is in edit mode</title>
		<link>http://www.lionsdomain.ch/?p=115</link>
		<comments>http://www.lionsdomain.ch/?p=115#comments</comments>
		<pubDate>Wed, 15 Jul 2009 22:31:22 +0000</pubDate>
		<dc:creator>ToM</dc:creator>
		
		<category><![CDATA[VSTO Excel]]></category>

		<guid isPermaLink="false">http://www.lionsdomain.ch/?p=115</guid>
		<description><![CDATA[We observed a very strange behaviour while updating cells when the user is currently editing a cell.
After doing some research on the net it seems that the only solution to determine if the cell is in edit mode is a very strange hack  
Obviously, the Application object has a method called GoTo(Range) to navigate [...]]]></description>
			<content:encoded><![CDATA[<p>We observed a very strange behaviour while updating cells when the user is currently editing a cell.</p>
<p>After doing some research on the net it seems that the only solution to determine if the cell is in edit mode is a very strange hack <img src='http://www.lionsdomain.ch/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Obviously, the Application object has a method called GoTo(Range) to navigate to some areas. Somehow throws this method a special exception if it&#8217;s in edit mode. So the strange solution so far is to call Application.GoTo(&#8221;###&#8221;) and see what kind of exception it throws <img src='http://www.lionsdomain.ch/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<pre class="brush: csharp;">
protected bool isInEditMode()
{
   try
   {
      this.Application.Goto(&quot;###&quot;, false);
   }
   catch (Exception ex)
   {
      if (ex.Message.StartsWith(&quot;Reference is not valid&quot;))
        return false;
      else
        return true;
   }
   return false;
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.lionsdomain.ch/?feed=rss2&amp;p=115</wfw:commentRss>
		</item>
		<item>
		<title>Orange Internet Everywhere</title>
		<link>http://www.lionsdomain.ch/?p=109</link>
		<comments>http://www.lionsdomain.ch/?p=109#comments</comments>
		<pubDate>Mon, 13 Jul 2009 11:58:55 +0000</pubDate>
		<dc:creator>ToM</dc:creator>
		
		<category><![CDATA[Off-Topic]]></category>

		<guid isPermaLink="false">http://www.lionsdomain.ch/?p=109</guid>
		<description><![CDATA[Nachdem ich mich nun wochenlang mit einem ICON 225 Adapter von Orange für Ihr Produkt &#8220;Internet Everywhere&#8221; rumgeärgert habe, dachte ich mir es ist mal an der Zeit einen kleinen Erfahrungsbericht zu schreiben.
Die ganze Geschichte hat so angefangen, dass ich längere Zeit zu einem Kunden musste um dort vor Ort zu arbeiten. Da die Security [...]]]></description>
			<content:encoded><![CDATA[<p>Nachdem ich mich nun wochenlang mit einem ICON 225 Adapter von Orange für Ihr Produkt &#8220;Internet Everywhere&#8221; rumgeärgert habe, dachte ich mir es ist mal an der Zeit einen kleinen Erfahrungsbericht zu schreiben.</p>
<p>Die ganze Geschichte hat so angefangen, dass ich längere Zeit zu einem Kunden musste um dort vor Ort zu arbeiten. Da die Security dort relativ strikt gehandhabt wird haben wir beschlossen, besagten USB Stick zu organisieren um mir zu ermöglichen, den Source Code via Memory Stick vom Rechner des Kunden auf mein Laptop zu kopieren und dort via Internet auf unserem Subversion Server einzuchecken.</p>
<p>Soweit so gut. Schnell stellte ich aber fest, dass es praktisch unmöglich ist, mit dem ICON 225 eine sinnvolle Verbindung zu erhalten. Sei dies mitten in Oerlikon oder im Herzen von Altstetten. Kurz gesagt egal wo ich war, es klappte nicht. Sollte es denn nach zehn Verbindungsversuchen zufällig mal klappen, liegt der Speed so ca. bei 800 B/s, für eine Weile&#8230;&#8221;eine Weile&#8221; deshalb, weil die Connection sogleich wieder abreisst, also wenn man Glück hat kann man eine SSH Connection zu einem Server aufbauen, die spätestens 30 Sekunden später wirder getrennt wird. Wenn man nur im Web surft muss man halt mit dem Abreissen der Connections leben.</p>
<p>Heute früh kam ich ins Büro und der Stick hat bereits nach drei Versuchen eine Connection. Juhu. Als ich dann ein Mail verschicken will schmeisst mich der Server raus weil er finden meine von Orange bezogene IP-Adresse sei auf diversen Spam-Blacklists. Also kein Mail heute.</p>
<p>Zwischenzeitlich brauche ich mindestens eine Stunde pro Tag um abverreckte SVN Checkins wieder zu reparieren, ja um überhaupt eine Connection zu bekommen. Eigentlich würde der ganze Task fünf Minuten dauern.</p>
<p>Schliesslich habe ich entnervt den Orange Support angerufen. Nachdem ich dann nach längerem hin und her tatsächlich mit einem echten Menschen sprechen konnte sagt mir dieser, ich sei ja selbst Schuld wenn ich mich auf so ein Produkt verlassen würde beim Arbeiten. Das sei nicht dafür gedacht und überhaupt ich könne froh sein wenn ich überhaupt eine Verbindung bekommen würde, das sei halt ein sehr neues Produkt und noch vor sechs Monaten wäre es praktisch unmöglich gewesen sich irgendwie einzuwählen.</p>
<p>Fazit: Orange Internet Everywhere scheint ein Produkt zu sein, dass stark  beworben wird, in der Praxis aber absolut versagt hat, und damit meine ich komplett unbrauchbar. Was nützt mir so ein Teil wenn es doch nicht funktioniert ? Aber am schlimmsten ist ja schon das Orange genau weiss das es da enorme Probleme gibt, weiterhin fleissig Werbung macht und dem Kunden dann noch ins Gesicht sagt man sei ja selbst schuld wenn man ihre Produkte verwenden würde. LOOOOOL wie dämlich ist denn das ?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.lionsdomain.ch/?feed=rss2&amp;p=109</wfw:commentRss>
		</item>
		<item>
		<title>UDF Registration</title>
		<link>http://www.lionsdomain.ch/?p=22</link>
		<comments>http://www.lionsdomain.ch/?p=22#comments</comments>
		<pubDate>Wed, 01 Apr 2009 20:53:20 +0000</pubDate>
		<dc:creator>ToM</dc:creator>
		
		<category><![CDATA[UDF]]></category>

		<guid isPermaLink="false">http://www.lionsdomain.ch/?p=22</guid>
		<description><![CDATA[There are two ways to register an User Defined Formula in Excel:

Register it through the registry by adding the necessary keys, or
Load it programatically during runtime

Registering  during setup using the registry
To register the UDF during the setup process, you need to add a custom action to your setup project and add a key to
HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\Excel\Options
The name [...]]]></description>
			<content:encoded><![CDATA[<p>There are two ways to register an User Defined Formula in Excel:</p>
<ul>
<li>Register it through the registry by adding the necessary keys, or</li>
<li>Load it programatically during runtime</li>
</ul>
<p><strong>Registering  during setup using the registry</strong></p>
<p>To register the UDF during the setup process, you need to add a custom action to your setup project and add a key to</p>
<p><em>HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\Excel\Options</em></p>
<p>The name of the key is OPEN[ID], while ID is an incrementing number. You therefore need to find an unused number and add the respective key. For example, if you have keys called OPEN1 and OPEN2, just call the new key OPEN3. If no OPEN[id] keys are defined at all, just call it OPEN. Set the added key&#8217;s value to &#8220;/A [ProgID of your add-in]&#8220;.</p>
<p><strong>Register during runtime</strong></p>
<p>This is my prefered solution because we also have a plugin loaded in Excel. This plugin registers the UDF dynamically at startup. To do so, we need to add two lines of code to the startup-method of the addin.</p>
<pre class="brush: csharp;">
using Excel = Microsoft.Office.Interop.Excel;
.
.
.
// Add the UDF to the loaded plugins.
Excel.AddIn addin = Application.AddIns.Add(&quot;UDF-progID&quot;);
// Set installed state to true.
addin.Installed = true;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.lionsdomain.ch/?feed=rss2&amp;p=22</wfw:commentRss>
		</item>
		<item>
		<title>Display VSTO Error Messages</title>
		<link>http://www.lionsdomain.ch/?p=12</link>
		<comments>http://www.lionsdomain.ch/?p=12#comments</comments>
		<pubDate>Wed, 01 Apr 2009 20:14:25 +0000</pubDate>
		<dc:creator>ToM</dc:creator>
		
		<category><![CDATA[Debugging Tips]]></category>

		<guid isPermaLink="false">http://www.lionsdomain.ch/?p=12</guid>
		<description><![CDATA[A very helpful trick is to set an user environment variable called VSTO_SUPPRESSDISPLAYALERTS to 0, this gives you more detailed information what&#8217;s going wrong during runtime.
]]></description>
			<content:encoded><![CDATA[<p>A very helpful trick is to set an user environment variable called <span style="font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; font-size: 11pt; mso-ascii-theme-font: minor-latin; mso-fareast-font-family: Calibri; mso-fareast-theme-font: minor-latin; mso-hansi-theme-font: minor-latin; mso-bidi-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-bidi; mso-ansi-language: DE-CH; mso-fareast-language: EN-US; mso-bidi-language: AR-SA;">VSTO_SUPPRESSDISPLAYALERTS </span>to 0, this gives you more detailed information what&#8217;s going wrong during runtime.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.lionsdomain.ch/?feed=rss2&amp;p=12</wfw:commentRss>
		</item>
		<item>
		<title>Debugging Assembly Problems</title>
		<link>http://www.lionsdomain.ch/?p=6</link>
		<comments>http://www.lionsdomain.ch/?p=6#comments</comments>
		<pubDate>Wed, 01 Apr 2009 19:55:07 +0000</pubDate>
		<dc:creator>ToM</dc:creator>
		
		<category><![CDATA[Debugging Tips]]></category>

		<guid isPermaLink="false">http://www.lionsdomain.ch/?p=6</guid>
		<description><![CDATA[If some of the components don&#8217;t load correctly and seem to do really nothing, you&#8217;ve a great chance that one or more of the required dependencies can&#8217;t be loaded.
Windows offers you a possibility to inspect what exactly happens when the assemblies are loaded (or not *g*)&#8230;The fusion log.
 
To enable the fusion log, create a directory [...]]]></description>
			<content:encoded><![CDATA[<p>If some of the components don&#8217;t load correctly and seem to do really nothing, you&#8217;ve a great chance that one or more of the required dependencies can&#8217;t be loaded.</p>
<p>Windows offers you a possibility to inspect what exactly happens when the assemblies are loaded (or not *g*)&#8230;The fusion log.</p>
<p> </p>
<p>To enable the fusion log, create a directory to retrieve the log&#8217;s output, let&#8217;s say c:\fusionlog.</p>
<p>Now, several registry keys need to be set in order to enable the logging:</p>
<ul>
<li>Set the path to your logfile directory in HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Fusion\LogPath (in our example c:\fusionlog)</li>
<li>Set HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Fusion\LogFailures to 1</li>
<li>Optionally set HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Fusion\ForceLog to 1</li>
<li>Optionally set HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Fusion\LogResourceBinds to 1</li>
</ul>
<p>There&#8217;s a tool called &#8220;Assembly Binding Log Viewer&#8221; available in the .NET Framework SDK, for more information look <a href="http://msdn.microsoft.com/en-us/library/e74a18c4(VS.80).aspx" target="_blank">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.lionsdomain.ch/?feed=rss2&amp;p=6</wfw:commentRss>
		</item>
	</channel>
</rss>
