Trent,
I’ve done quite a bit of testing and in all cases I’ve been able to consistently reproduce the application exception I’ve been getting. It is important to note that the exception ONLY occurs on a SF Windows Application with Security. A standard SF Windows Application does not exhibit the problem.
The exception only happens on exiting the application if the Database Connection Wizard has been run in the current instance, either on startup where the applications data base has not yet been defined or if run from the File menu on a SF Main form. If run from the File menu you must run the wizard all the way through the Finish step for the exception to occur on exiting the application.
So far I haven’t been able to isolate the cause of this problem. It’s happening on every PC where I try to deploy an app as well as two development PCs that I’ve tested. To eliminate as many variables as possible, I’ve also done the following, once under Windows XP Pro SP2 and once using Windows 2000 Pro SP4. In both cases I received an exception (although at different locations depending on the OS). I could be missing something when I’m setting up the environment and building the test app, but I can’t see what it is. Maybe you can.
· Started with a Dell GX280 and reformatted the drive.
· Installed Windows XP Professional SP2 with no additional updates
· No anti-virus software installed on PC
· Installed VS2005 Professional, default install from Dec 2005 Microsoft volume licensing discs. No additional updates or patches installed.
· Installed SQL Server 2005 STD using Dec 2005 Microsoft volume licensing, all services installed. No additional patches or updates installed.
· Rebooted PC
· Installed SF v1.5 11/09/06 without DevExpress or Infragistics with StrataFrame DB on local SQL instance
· Created a Security project and added 1 user (used “MySecurityKey” for key)
· Ran DDT to create a database that includes 1 table + Security tables, no localization or message tables
· Deployed the new DB to the local SQL instance with the data from the Security project
· Created a new StrataFrame Windows project with security. No modifications to AppMain
· Replaced the standard form with a SF main form. Left name as Form1 with no code added
· No business objects were added to the project
· Ran program in designer
· In the connection wizard configured the app to use the new data base with Windows security.
· When the Authorization form is displayed, clicked on Exit
· Program throws an application exception (same as previous posts)
· Clicked on Stop Debugging.
· Re-Ran application
· When the Authorization form is displayed, clicked on Exit
· Application exited with no exception
· Re-Ran application
· Entered ID and password on Authorization form, clicked OK
· Main form is displayed
· Clicked on File, Database Connection menu
· Selected the current connection
· Clicked on Edit
· Ran through the Connection Wizard, leaving the information the same
· Clicked Cancel on the connection windows to close
· Closed the Main form to exit application
· Application exception raised
All the PCs where I’ve tested running the VS2005 design environment are Dell GX280 or GX620 systems. Deployed systems have been GX620s as well as no-name clones running either Windows XP SP2 or Windows 2000 Pro SP4.
After running the initial test of the bare bones XP machine, I applied all of the latest XP patches and SQL 2005 SP1. The results were still the same. As far as I’m aware there are no SPs for VS2005. I’ve tried using local databases and remote databases. I’ve even taken the development systems off the network. The results are always the same.
Any suggestions would be appreciated since the current situation is making deployment of SF applications very difficult (I’m using a shared configuration file). I haven’t tried it yet but I’m assuming that I could work around the issue by hard coding the connection string in AppMain.
-Larry