Bug? I just can't understand why...?

Cableguy

Expert
Licensed User
Longtime User
In the app I'm working I have been "forced" to name my views with quite long names… not an issue...
I add views and its declarations as I go along and need them...
And then this happens… (all views are added using the designer )
upload_2019-11-26_22-16-49.png
 

Attachments

  • upload_2019-11-26_22-16-29.png
    upload_2019-11-26_22-16-29.png
    1.2 KB · Views: 184
Last edited:

Cableguy

Expert
Licensed User
Longtime User
I have a feeling that I have seen this too last time I added a view to a layout in an existing project. It somehow rectified itself but I don't know what I did to make it so. B4A 9.50.
I'm on 9.50 too
 

agraham

Expert
Licensed User
Longtime User
when the compiler cannot know that you are loading the layout file.
Under what circumstance can this happen? If I remember correctly I ran the project OK. Opened the Designer on the .bal, added the view and saved it. However I think that I forgot to add the Globals declaration for the view in the Designer but then added it manually in the editor and the warning appeared. Would this cause it?
 

Cableguy

Expert
Licensed User
Longtime User
No. There is no difference between letting the designer add the line or adding it yourself.
Maybe you haven't saved the layout file after you added the view and it was saved when you ran the project so it worked fine at runtime.
Then the warning should disappear, no?

In my case, my views are part of a layout that is loaded into one of three pages of a pagerview. All other views in this layout present no warning, and these two were "edited" at a later point...
 

Cableguy

Expert
Licensed User
Longtime User
... or when the compiler cannot know that you are loading the layout file.

I am loading layout by creating a string array and then passing it to the loadlaoyout method in a for/next loop… Can this be it?
If so, this layout file has well over 20 views, but only these 2 are "warning" worthy (!)
 

Cableguy

Expert
Licensed User
Longtime User
I will later today... But it's no Biggie, the project compiles and works as expected
 

Cableguy

Expert
Licensed User
Longtime User
So here you go...
 

Attachments

  • CRIT.zip
    22 KB · Views: 218
Top