Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2016-03

Strange error with TValueListEditor

7 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Richard Mace

Hi all,

I am getting the following error within Lazarus 1.4.4 On Windows 10 when loading my project:

Fix LFM file:
Error: Identifier Strings is not published in class "TValueListStrings" and it's highlighted a row that contains:
Strings.Strings = ('')

I have a button that says "Remove all invalid properties" and then I click that, I then get
"Division by zero" with just a cancel button.

It then takes me to my main.lfm file and then that's it. Every subsequent time I reload Lazarus, I get the same "Division by zero" message and I can no longer view my form.

Any ideas please?

Thanks

Richard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20160331/e77b963d/attachment.html>

Reply by email

Bart
to Richard Mace
Richard Mace wrote
Error: Identifier Strings is not published in class "TValueListStrings" and it's highlighted a row that contains: Strings.Strings = ('')

Typically the Strings.Strings should be part of the TValueListEditor. There should be no TValueListStrings in the lfm.

Here's anexample of an lfm with a TValueListEditor

object ValEd: TValueListEditor
Left = 8
Height = 188
Top = 8
Width = 350
FixedCols = 0
RowCount = 4
TabOrder = 0
OnPrepareCanvas = ValEdPrepareCanvas
KeyOptions = [keyEdit, keyAdd]
Options = [goFixedVertLine, goFixedHorzLine, goVertLine, goHorzLine, goColSizing, goEditing, goAutoAddRows, goAlwaysShowEditor, goThumbTracking]
Strings.Strings = (
'a=b'
'c=d'
'e=f'
)
ColWidths = (
64
282
)

  end

This is from my ValueListEditor test suite, and it loads without problems on Lazarus trunk and Lazarus 1.6 (32-bit on Win7-64).

1. Can you copy the relevant part of the lfm file and post it here?
2. 1.4 series is old. Please update to 1.6

Bart

Reply by email

Richard Mace
to Bart
Bart wrote 41 lines
On 3/31/16, Richard Mace wrote: > Error: Identifier Strings is not published in class "TValueListStrings" and > it's highlighted a row that contains: > Strings.Strings = ('') Typically the Strings.Strings should be part of the TValueListEditor. There should be no TValueListStrings in the lfm. Here's anexample of an lfm with a TValueListEditor object ValEd: TValueListEditor Left = 8 Height = 188 Top = 8 Width = 350 FixedCols = 0 RowCount = 4 TabOrder = 0 OnPrepareCanvas = ValEdPrepareCanvas KeyOptions = [keyEdit, keyAdd] Options = [goFixedVertLine, goFixedHorzLine, goVertLine, goHorzLine, goColSizing, goEditing, goAutoAddRows, goAlwaysShowEditor, goThumbTracking] Strings.Strings = ( 'a=b' 'c=d' 'e=f' ) ColWidths = ( 64 282 ) end This is from my ValueListEditor test suite, and it loads without problems on Lazarus trunk and Lazarus 1.6 (32-bit on Win7-64). 1. Can you copy the relevant part of the lfm file and post it here?

? object vle11TrunkProperties: TValueListEditor Left = 13
Height = 288
Top = 51
Width = 496
FixedCols = 0
RowCount = 2
TabOrder = 1
Strings.Strings = (
''
)
OnStringsChange = vle11TrunkPropertiesStringsChange ColWidths = (
64
432
)

          end

?
?The "Strings.Strings = ("? line is what is highlighted with the error: Identifier Strings is not published in class "TValueListStrings"

2. 1.4 series is old. Please update to 1.6

?I've tested it in 1.6, in Ubuntu 14.04 and it comes up with the same error.

Richard?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20160331/b67858b4/attachment.html>

Reply by email

Bart
to Richard Mace
Richard Mace wrote
?I've tested it in 1.6, in Ubuntu 14.04 and it comes up with the same error.

Strange indeed.
Which fpc version?
Can you attach the project (zipped source) here?

If you start a new project with a TValueListEditor, save, quit Lazarus, restart: same problem?
If not: does the lfm look different?

Bart

Reply by email

Richard Mace
to Bart
Bart wrote 8 lines
On 3/31/16, Richard Mace wrote: > ?I've tested it in 1.6, in Ubuntu 14.04 and it comes up with the same > error. Strange indeed. Which fpc version?

?2.6.4 With Lazarus 1.4.4 and 3.0.0 with Lazarus 1.6?

Can you attach the project (zipped source) here?

?It's not Open Source, but I don't mind emailing it to you personally??

If you start a new project with a TValueListEditor, save, quit Lazarus, restart: same problem?

?Nope, works fine.?

If not: does the lfm look different?

?A bit:

object ValueListEditor1: TValueListEditor
Left = 8
Height = 100
Top = 8
Width = 200
FixedCols = 0
RowCount = 2
TabOrder = 0
Strings.Strings = (
''
)
ColWidths = (
64
132
)
end ?

?Thanks for your help

Richard?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20160331/3c307e2b/attachment.html>

Reply by email

Bart
to Richard Mace

I see no real difference in the lfm structure (apart from the fact that the problematic one has OnStringsChange =
vle11TrunkPropertiesStringsChange, which sould not raise the error you mentioned)

Does the form contain any other components that are NOT installed in the "minimal IDE"?
I'm asking because in that case I will ot be able to load the form (especially if it has third-party controls).

For testing purposes in priciple I only need the form (lfm+sourcecode), not the entire project. I don't need to compile it, jus be able to load the form.
You can send it to my private email adress, I will treat is as copyrighted material.

Bart

Reply by email

Richard Mace
to Bart
Bart wrote 10 lines
I see no real difference in the lfm structure (apart from the fact that the problematic one has OnStringsChange = vle11TrunkPropertiesStringsChange, which sould not raise the error you mentioned) Does the form contain any other components that are NOT installed in the "minimal IDE"? I'm asking because in that case I will ot be able to load the form (especially if it has third-party controls).

?No, I'm pretty sure it doesn't?

Show quoted text 7 lines
For testing purposes in priciple I only need the form (lfm+sourcecode), not the entire project. I don't need to compile it, jus be able to load the form. You can send it to my private email adress, I will treat is as copyrighted material.

?emailed the project to you privately.

Thanks?

Richard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/lazarus/attachments/20160331/a140668f/attachment.html>

Reply by email