ClickOnce, app-install from the web fails on a clean XP Prof. SP3...


Author
Message
Ralph Rutschmann
Ralph Rutschmann
StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)
Group: Forum Members
Posts: 69, Visits: 1.3K
Hi,

surely I'm doing something really stupid...

I did a few tests to install my App after deploying through ClickOnce to a web page:

http://www.systemhaus-alber.de/waupdate/brainspark/

It always worked as expected. Untill I tried to install the app from the web directly to a clean machine with XP Prof. SP3. It installs the .NET-Framework 2.0 and SQLExpress, but then it fails to install my app, telling me that there first have to be the assembly 'Microsoft.SqlServer.Dmf Version 10.0.0.0' installed into the GAC.

After looking at the GAC, all versions there are 9.0.242.0 on a clean XP. On a clean Vista Ultimate it is all at version 10.0.0.0, but I tried not to install under Vista, because I want my app to run on XP also.

So I looked at my development machine, witch is XP Prof. SP3, and there are both versions in the GAC. Therefore no error while testing the install of my app, I think. Don't know from where I got the version 10.0.0.0 ones on my XP machine, what I could have installed to have them there...

At the source code of SF I found no suspect references to such an assembly. So I decided to install VS and SF at the clean machine with XP Prof. SP3. Now I have an error message as soon as I try to change the connection string through the appropriate SF-dialog, which I call from a menu_click() like that:

//-- Change the connection string
if (ConnectionManager.ShowAvailableConnectionStrings())
{     //-- Set the connection string
      ConnectionManager.SetConnections();}

The the called ConnectionManager is the original and untouched SF-ConnectionManager.

The error message is now:

-----------------------------------------------------------------

FileNotFoundException
  Die Datei oder Assembly Microsoft.SqlServer.Smo, Version=10.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91 oder eine Abhängigkeit davon wurde nicht gefunden. Das System kann die angegebene Datei nicht finden.
FileNotFoundException
  Die Datei oder Assembly Microsoft.SqlServer.Smo, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91 oder eine Abhängigkeit davon wurde nicht gefunden. Das System kann die angegebene Datei nicht finden.

Source     : MicroFour StrataFrame UI

Stack Trace:
   bei MicroFour.StrataFrame.DBEngine.SQL.SQLServerSchema..ctor()
   bei MicroFour.StrataFrame.Data.SQLServerConnectionPage..ctor()
   bei MicroFour.StrataFrame.Data.ConnectionWizard.LoadRequiredPages()
   bei MicroFour.StrataFrame.Data.ConnectionWizard..ctor(RequiredDataSourceCollection RequiredItems, Int32 ApplicationPK, Boolean PersistData)
   bei MicroFour.StrataFrame.Data.ConnectionWizard..ctor(RequiredDataSourceCollection RequiredItems, Int32 ApplicationPK)
   bei MicroFour.StrataFrame.Data.ConnectionManager.ShowConnectionWizard(Int32 ApplicationPK)
   bei MicroFour.StrataFrame.Data.ConnectionManager.ShowConnectionWizard()
   bei MicroFour.StrataFrame.Data.DBEShowApplicationConnectionStrings.cmdAdd_Click(Object sender, EventArgs e)
   bei System.Windows.Forms.Control.OnClick(EventArgs e)
   bei System.Windows.Forms.Button.OnClick(EventArgs e)
   bei System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
   bei System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   bei System.Windows.Forms.Control.WndProc(Message& m)
   bei System.Windows.Forms.ButtonBase.WndProc(Message& m)
   bei System.Windows.Forms.Button.WndProc(Message& m)
   bei System.Windows.Forms.Control.ControlNativewindow.OnMessage(Message& m)
   bei System.Windows.Forms.Control.ControlNativewindow.WndProc(Message& m)
   bei System.Windows.Forms.Nativewindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

-----------------------------------------------------------------

Oh yes, on the clean machine there are only assemblies with the version 9.0.242.0 and not 10.0.0.0. On my development machine with both versions in the GAC it works, but this is not what I want, because some of my customers may not have both versions on there machines.

The references at the SF-SourceCode do not point to any 10.0.0.0 version, so recompiling and 'AfterBuild'ing (running the AfterBuild.bat), looking hard to secure all assemblies on the machine are at the same level in every subdirectory and the GAC did not help.

Any hint where I could look next?

TIA, Ralph

