StrataFrame Forum

how to deploy an exe to another machine

http://forum.strataframe.net/Topic25063.aspx

By Ger Cannoll - 10/30/2009

I have a small app developed whcih I now want to deploy to another inhouse machine, just to see what's involved

I gather that I must copy the Microfour assemblies, my Business Object Assmbly and the .exe but am unsure where to locate the Microfour assemblies. Are there any other files that I need to copy ?

I see there are Startaframe files in a folder called c:\windows\assembly (but these do not have a .DLL extension). There are also Strataframe files in a folder called: c:\ProgramFiles\CommonFiles\Microfour\Strataframe (which do have a .DLL extension). Is one of these folders the correct place to get the Microfour assembly that I need to distribute with the App ?

At this stage I want to just copy the required files to the other machine.( if thats possible)  I realise on a live install this may not be the way to go ,but at this stage, I want to do all this stuff manually, more to get an understanding of what goes on under the hood

By Bill Cunnien - 10/30/2009

It should be pretty easy as long as the .NET Framework is already installed. I have a folder in the Program Files directory named after the app. Here is a list of files that are in this folder:



Program Files

MyApp

MyModel.dll (business objects)

MyApp.exe

MicroFour StrataFrame Base.dll

MicroFour StrataFrame Business.dll

MicroFour StrataFrame Inherited UI.dll

MicroFour StrataFrame Security.dll

MicroFour StrataFrame UI Expanded.dll

MicroFour StrataFrame UI.dll



I left the DevEx dll's out as well as some other 3rd party stuff. I have also implemented RBS so the security DLL may not be necessary for you. Create your folder (where ever you want), copy the files in and run it.



Have a wonderful day!

Bill
By Ger Cannoll - 10/30/2009

Hi Bill. Thanks for replying

Where do I get the Microfour DLLs from. There seems to be files in c:\windows\system (the GAC ?) which dont have a DLL extension and also Microfour Dlls in c:\ProgramFiles\Commonfiles\Microfour\Statatframe which do have a .DLL extension so I guess I take them from this folder ?

At this stage I am not sure exactly what the GAC is or how it is used

By Trent L. Taylor - 10/30/2009

You can get them from several places. You can use the MSM whichwould be in the directory you installed StrataFrame...or just get them from the common files which would be:



c:\program files\common files\microfour\strataframe




You may need to alter the path to accommodate the installation of your OS. On a 64-bit machine it would most likely be:



c:\program files(x86)\common files\microfour\strataframe
By Ger Cannoll - 10/30/2009

Thanks Trent. I can get them form c:\programfiles\Commonfiles......

What is an  MSM wildcard ?

By Greg McGuffey - 10/30/2009

I'm surprised that the SF dlls are just in you bin/debug (or release) folder. When I do this, I usually just do a release build, then copy the release folder to another machine.
By Ger Cannoll - 10/30/2009

I have copied the app to another pc (happens to be a server) and have run it from the server.

It asked me for the server name and database name and I input the details and it works fine from new machine(i.e server)

Hoever , if I set up a mapping on my development machine to the server folder , run the app from the server, it points back to the database on my development machine , rather than the server sql server

Where/how  do I change the connection string so that I can run the app thats sitting on the server now,  from my pc,  but look at the sql server database thats on the server.Is this held in a table somewhere that I can amend or do I have to manage this programatically

By Trent L. Taylor - 10/30/2009

What is an MSM wildcard ?




An MSM file is a pre-built collection or installation that can be added wholesale to an MSI installation. I will admit though, it is generally better to add the files individually as MSM add-ins can cause issues in certain environments.



Where/how do I change the connection string so that I can run the app thats sitting on the server now, from my pc, but look at the sql server database thats on the server.Is this held in a table somewhere that I can amend or do I have to manage this programatically




You will want to look at the documentation regarding the Connection String Manager as you can call the ConnectionManager.ShowAvailableConnectionString() to add new connection strings for an application allowing you to swap between development and production. This ties into the Connections.dat and the AppKeys.dat. All of this is in the docs and will provide more detail than I can supply here.
By Ger Cannoll - 11/2/2009

Ok . I have read docs and done some experimenting with ShowAvailableConnectionStrings() and SetConnections() and can change from one database to another on a form, by selecting a different Application Tilte. I still am a little bit hazy and would appreciate some guidance.

I am just starting to design the tables that go into the databases and an option is to end up with 3 different databases in the same Sql Server which will be used throughout the application. Fot the one application title, I have not been able to set up more than one database using ShowAvailableConnectionStrings.If I edit the the Application Settings, I seem to be just able to insert ONE database, whereas my application will be using 3. I can 'Select' just One application setting . In that my application is using 3 Databses, I would have epected to be able to 'Select' 3 items. Is it possible to do this or maybe I am barking up the wrong tree ?

Also, is there a way to easily change from Production to Live if I have 3 databases in the one application. I have manged to do this ok with one database by using ShowAvailableConnectionStrings()

By Dustin Taylor - 11/3/2009

To do that you would need to add multiple named datasources and then specify the proper connection when appropriate. You can certainly do that, but first, do you mind if I ask why the three seperate SQL databases are needed?  Is this a constraint of a pre-existing system (i.e. are they databases someone else created that you don't have the ability to combine?)
By Ger Cannoll - 11/3/2009

To do that you would need to add multiple named datasources and then specify the proper connection when appropriate. 

Do you mean that in each for, I would need to SetDataSource or something similar ?

why the three seperate SQL databases are needed?  Is this a constraint of a pre-existing system (i.e. are they databases someone else created that you don't have the ability to combine?)

There are two reasons:

1) In the old system, the tables were in separate databases, just a logical grouping more so than anything else, so this could be changed if its going to make the automatic switching of Production/Live or Company1/Company2/Company3 easier

2) The other reason was a cost saving issues. One of these Databses is a Data Warehosue type app where all the data from the other databases is sliced and diced and can end up to be quite large... up to 3/4 gigs. I may be wrong, but is'nt there a limit on Sql Express of 4 Gigs per database...so this was a way to keep the sizes manageable and not requiring the client to go out and having to buy full version of Sql Server