Android Question java.lang.RuntimeException: java.lang.RuntimeException: CustomView CustomType property was not set.

janderkan

Well-Known Member
Licensed User
Longtime User
Hi

I use B4A 7.80 and have downloaded this project:
https://www.b4x.com/android/forum/t...listview-cross-platform-customlistview.84501/
It compiles and run.
I add a new CustomView to Layout number 1
But In the designer when I select 'Add View' the arrow next to CustomView is missing.

In the designer the Custom type property is empty and greyed out, so it is not possible to change it.
When I run the project I get following error:
java.lang.RuntimeException: java.lang.RuntimeException: CustomView CustomType property was not set.

Downgrading to B4a 7.30 the same project compiles and run with no problem.
In the designer when I select 'Add View' the arrow next to CustomView is there and I select the type from a menu.
 

Attachments

  • 7_8.jpg
    7_8.jpg
    26.2 KB · Views: 245
  • 7_3.jpg
    7_3.jpg
    22.3 KB · Views: 226

janderkan

Well-Known Member
Licensed User
Longtime User
Here is my observations.

A. I double click the project (xCustomListView.b4a) in file manager.
B. Click Designer-Open Designer.
C. Click Add View.
D. No arrow next to CustomView.
E. I close the project.

F. I repeated (A-E) 5 times.

G. I double click the project (xCustomListView.b4a) in file manager.
H. Click Designer-Open Designer
I. Click Add View
J. No arrow next to CustomView.
K. In Designer I select File-Open
L. Cancel the File Open
M. Click Add View
N. Now there is an arrow next to CustomView.
O. I close designer.

P. I repeated (G-O) 5 times.

Q. I repeated (A-P) 5 times

This is consistent.
 
Upvote 0

janderkan

Well-Known Member
Licensed User
Longtime User
Yes I am sure I use B4A v7.80
I repeated all steps in post #5 and changed step A and G to:
I open B4A, checks it is v7.80, select File-Open.
Behavior is consistent.

When I downgrade to B4A v7.30 everything is working perfectly.

I noticed a little delay when starting Designer.
I closed all other running programs.
Now the behavior is not consistent, sometimes I get the arrow in Designer on the first click on Add View.
I feel that, when it works, there is no delay when loading designer.
 
Upvote 0

janderkan

Well-Known Member
Licensed User
Longtime User
The list of custom views is refreshed whenever the designer window is focused. You can try to return to the code editor and then back to the designer window.

Have you modified any of the IDE settings in the INI directly (such as BackgroundGuiThreadInterval2) ?

No, i have not changed any IDE settings.

A. I double click the project (xCustomListView.b4a) in file manager.
B. Click Designer-Open Designer
C. Click Add View
D. No arrow next to CustomView.
E. In Designer I select File-Open
F. Cancel the File Open
G. Click Add View
H. Now there is an arrow next to CustomView.
I. I close designer.
J. I repeated (B-I) 5 times.

Looks like the custom views is refreshed when I open another layout, but not the first time I start Designer.
Timing problem, slow CPU, low memory ?

At least I now have a workaround.
 
Upvote 0
Top