Search found 11 matches

by Witchi
Thursday 7th September 2023 11:39am
Forum: Beginners
Topic: Add new entry on Listview's first position
Replies: 6
Views: 1943

Re: Add new entry on Listview's first position

Yeah, that works! Thanks a lot! 8-)
by Witchi
Wednesday 6th September 2023 7:48pm
Forum: Beginners
Topic: Add new entry on Listview's first position
Replies: 6
Views: 1943

Add new entry on Listview's first position

Hi, Has anyone tries to add a new entry at first position to a Listview? You can use the .Add() method, but it adds only after another entry or at the end of the list: ' after is a valid key within the Listview or null (at the end) lv.Add(mykey, mytext, mypicture, after) If I have 5 entries on the L...
by Witchi
Sunday 19th February 2023 3:56pm
Forum: Beginners
Topic: Enumerations
Replies: 4
Views: 4713

Re: Enumerations

Or do you mean declaring constant variables that increase in number? that sort of Enum? You can do that too. See here https://gambaswiki.org/wiki/lang/enumdecl Public Enum This, That, TheOther 'This will be 0, that 1 and so on or... Public Enum This = 10, That, TheOther ' This will be 10, That 11 a...
by Witchi
Sunday 19th February 2023 2:02pm
Forum: Beginners
Topic: Enumerations
Replies: 4
Views: 4713

Enumerations

Hi,
Is there a construct in Gambas like Enumerations (as known as in Java or C++)? Or should I define a class with constants to emulate that?

Thanks
Witchi
by Witchi
Friday 25th February 2022 8:48am
Forum: Beginners
Topic: Best practice for huge forms
Replies: 1
Views: 1514

Best practice for huge forms

If you develop some huge forms with more and more components, how do you handle that beast? Actually I would split such things into smaller views and use MVC (Model-View-Controller) or MVP (Model-View-Presenter) to get smaller classes. So I have built some panels within the graphical builder of Gamb...
by Witchi
Friday 25th February 2022 7:59am
Forum: Beginners
Topic: Abstract and protected methods
Replies: 7
Views: 3336

Re: Abstract and protected methods

That is right, with Strategy I could emulate my abstract method problem. Thank you. Is there a guide for Gambas object model? Like a document which compares OO things in Gambas with other languages and some work-arounds? I have a lot of questions in that way. So I find the constructor parameter thin...
by Witchi
Thursday 24th February 2022 10:37pm
Forum: Beginners
Topic: Abstract and protected methods
Replies: 7
Views: 3336

Re: Abstract and protected methods

Are there such things like abstract methods or protected methods within Gambas? No. If you need abstract method, you can do this: Public Sub Method() Error.Raise("Not implemented method invocation!") End That is not the same. Here I can override the Method(), but if I call it from the dec...
by Witchi
Thursday 24th February 2022 8:39pm
Forum: Beginners
Topic: Abstract and protected methods
Replies: 7
Views: 3336

Re: Abstract and protected methods

by Witchi ยป Thursday 24th February 2022 1:25pm Are there such things like abstract methods or protected methods within Gambas? Wow! I had to look that up. I am still not sure what it all means, but you can 'Inherit' items into a class and add methods, variables and events, if that helps. What are y...
by Witchi
Thursday 24th February 2022 1:25pm
Forum: Beginners
Topic: Abstract and protected methods
Replies: 7
Views: 3336

Abstract and protected methods

Are there such things like abstract methods or protected methods within Gambas?
by Witchi
Thursday 24th February 2022 1:22pm
Forum: Beginners
Topic: Explicit type conversion
Replies: 8
Views: 3742

Re: Explicit type conversion

Thanks for all posts. It works with Object instead of Variant! :)