Recent

Author Topic: [solved?] "Error in TdefaultComponentEditor"  (Read 11276 times)

TurboRascal

  • Hero Member
  • *****
  • Posts: 672
  • "Good sysadmin. Bad programmer."™
[solved?] "Error in TdefaultComponentEditor"
« on: September 30, 2012, 01:45:33 am »
When I try to create an event handler (e.g. OnClick procedure for TButton) I get an error, the full text in the dialog is:

Quote
The component editor of class "TDefaultComponentEditor" has created the error:
"Unable to find method. Please fix the error shown in the message window, which is normally below the source editor."

The Message Window says:
Quote
/development/lazarus/lcl/lclclasses.pp(32,10) Error: unit not found: Classes

Version information: Lazarus 1.1 r38913M FPC 2.6.1 i386-linux-gtk 2

What gives?
« Last Edit: November 21, 2013, 11:16:37 pm by TurboRascal »
Regards, ArNy the Turbo Rascal
-
"The secret is to give them what they need, not what they want." - Scotty, STTNG:Relics

taazz

  • Hero Member
  • *****
  • Posts: 5368
Re: "Error in TdefaultComponentEditor"
« Reply #1 on: September 30, 2012, 04:45:52 am »
Had those my self a couple of times usually it was something I did on the source code forgot a";" char somewhere or something along those recently though it surfaced after I had use the "Add unit to uses clause" something wend wrong with that I had to remove the unit names delete the extra control from the form and put back up again.I didn't find out what exactly wend wrong the unit I added had nothing to do with the control that raised the problem.
Good judgement is the result of experience … Experience is the result of bad judgement.

OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64

TurboRascal

  • Hero Member
  • *****
  • Posts: 672
  • "Good sysadmin. Bad programmer."™
Re: "Error in TdefaultComponentEditor"
« Reply #2 on: September 30, 2012, 06:04:12 am »
This error happens all the time, and in fact before I write even one line of code (just dropped a component and double-clicked on the event). In 1.0 it does not happen, neither it did in previous trunk builds.

However similar errors do happen sometimes and the error messages can be misleading because they often point to a different part of code like you said. Unfortunately not the case here... In fact, and I forgot to mention this before, the code compiles fine, so definitely the problem is in the IDE only.
Regards, ArNy the Turbo Rascal
-
"The secret is to give them what they need, not what they want." - Scotty, STTNG:Relics

fabienwang

  • Sr. Member
  • ****
  • Posts: 449
  • Lazarus is the best
    • My blog
Re: "Error in TdefaultComponentEditor"
« Reply #3 on: September 30, 2012, 11:09:35 am »
Have you considered reinstalling lazarus ?
I'm using Arch Linux.
Known for: CPickSniff, OpenGrabby
Contributed to: LazPaint

TurboRascal

  • Hero Member
  • *****
  • Posts: 672
  • "Good sysadmin. Bad programmer."™
Re: "Error in TdefaultComponentEditor"
« Reply #4 on: September 30, 2012, 12:46:45 pm »
Have you considered reinstalling lazarus ?

Yes, I did it already... the first time this occured with an earlier SVN revision, a day or two ago. Then I got and compiled another revision and the same happens...
Regards, ArNy the Turbo Rascal
-
"The secret is to give them what they need, not what they want." - Scotty, STTNG:Relics

TurboRascal

  • Hero Member
  • *****
  • Posts: 672
  • "Good sysadmin. Bad programmer."™
Re: "Error in TdefaultComponentEditor"
« Reply #5 on: October 01, 2012, 06:10:39 am »
Got it. I needed to rescan FPC source. I guess something changed between revisions which required this.
Regards, ArNy the Turbo Rascal
-
"The secret is to give them what they need, not what they want." - Scotty, STTNG:Relics

DavidJameson

  • Newbie
  • Posts: 6
Re: [solved] "Error in TdefaultComponentEditor"
« Reply #6 on: October 22, 2013, 12:59:02 am »
This is NOT solved. I just downloaded latest Lazarus and fpc to a brand new iMac.

If I place a button on a form and double-click, I immediately get the error and Lazarus opens a window called Classes.

I tried the rescan FPC but that didn't help.

DavidJameson

  • Newbie
  • Posts: 6
Re: [solved] "Error in TdefaultComponentEditor"
« Reply #7 on: October 22, 2013, 01:01:01 am »
I did however just upgrade to Mavericks over the weekend - could that have screwed things up? That's the only change to my system.

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: [solved] "Error in TdefaultComponentEditor"
« Reply #8 on: October 22, 2013, 11:11:45 am »
@DavidJameson: what version do you mean? 1.0.12? Some other version?
What version of FPC? 2.6.2? Trunk?

Perhaps your development tools need to be reinstalled (just a guess):
http://wiki.lazarus.freepascal.org/OS_X_Programming_Tips#Xcode_5_and_above
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

DavidJameson

  • Newbie
  • Posts: 6
Re: [solved] "Error in TdefaultComponentEditor"
« Reply #9 on: October 22, 2013, 03:50:58 pm »
DHJiMac:~ $ fpc
Free Pascal Compiler version 2.6.2 [2013/02/03] for i386


Lazarus is 1.0.12

I did reinstall the development tools (i had already found that xcode 5 link, needed to do that to get a command line program to link)


(FYI --- I just resinstalled FCP and Lazarus and it makes no difference --- double-clicking on a button (say) produces the same error message)
« Last Edit: October 22, 2013, 05:50:57 pm by DavidJameson »

 

TinyPortal © 2005-2018