Roberto P. Well-Known Member Licensed User Longtime User Nov 11, 2018 #1 hi everyone how read property Single Line for create new custom control? I try to read the property from pannel o label, but It's not possibile. thank Attachments Schermata 2018-11-11 alle 09.55.38.png 11.1 KB · Views: 461
hi everyone how read property Single Line for create new custom control? I try to read the property from pannel o label, but It's not possibile. thank
Erel B4X founder Staff member Licensed User Longtime User Nov 11, 2018 #2 Should be available in the passed label. Upvote 0
Roberto P. Well-Known Member Licensed User Longtime User Nov 11, 2018 #3 it's write only member Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Nov 11, 2018 #4 You are correct. Add a similar property as a custom property. It is write-only because it is a complex property. Upvote 0
You are correct. Add a similar property as a custom property. It is write-only because it is a complex property.
Roberto P. Well-Known Member Licensed User Longtime User Nov 11, 2018 #5 ok, i'll create the same property. #DesignerProperty: Key: Multilinee, DisplayName: Multi Line, FieldType: Boolean, DefaultValue: true Upvote 0
ok, i'll create the same property. #DesignerProperty: Key: Multilinee, DisplayName: Multi Line, FieldType: Boolean, DefaultValue: true
klaus Expert Licensed User Longtime User Nov 11, 2018 #6 If you want to change the property in the code, you need to add two routines: Code: Copy Public Sub setMultiLine(MultiLine As Boolean) mMultiLine = Multiline 'your code if needed End Sub Public Sub getMultiLine As Boolean Return mMultiline End Sub mMultiLine is a local variable in the class holding the property. Upvote 0
If you want to change the property in the code, you need to add two routines: Code: Copy Public Sub setMultiLine(MultiLine As Boolean) mMultiLine = Multiline 'your code if needed End Sub Public Sub getMultiLine As Boolean Return mMultiline End Sub mMultiLine is a local variable in the class holding the property.
Roberto P. Well-Known Member Licensed User Longtime User Nov 11, 2018 #7 this is for read property Code: Copy mEdit.SingleLine = Not(Props.Get("Multilinee")) Upvote 0
klaus Expert Licensed User Longtime User Nov 11, 2018 #8 You need to be clear on what you want! Do you want a MultiLine property or a SingleLine propety? Knowing that one is the opposite of the other. I find it strange, it seems, that you want a SingleLine property but you ask for a MultiLine property !!?? Why not define directly a SingleLine propety? Upvote 0
You need to be clear on what you want! Do you want a MultiLine property or a SingleLine propety? Knowing that one is the opposite of the other. I find it strange, it seems, that you want a SingleLine property but you ask for a MultiLine property !!?? Why not define directly a SingleLine propety?
Roberto P. Well-Known Member Licensed User Longtime User Nov 11, 2018 #9 Hi Klaus, I created custom control, with edit control, that have a parameter that can setting the single line o multiline (are opposite). but I see that it's impossibile to read the property inside the standard. I hope it's clear. regards Upvote 0
Hi Klaus, I created custom control, with edit control, that have a parameter that can setting the single line o multiline (are opposite). but I see that it's impossibile to read the property inside the standard. I hope it's clear. regards
klaus Expert Licensed User Longtime User Nov 11, 2018 #10 Add the custom property as suggested. In my previous post, I was surprised that define a MultiLine property and then inside the code you transform into a SingleLine property. To have a consitency with an EditText object, define s SinglLine property. Upvote 0
Add the custom property as suggested. In my previous post, I was surprised that define a MultiLine property and then inside the code you transform into a SingleLine property. To have a consitency with an EditText object, define s SinglLine property.
Roberto P. Well-Known Member Licensed User Longtime User Nov 11, 2018 #11 ok Klaus, I wrote this only for example. Excuse me for it. regards Upvote 0