Solved

Delphi Crashes on installing Package

Posted on 1998-07-08
6
328 Views
Last Modified: 2010-04-04
I have a package using Unit A and B.
Both uses some other Units. There are no Circular References. If I Compile the units in a program (no Package) everything is fine.
if I want to install the Package I get the Error
Access Violation at address xxx reading address 0000.

For Testing I removed all Code except the Uses Statement and the Crash occurs.
If I remove Uses A in Unit B everything is fine.
I tied Uses in Interface an in implementation part.
I Use Delphi 3.01.

What can be wrong?


0
Comment
Question by:WernerMairl
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 3

Expert Comment

by:vladika
ID: 1357298
Write unit code, please
0
 
LVL 5

Expert Comment

by:ronit051397
ID: 1357299
Check if there is an Initialization section in the unit (in the uses) which causes the crash.
0
 
LVL 1

Expert Comment

by:Marcius
ID: 1357300
I had a similar problem a couple of months ago. My problem was called by a copy of the unit being stored somewhere else on disk. Once I deleted this copy, everything was fine.

So, check that you have one and only one copy of the unit you are using on disk or on the network in your search path. If you have, delete all instances except the one you are using.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 1

Expert Comment

by:Greedy
ID: 1357301
it might be something like your trying to install a run time package, that will generate a Access Violation...Go to the requires tab and remove everthing in it click compile and see what it tells you it added and then see if one of them packages is causeing the problem...you may want to delete off the runtime packages that it requires and rebuild them (save them to a back up just in case :)
0
 
LVL 3

Accepted Solution

by:
AndreasSchindler earned 200 total points
ID: 1357302
Check initialisation of all (implicit) included Units.
If your Programm works when ist is compiled normally and crashes if you install the Package, I think the initialisation of the Units depend on a order of loading.
When you compile the package, the units are loaded in a different order so the "second" initialisation is executed before the "first" one and causes the Crash.

Make sure that each initialisation works in any loading order of the Units.

0
 

Author Comment

by:WernerMairl
ID: 1357303
I created a global TStriglist in one initialisation and accessed from another.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
Suggested Courses
Course of the Month9 days, 23 hours left to enroll

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question