Item does not exist

  1. 5 months ago

    Dave S

    Dec 12 San Diego, California USA
    Edited 5 months ago

    Ok.... this is frustrating. seems since I saved some code using 2018..... things are messed up

    The compiler (regardless of what version) is now reporting that two methods "do not exist"

    • They clearly do exist. even Autocomplete identifies them.
    • They are both called multiple times... yet it only complains about one call of each of them
    • If I right click on the offending line.... it still manages to "Jump to Definition" so clearly SOMETHING knows

    I have tried deleting and retyping the lines to no avail...

    I also did notice something else. I had a line that originally contains " + S + " and it changed to "+ Str(d) +"

    FYI..... I ran all this code just last night, and was resuming activity this morning, when all of a sudden .......

  2. Dave S

    Dec 12 San Diego, California USA
    Edited 5 months ago

    REALLY STRANGE.
    This code was originally written before the COLOR function had named colors attached
    So I was using "&C000000" for black instead of "COLOR.BLACK"
    I restored a previous version of the code that worked, and did a global replace of "&c000000" with "color.black"
    Then the above issue reappeared!

    EDIT : FOUND IT.... and this needs to be included somehow in the documents I think

    Each of the two methods.... had an optional parameter.. which was a color who defaulted to black

    Turns out using COLOR.BLACK in the signature of a method to assign an default optional value is NOT VALID, you must use &C000000

  3. Paul L

    Dec 12 Xojo Inc http://docs.xojo.com

    I'm not sure why you'd get an error as they should just evaluate as constants, which you can use to provide default values for parameters.

  4. Paul L

    Dec 12 Xojo Inc http://docs.xojo.com

    If you're able to file a Feedback case for this, it would be helpful as this behavior seems incorrect.

  5. Dave S

    Dec 12 San Diego, California USA

    I don't do feedback for reasons that I have discussed before.

    But I restored the parameter to &C000000 and the error went away.... put it back in and the error returned.. so this should be super simple to replicate.

    and is COLOR.BLACK truly a "constant"... since it is a function of a class

  6. Wayne G

    Dec 12 Pre-Release Testers, Xojo Pro New Zealand axisdirect.nz

    I am currently having similar issues with random errors when running a debug. I can clear those errors by Analyzing the project then running it.

  7. Dale A

    Dec 13 San Diego, California, USA

    Dave, I filed it as Feedback Case #54438

  8. Dave S

    Dec 13 San Diego, California USA

    Thanks.... we should meet for lunch of something... since we seem to be the only two forum members in San Diego

or Sign Up to reply!