Menu

'False' is not an integer value

a2z
2003-06-23
2003-06-23
  • a2z

    a2z - 2003-06-23

    Hi Anthony,

    When b4 starts I get this warning "'False' is not an
    integer value".

    This is because I have a 'JCFSettings.cfg' file
    lingering from v0.6x series.

    To get rid of that message I added the following
    couple of lines.

    {----MODIF BEGIN}
    function TSettingsInputString.Read(): integer;
    var
      lbFound: Boolean;
      lsNewText: string;
    begin
      InternalGetValue(psTag, lsNewText, lbFound);
      if lbFound then Begin {<<-- ADD BEGIN}
        If SameText(lsNewText, 'true') Or SameText(lsNewText, 'false') Then
          Result := Integer(SameText(lsNewText, 'true'))
        Else
          Result := StrToInt(lsNewText)
      End else {<<-- ADD END}
        Result := piDefault;
    end;
    {----MODIF END}

    But, this does not make it compatible with v0.6x
    series. Could I suggest you rename the 'JCFSettings.cfg'  file something like
    'JCFSettings.v2.cfg' .

    Cheers,
    Adem

     
    • Anthony Steele

      Anthony Steele - 2003-06-23

      Erm yes, I have paid no attention to compatibility of config files yet. Best to start with the JcfSettings.cfg supplied with the Beta 4 zip and modify from there.

      Once you have loaded the config file and saved it again, you should be fine.

      I will look into making this easier, either by the code above, or by giving the v2 config file a different name

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.