title: Strange interaction between R package XLConnect and choose.files()
body: <p>I observe the following strange behaviour:</p>
  
  <p>Using the R-console (2.15.2, Windows 7, 32 bit), I get:</p>
  
  <pre><code>&gt; choose.files() # works fine here
  character(0)
  &gt; library(XLConnect)
  Lade nötiges Paket: XLConnectJars
  Lade nötiges Paket: rJava
  Error : .onLoad in loadNamespace() für 'XLConnectJars' fehlgeschlagen, Details:
    Aufruf: .jinit()
    Fehler: Cannot create Java virtual machine (-4)
  Zusätzlich: Warnmeldung:
  Paket ‘rJava’ wurde unter R Version 2.15.3 erstellt 
  Fehler: Paket ‘XLConnectJars’ konnte nicht geladen werden
  </code></pre>
  
  <p>The choose.files() call works fine (I just clicked "Cancel"), but obviously XLConnect could not be loaded due to some JVM related problem.</p>
  
  <p>Now, restarting the R-console and issuing the same two commands in different order:</p>
  
  <pre><code>&gt; library(XLConnect)
  Lade nötiges Paket: XLConnectJars
  Lade nötiges Paket: rJava
  XLConnect 0.2-4 by Mirai Solutions GmbH
  http://www.mirai-solutions.com ,
  http://miraisolutions.wordpress.com
  Warnmeldung:
  Paket ‘rJava’ wurde unter R Version 2.15.3 erstellt 
  &gt; choose.files() # returns after a few seconds without ever displaying a file choser
  character(0)
  </code></pre>
  
  <p>So the XLConnect package loads fine, but the choose.files() call never displays a file chooser and returns "character(0)" after some seconds.
  When I run the same code in R-Studio, everything works fine in both ways.</p>
  
  <p>I already tried to increase the Java heap space (as I found this hint in some other threads/forums) but it did not help.</p>
  
  <p>Any explanations or tips how to solve that problem?</p>