AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Thema durchsuchen
Ansicht
Themen-Optionen

My Delphi 2010 is sick

Ein Thema von WojTec · begonnen am 4. Jul 2012 · letzter Beitrag vom 9. Jul 2012
Antwort Antwort
WojTec

Registriert seit: 17. Mai 2007
482 Beiträge
 
Delphi XE6 Professional
 
#1

Re: My Delphi 2010 is sick

  Alt 4. Jul 2012, 19:51
So, I have custom constructor, I'm setting components in this constructor, all what happen later depend on these settings - and working, till I add this check box or combo box (I tried both).

For example I'm drawing gradient, in method I'm using cbPath.Checked - working.
When I add this condition then stop working

Code:
---------------------------
Debugger Exception Notification
---------------------------
Project x.exe raised exception class EAccessViolation with message 'Access violation at address 0062DCF7 in module 'x.exe'. Read of address 00000000'.
---------------------------
Break  Continue  Help  
---------------------------
Code:
---------------------------
Debugger Exception Notification
---------------------------
Project x.exe raised exception class EReadError with message 'Error reading edtSteps.SpinOptions.MinValue: Access violation at address 0062DCF7 in module 'x.exe'. Read of address 00000000'.
---------------------------
Break  Continue  Help  
---------------------------
This behaviour is completely nonesense for me...

  Mit Zitat antworten Zitat
Benutzerbild von himitsu
himitsu

Registriert seit: 11. Okt 2003
Ort: Elbflorenz
44.342 Beiträge
 
Delphi 12 Athens
 
#2

AW: Re: My Delphi 2010 is sick

  Alt 4. Jul 2012, 22:47
address 00000xxx = nil

Something does not exist.

Probably cbPath has not yet been created. Check it by adding "IF cbPath <> NIL" to the first line.
or if not Assigned(cbPath) then DoError; , Assert(Assigned(cbPath)); , Assert(cbPath <> nil); , ...
Ein Therapeut entspricht 1024 Gigapeut.

Geändert von himitsu ( 4. Jul 2012 um 22:49 Uhr)
  Mit Zitat antworten Zitat
WojTec

Registriert seit: 17. Mai 2007
482 Beiträge
 
Delphi XE6 Professional
 
#3

Re: My Delphi 2010 is sick

  Alt 5. Jul 2012, 09:03
@himitsu, you are talking about first or second address in message?

Let's say Delphi creates it incorrectly (I repeat: error after changes, before working) - what to do?
  Mit Zitat antworten Zitat
mkinzler
(Moderator)

Registriert seit: 9. Dez 2005
Ort: Heilbronn
39.874 Beiträge
 
Delphi 11 Alexandria
 
#4

AW: My Delphi 2010 is sick

  Alt 5. Jul 2012, 09:27
The second. The First is the adress of the Code itself.
Markus Kinzler
  Mit Zitat antworten Zitat
WojTec

Registriert seit: 17. Mai 2007
482 Beiträge
 
Delphi XE6 Professional
 
#5

Re: My Delphi 2010 is sick

  Alt 5. Jul 2012, 09:35
Ok. So, what to do now?
  Mit Zitat antworten Zitat
mkinzler
(Moderator)

Registriert seit: 9. Dez 2005
Ort: Heilbronn
39.874 Beiträge
 
Delphi 11 Alexandria
 
#6

AW: My Delphi 2010 is sick

  Alt 5. Jul 2012, 09:38
cbPath references not an existing Object. It seems that it is never set at all ( 0 = nil = nirvana)
Check if/where you set that variable.
Markus Kinzler
  Mit Zitat antworten Zitat
Benutzerbild von Stevie
Stevie

Registriert seit: 12. Aug 2003
Ort: Soest
4.045 Beiträge
 
Delphi 10.1 Berlin Enterprise
 
#7

AW: My Delphi 2010 is sick

  Alt 5. Jul 2012, 11:56
Your dfm file does not match the pas file.

When loading the form it streams the dfm file and creates the components and places the references in the published fields if they exist (yes, you can have a component on your form but no field in your pas file, if you don't need to access it). But it does not work the other way around. If you placed your component field in the published part (which is by default if you dont specify the visibility) but never created it yourself.

Usually the IDE also complains about this when saving your form (like "Field Form1.CheckBox1 does not have a corresponding component. Remove the declaration?")

Also: did you call inherited in your custom constructor?
Stefan
“Simplicity, carried to the extreme, becomes elegance.” Jon Franklin

Delphi Sorcery - DSharp - Spring4D - TestInsight
  Mit Zitat antworten Zitat
Antwort Antwort


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 17:11 Uhr.
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz