Dear Tobi
Thanks for showing me the "sane OOP way" in such a detailed manner. ;-) Well, you wrote, it's "quite advanced topic". And you're right, I do not have a clue right now. .. but there are still long winter nights and I know where to dig now! (If not succeeding, I might escape by copy/paste manually and making invisible all not needed Frames.) Thanks for your help and a nice holidays to all. Regards, Hubert Am 21.12.2013 11:12,schrieb Tobias Boege: > On Fri, 20 Dec 2013, u...@gmx.ch wrote: >> Dear Cracks, >> >> >> I want to show various CsvLines in a ScrollView. >> Each line will be splitted and filled in a bunch of controls which are >> all neatly placed and formatted in a "SourceFrame". >> >> My question: >> Is there an easy way to copy/paste that "SourceFrame" depending on the >> (flexible) amount of CsvLines ? >> >> >> Or in other 'words': >> FrameDat0: TextBoxTxt0, CheckBoxLock0, .., BtnSaveFrameDat0 >> and >> N=AmountCsvLines >> >> shall become >> FrameDat0: TextBoxTxt0, CheckBoxLock0, .., BtnSaveFrameDat0 >> FrameDat1: TextBoxTxt1, CheckBoxLock1, .., BtnSaveFrameDat1 >> FrameDat2: TextBoxTxt2, CheckBoxLock2, .., BtnSaveFrameDat2 >> .. >> FrameDatN: TextBoxTxtN, CheckBoxLockN, .., BtnSaveFrameDatN >> >> >> I can do that in the IDE by copy/paste, but how to do it by code? >> Using a gridview does not allow all the formatting I need. >> >> >> Any good ideas or 'magic strategies' ? >> (I got stuck. Code explodes and becomes unflexible) >> > > Well, you can copy your SourceFrame and stuff but I won't elaborate on this > way until you explicitly rejected the sane OOP way :-) > > Which goes like this: > > - create a form "CsvLine", > - arrange your TextBoxes, CheckBoxes, ..., Buttons on it, > - write a _new() method which takes a CSV line and parses it into the > controls, > - create an array of these Forms into a container on your main form (one > for each CSV line). > > This is a quite advanced topic; hope you can deal with the strategy above... > > IIRC, you're german. You can have a look at an article where we created > custom controls using Forms[0], or my project[1] where this is done more > excessively. > > Regards, > Tobi > > [0] http://www.gambas-buch.de/dw/doku.php?id=k18:k18.12:start > [1] http://www.gambas-buch.de/dw/doku.php?id=k27:k27.4:start > > ------------------------------------------------------------------------------ > Rapidly troubleshoot problems before they affect your business. Most IT > organizations don't have a clear picture of how application performance > affects their revenue. With AppDynamics, you get 100% visibility into your > Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro! > http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk > _______________________________________________ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > ------------------------------------------------------------------------------ Rapidly troubleshoot problems before they affect your business. Most IT organizations don't have a clear picture of how application performance affects their revenue. With AppDynamics, you get 100% visibility into your Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro! http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user