error 460 FIRETEXTBOX

Started by Heinz Grandjean, December 12, 2011, 11:09:42 AM

Previous topic - Next topic

Heinz Grandjean

Hello,

trying to convert from FireFly 3.10 to 3.50.
I get the following:
Error 460
.....
Undefined equate....
SendMessage hWndControl, %FIRETEXTBOX_SETREADONLY, %FALSE,0

Many thanks for help

Heinz Grandjean

Peter House

Heinz,

Whenever I get an error like this and do not know the reason, Since it must be that either %FIRETEXTBOX_SETREADONLY or %FALSE are undefined, I use a tool called AstroGrep and search the source files for both text strings and see which one does not exist.

Here I would guess it is %FIRETEXTBOX_SETREADONLY is missing and I will then search the ROCA include files for %FIRETEXTBOX_SETREADONLY to find which include file I am missing.

AstroGrep is available from http://astrogrep.sourceforge.net/download/ and is a really handy and simple Windows grep tool.

Good Luck,

Peter

Heinz Grandjean

Thanks Peter,
You are right, the definition of %FIRETEXTBOX_SETREADONLY is missing.
When I set it in manually on top of the application (I got it from the FireTextBox.inc), the error goes away.
It seems that unlike to FF3.10 FF3.50 is not including that FireTextBox.Inc???
Maybe the path is corruptet...
But where to check...
I' m working on a 64Bit-System and FF has been installed in the programfile(x86) .

Heinz Grandjean

Rolf Brandt

QuoteUndefined equate....
SendMessage hWndControl, %FIRETEXTBOX_SETREADONLY, %FALSE,0

Were you using the right hwnd for the FireTextBox?

I just tried two small projects with FireTextBoxes and they compiled and ran fine.

SendMessage hWndControl, %FIRETEXTBOX_SETREADONLY, %FALSE,0

...worked also.
Rolf Brandt
http://www.rbsoft.eu
http://www.taxifreeware.com
I cook with wine, sometimes I even add it to the food.
(W. C. Fields)

Jim Dunn

Quote from: Peter House on December 12, 2011, 11:30:51 AMuse a tool called AstroGrep and search the source files for both text strings and see which one does not exist
I'm also a big fan of grep... from my unix days... I use baregrep (from http://www.baremetalsoft.com/baregrep/)... because when using it from the command-line, it would auto-populate the "current directory" as the search-in option...

But now I'll use AstroGrep, since I was able to recompile to have that feature, I just changed the SearchStarts code:

      static public string SearchStarts
      {
         /// get { return MySettings.searchStartPaths; }
         get { return Environment.CurrentDirectory; }
         set { MySettings.searchStartPaths = value; }
      }


Thx!  : )
3.14159265358979323846264338327950
"Ok, yes... I like pie... um, I meant, pi."

Heinz Grandjean

#5
Thanks again for your suggestions.

I think that I' m comming closer.
I tried to compile the code using the CODGEN_MyAppl_Main.bas in the PB10-Editor.
The compiler sends an error-message concerning to the line #INCLUDE ONCE "cWindow.inc" .
Compiler file not found...
And it does it with all the following *.inc-files

%USE_JOSE_INCLUDES = 1
%USERICHEDIT       = 1     ' ensures that the RichEdit class name will get loaded
%WINVER = &H0500


#INCLUDE ONCE "Windows.inc"
#INCLUDE ONCE "CommCtrl.inc"
#INCLUDE ONCE "ComDlg32.inc"
#INCLUDE ONCE "cWindow.inc"
#INCLUDE ONCE "StaticCtrl.inc"
#INCLUDE ONCE "ButtonCtrl.inc"
#INCLUDE ONCE "EditCtrl.inc"
#INCLUDE ONCE "ComboCtrl.inc"
#INCLUDE ONCE "ListBoxCtrl.inc"
#INCLUDE ONCE "ListViewCtrl.inc"
#INCLUDE ONCE "HeaderCtrl.inc"
#INCLUDE ONCE "StatusBarCtrl.inc"       

Well, I put the correct path of the Jose includes in the FF3-environment-options dialog.
And FF3 accepts the path.
But the path is not correctly set in CODGEN_MyAppl_Main.bas!
When I changed it manually using the Pb-IDE the error goes away.
But after recompiling with FF35 the line is overwritten again to the above "blank"-entry.

Perhaps you have an idea where my mistake is?

Thanks again,
Heinz Grandjean

David Kenny

Does it work correctly when you create a new project, which also uses Jose includes?

Heinz Grandjean

Hi David,
yes, when I use the FireTextBox in a new project, initially made with FF35, then all is correct.
The problem occurs only if I try to compile an older (FF3.10)-project in FF35.
Maybe a command-line problem concerning the Jose-includes??

Heinz Grandjean

Heinz Grandjean

Hello,
I mentioned above that in a new FF35 application the FireTextBox-problem doesn't rise.
But if I try to use a the function FireTextBox_SetReadOnly I get the same trouble I mentioned before.

If You compare some lines in the codegen_XX_Main.bas of FF3.10 and FF 3.50  an interesting difference
is evident:

FF3.10:
' Declares/equates for all functions and controls in the project
#INCLUDE "CODEGEN_LOKDATENMANAGER_DECLARES.inc"

' Custom Controls Include Files
#INCLUDE "CODEGEN_FIRETEXTBOXINC_MODULE.inc"

' Special FireFly utility functions
#INCLUDE "CODEGEN_LOKDATENMANAGER_UTILITY.inc"

FF3.50

' Declares/equates for all functions, Forms and Controls in the project
#INCLUDE ONCE "CODEGEN_LOKDATENMANAGER_DECLARES.inc"
#INCLUDE ONCE "CODEGEN_LOKDATENMANAGER_UTILITY.inc"
#INCLUDE ONCE "CODEGEN_FIRETEXTBOXINC_MODULE.inc"         
       
FF3.50 places the CODEGEN_FIRETEXTBOX_MODULE after!! the CODEGEN_XX_UTILITY.inc !!
And the error can be located in CODEGEN_XX_UTILITY.inc!!

A manual change doesn't work, because FF3,50 alway resets it.

Thanks,
Heinz Grandjean



Paul Squires

Hi - I think that the "easiest" fix is to go into your Functions Library and edit the FF_FireTextBox_SetReadOnly code.

Change:
       SendMessage hWndControl, %FIRETEXTBOX_SETREADONLY, %TRUE, 0

To:
       SendMessage hWndControl, %WM_USER + 2059, %TRUE, 0
Paul Squires
PlanetSquires Software

Heinz Grandjean

Thank You,

that does it.

Heinz Grandjean