Dustin Taylor
Dustin Taylor
StrataFrame Team Member (652 reputation)
Group: StrataFrame Users
Posts: 364, Visits: 771
10.0 is SQL Server 2008. Are you trying to use server 2008 in your application? If so, you'll need to load the smo objects for 2008 (or ensure that they are loaded) as part of your installation before deploying your appilcation.
Ralph Rutschmann
Ralph Rutschmann
StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)
Group: Forum Members
Posts: 69, Visits: 1.3K
Hello Dustin,

Dustin Taylor (09/29/2008)
10.0 is SQL Server 2008. Are you trying to use server 2008 in your application? If so, you'll need to load the smo objects for 2008 (or ensure that they are loaded) as part of your installation before deploying your application.

My prerequisites are .NET Framework 2.0, Windows Installer 3.1 and SQLExpress 2005. I have no SQL 2008 on no machine in no version. I know there is a SQLExpress 2008 somewhere, but I don't want to complicate my life without any need. Attached is a screen shot, showing where my app stops with an error message in debugging mode on a clean machine, XP Prof. SP3 (no 10.0.0.0 assemblies). To me it seems to point to SF, but I could be wrong. But if I'm wrong, I don't know what I could do. I have no references to a 10.0.0.0 assembly in my app and I found no such thing in SF source code. All I use is SQLExpress 2005 and StrataFrame. And Visual Studio, of course. ;-)

It worked all as it should a until a few day ago and I did all tests since then on my development machine. Now I found something went broken meanwhile. Could it have something to do with one of the last builds? Do you think it could have something to do with that?

Maybe the screen shot helps to identify the problem...

Thank you very much for any help.

Friendly greetings, Ralph

Attachments
FileNotFoundExeprtion.jpg (233 views, 329.00 KB)
Ralph Rutschmann
Ralph Rutschmann
StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)StrataFrame User (131 reputation)
Group: Forum Members
Posts: 69, Visits: 1.3K
Hi Dustin,

it's me again. I knew I did something really stupid. The following I found in my app.config:

<runtime>
  <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
   <dependentAssembly>
    <assemblyIdentity name="Microsoft.SqlServer.ConnectionInfo" publicKeyToken="89845DCD8080CC91" culture="neutral"/>
    <bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0"/>
   </dependentAssembly>
   <dependentAssembly>
    <assemblyIdentity name="Microsoft.SqlServer.ServiceBrokerEnum" publicKeyToken="89845DCD8080CC91" culture="neutral"/>
    <bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0"/>
   </dependentAssembly>
   <dependentAssembly>
    <assemblyIdentity name="Microsoft.SqlServer.Smo" publicKeyToken="89845DCD8080CC91" culture="neutral"/>
    <bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0"/>
   </dependentAssembly>
   <dependentAssembly>
    <assemblyIdentity name="Microsoft.SqlServer.SqlEnum" publicKeyToken="89845DCD8080CC91" culture="neutral"/>
    <bindingRedirect oldVersion="0.0.0.0-10.0.0.0" newVersion="10.0.0.0"/>
   </dependentAssembly>
  </assemblyBinding>
 </runtime>

As I remember, I was asked from VS if I want to have corrected some conflicts between assembly versions, and I clicked on 'Yes'. Thus the above snipped was added do my app.config.

Now I had a look at my software installations. Guess what? Right, I did apparently something really stupid or it was any of my lastly installed softwares, but there was an entry named: 'Microsoft SQL Server 2008 Management Objects'.

Deleting the above code snippet from my app.config, deinstallation for the 'Management Objects' and it works all as it should! :-)

It seems I got to be pointed into the wrong direction by the error messages of VS.

Sorry for any trouble I may have caused. I don't know where this Management Objects where coming from. I will see which application the deinstallation of that beast breaks, or even not.

Thank you very much.

Friendly greetings, Ralph

Dustin Taylor
Dustin Taylor
StrataFrame Team Member (652 reputation)
Group: StrataFrame Users
Posts: 364, Visits: 771
That certainly explains it Smile. Glad you got it going!
Matthew Phillips
Matthew Phillips
StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)StrataFrame Beginner (1 reputation)
Group: Forum Members
Posts: 1, Visits: 1
Sirs, I am hoping we can reopen this thread.  I am having the very same problem, however when I checked my app.config file, I found no such references to version 10 of these assemblies.  My development server does have this version of sql server installed.  The only ClickOnce prerequesite that I have is .NET 2.0, nothing else.  Any other ideas where this might be coming in?
Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
Well...this is one of the flaws of ClickOnce...I am not a big fan (which can be discovered on other threads).  This is one of this types of issues that can come from a large number of different things and doesn't actually relate to SF.  However, if you want to post more information in regards to your specific errors, maybe something can be gleamed from what you are running into.
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search