Wish Custom Views File FieldType for DesignerProperties

Cableguy

Expert
Licensed User
Longtime User
Hi @Erel

Picking up from this wish I further explain the possible usage and why it should have already be implemented...

A custom view is, most of the times, a mix of functionalities from several other views, like the some text input fields mixed up with buttons, or combo views...
In some more complex cases, a custom view is a set of inter connected views used to achieve a simpler result than it would if coded all views seperatly...
But, in some cases, visualy we are left a bit impaired by the lack of a filename type of designer property...
The base panel can hold & image, but when we create a CV with cascading views, sometimes 2 or more images are needed to achieve a coherent look through out the view.

Of course, You know all this, and although we have come a long way, sometimes I see "smaller" improvements being left behind so that the "bigger" ones are implemented...
I really think the next update should be about the "smaller" features that are long overdue, and would defenetly bring a more professional coherent vibe to the B4X Suite.
 

stevel05

Expert
Licensed User
Longtime User
I may have missed the point of this wish, I'm just trying to understand. What is to stop you passing 1 or more stringproperties with the name of the files?

Code based on the original wish.
B4X:
#DesignerProperty: Key: image1, DisplayName: Image1, FieldType: String, DefaultValue: ,Description: First Image
#DesignerProperty: Key: image2, DisplayName: Image2, FieldType: String, DefaultValue: ,Description: Second Image
.....
Dim Image1Name As String = Props.GetDefault("image1","")

    If Image1Name <> "" Then
        BitMap1 = fx.LoadImage(File.DirAssets,Image1Name)
    End If

    Dim Image2Name As String = Props.GetDefault("image2","")
    If Image2Name <> "" Then
        BitMap2 = fx.LoadImage(File.DirAssets,Image2Name)
    End If
 

Cableguy

Expert
Licensed User
Longtime User
That is the workaround...

The wish is to define a designer property that can display the files combobox listing the files added to the files tab, as one does with the image view or the panels background drawable.
 

stevel05

Expert
Licensed User
Longtime User
Ahh OK, thanks. Now I understand.
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…