title: AMO-Assembly takes long to initialize when compiling for .net 3.5
body: <p>I am developing a small application in c# to administrate Analysis Services cube partitions using the Analysis Services Management Object Model (AMO). Therefore, my application uses the assembly <code>Microsoft.AnalysisServices.dll</code> as it is deployed with SQL Server 2008 R2 or 2012. When I set .net 4.0 or 4.5 as the target framework, everything works fine. However, the target system only has 3.5 available (We have to live with this), and when I set this as the target framework, the instruction</p>
  
  <p><code>Server OLAPServer = new Server();</code></p>
  
  <p>takes about 10 seconds. During this time, my application window freezes. Afterwards, I can successfully <code>.connect()</code> to my local SSAS instance.</p>
  
  <p>It doesn't matter if I use the dll of SQL Server 2008 R2 or 2012, the problem happens with both. When I change to target framework 4.0 or 4.5, the initialization is done in less than one second. If this matters, I am using Visual Studio 2012.</p>
  
  <p>What is happening during this time? Can it be shortened while still using .net 3.5?</p>
  
  <p>I could move the initialization to a separate thread to avoid that the window is going to freeze. But I would prefer a solution where it doesn't take so long to initialize.</p>
  
  <p>Thanks for your help!</p>