tags:

views:

829

answers:

2

What is loaded into Delphi 2010 from a dsk file that could prevent Delphi 2010 from crashing when a project is loaded?

Let me explain. It is somewhat complicated.

When I installed Delphi 2010 I put it on a large USB Western Digital hard drive (R:) with only Delphi 2010, Delphi project folders and Delphi component folders on it.

I copied all of my projects and components to the USB drive in R:\Components and R:\Projects folders. I then removed all the *.dcu files and history folders and *.dsk files so that Delphi 2010 would load the correct files that I open from Drive R.

Then I installed nearly all of my components into Delphi 2010 from folders on Drive R and tested them all with out a problem. So far over the last 7 days I have not had a problem with any of the components or projects I installed from R drive. I had thought everything was just fine until I tried loading my VclZip projects into Delphi 2010 from Drive R.

After opening a project with vclzip component... all is fine for about 15-20 seconds... then without even touching the mouse or the keyboard Delphi totally crashes and i am left at the Vista desktop with a dialog what says an exception ocurred in bds.exe in the runtime debugger.

Trouble Shooting

If I copy the *.dsk file in the project folder from Drive D ( Delphi 2009 project folder) to the project folder on Drive R, Delphi 2010 opens the project from Drive R and it does not crash, but the wrong files from my Delphi 2009 projects folder on Drive D are loaded into the Tabs (I suspect as specified from the *.dsk file). If I close the tabs in the Delphi 2010 IDE with the incorrect files and reopen the files in the ide, by double clicking them in the project group Delphi does not crash and i can compile and run the project from Drive R in Delphi 2010 with no problems.

I have been working with Delphi since Delphi 1 and I have never seen this happen before among 10's of thousands of delphi projects over the years, but I must say I naver have installed a version of delphi on a usb drive before. The other thing that is strange is why do just projects with VclZip do this? No other projects of well over a 100-200 projects and demos compiled so far in Delphi 2010 act this way.

Obvously something is wrong but I have no idea what except maybe an environment path or some incompatable code in a component. Is there an environment path that could cause Delphi to crash? An official VCLZip component is not available yet but I suspect it will be done in several days. If the component is not causing the problem does anyone have any ideas or suggestions?

Hopefully I have explained this well enough for everyone to understand.

+4  A: 

The *.dsk contains nothing important, and will in fact cause problems when you copy it between folders/computers, as it specifies where to load recent files from. I don't synch *.dsk at all, and your safe to delete it.

The DSK file stores recent file locations, form positions, window positions, watches, other debugging info (breakpoints, etc.) and other settings that don't hurt too much to lose.

Zartog
+4  A: 

Components are loaded into the IDE process, so any error in a component can cause problems in the IDE. I guess there is something in the version of the VCLZip components you use that makes the IDE unstable and breaks it down. So this is a showstopper, indeed, but for the VCLZip components.

Like already said, .dsk files can be discarded and should not be copied over. I generally also don't copy the .dproj files over to other directories. I rather open the .dpk or .dpr files and have a new one generated. That ensures that all directories are set correctly with the defaults, etc.

Rudy Velthuis
Frank,I understand that .dsk files should not be used and I usually delete them as I explained. But do you have any idea why if the dsk file is used then Delphi does NOT crash when opening the project and it runs just fine.
Bill Miller