From bespalov.av at ...626... Wed Feb 1 06:19:42 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Wed, 1 Feb 2012 12:19:42 +0700 Subject: [Gambas-user] HOW TO insert a text into the file? In-Reply-To: References: <33239012.post@...1379...> Message-ID: http://gambas.pro/gambas/gambas-file-management-1.htm http://gambas.pro/gambas/gambas-temporary-files.htm Here simple on Russian. 2012/2/1 Jussi Lahtinen > http://gambasdoc.org/help/lang/open?v3 > http://gambasdoc.org/help/comp/gb/file?v3 > > http://gambasdoc.org/help/lang?v3 > > Jussi > > > > > On Tue, Jan 31, 2012 at 22:20, abbat wrote: > > > > > > > Public Sub Button1_Click() > > > > How to insert a text into existing file (/tmp/file)? > > > > -- > > View this message in context: > > > http://old.nabble.com/HOW-TO-insert-a-text-into-the-file--tp33239012p33239012.html > > Sent from the gambas-user mailing list archive at Nabble.com. > > > > > > > > > ------------------------------------------------------------------------------ > > Keep Your Developer Skills Current with LearnDevNow! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-d2d > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ____ ? ????????? ???????. From john.aaron.rose at ...626... Wed Feb 1 07:56:08 2012 From: john.aaron.rose at ...626... (John Rose) Date: Wed, 01 Feb 2012 06:56:08 +0000 Subject: [Gambas-user] Search tool button for code in IDE Message-ID: <1328079368.3152.8.camel@...2661...> The icon I would like to see is for Find/Replace in the toolbar below the tabs when a class (i.e. code) file is displayed. There is no icon for that in the Configure. I realise that there is a Find/Replace facility in th eproject toolbar which will do this. From john.aaron.rose at ...626... Wed Feb 1 08:03:02 2012 From: john.aaron.rose at ...626... (John Rose) Date: Wed, 01 Feb 2012 07:03:02 +0000 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 Message-ID: <1328079782.3152.11.camel@...2661...> Matti, I did 'svn update': it gave Skipped '.'. Does this mean that the downloaded 'trunk' repository is corrupt? I've attached the tar.gz of the compile.log. -------------- next part -------------- A non-text attachment was scrubbed... Name: CompileGambas.log.tar.gz Type: application/x-compressed-tar Size: 43801 bytes Desc: not available URL: From math.eber at ...221... Wed Feb 1 08:49:05 2012 From: math.eber at ...221... (Matti) Date: Wed, 01 Feb 2012 08:49:05 +0100 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 In-Reply-To: <1328079782.3152.11.camel@...2661...> References: <1328079782.3152.11.camel@...2661...> Message-ID: <4F28EE71.3010400@...221...> If you google for 'svn update skipped' you will find a lot of possible errors. Maybe it is easier to start again and do the 'svn checkout' again. Am 01.02.2012 08:03, schrieb John Rose: > Matti, > > I did 'svn update': it gave Skipped '.'. Does this mean that the > downloaded 'trunk' repository is corrupt? > > I've attached the tar.gz of the compile.log. > From ron at ...1740... Wed Feb 1 09:00:53 2012 From: ron at ...1740... (Ron) Date: Wed, 01 Feb 2012 09:00:53 +0100 Subject: [Gambas-user] extern library In-Reply-To: <4F273130.7040608@...1...> References: <3525035.btJeaiBlXI@...46...> <1756961.yBaByDlCDY@...46...> <4F273130.7040608@...1...> Message-ID: <4F28F135.2070300@...1740...> On 31-1-2012 1:09, Beno?t Minisini wrote: > Le 29/01/2012 21:33, Wally a ?crit : >> No other way ? >> > Normally the library can be any path, like any data file. So: > > - It is searched as a real file (absolute path, or standard library paths). > > - If it is not found, then it is searched inside the project. > > If you don't succeed in loading your library, please send me a little > test project. > > Regards, > I believe storing it anywhere else than a library path didn't work for me in my project, but I will check again. I'm talking about gambas2. Regards, Ron_2nd. From john.aaron.rose at ...626... Wed Feb 1 15:15:40 2012 From: john.aaron.rose at ...626... (John Rose) Date: Wed, 01 Feb 2012 14:15:40 +0000 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 Message-ID: <1328105740.27374.8.camel@...2661...> I deleted everything in my trunk directory and downloaded Gambas3 revision #4445. I then recompiled Gambas3, compile log attached. In my view the compile/install is not working properly. When I run the attached Test project, clicking on the 'Select Directory' button still brings up the /home directory rather than /home/john when Dialog.Path is set to Home.User. /usr/bin/gambas3.gambas is still showing Date Modified as 31 December: it is the executable linked from /usr/bin/gambas3 which is the menu item created for Gambas3. I've noticed that in /usr/local/bin, there are a number of executables & links (e.g. for gambas3 linking to gambas3.gambas) with Date modified of today. Even when I invoke /usr/local/bin/gambas3, it still shows the same version (i.e. 3.0.90 r172). Would the version be the same between the stable 3.0 version & trunk's version (VERSION file contains 3.0.90)? -------------- next part -------------- A non-text attachment was scrubbed... Name: CompileGambas.log.tar.gz Type: application/x-compressed-tar Size: 44271 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Test.tar.gz Type: application/x-compressed-tar Size: 13457 bytes Desc: not available URL: From rmorgan62 at ...626... Wed Feb 1 15:23:28 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Wed, 1 Feb 2012 06:23:28 -0800 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 In-Reply-To: <1328105740.27374.8.camel@...2661...> References: <1328105740.27374.8.camel@...2661...> Message-ID: Were you sure to remove the hidden svn files? You may want to delete the trunk folder itself and then recreate it. In fact, I'd create new gambas folder. On Wed, Feb 1, 2012 at 6:15 AM, John Rose wrote: > I deleted everything in my trunk directory and downloaded Gambas3 > revision #4445. I then recompiled Gambas3, compile log attached. > > In my view the compile/install is not working properly. When I run the > attached Test project, clicking on the 'Select Directory' button still > brings up the /home directory rather than /home/john when Dialog.Path is > set to Home.User. > > /usr/bin/gambas3.gambas is still showing Date Modified as 31 December: > it is the executable linked from /usr/bin/gambas3 which is the menu > item created for Gambas3. I've noticed that in /usr/local/bin, there are > a number of executables & links (e.g. for gambas3 linking to > gambas3.gambas) with Date modified of today. Even when I > invoke /usr/local/bin/gambas3, it still shows the same version (i.e. > 3.0.90 r172). Would the version be the same between the stable 3.0 > version & trunk's version (VERSION file contains 3.0.90)? > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From jussi.lahtinen at ...626... Wed Feb 1 18:30:11 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 1 Feb 2012 19:30:11 +0200 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 In-Reply-To: <1328105740.27374.8.camel@...2661...> References: <1328105740.27374.8.camel@...2661...> Message-ID: Where did you get the source? With svn? Or did you downloaded it from some website? Next time before compiling anything, delete all gambas binaries to make sure that next you are using just compiled version. Also where/how did you get the revision (not version) number? Jussi On Wed, Feb 1, 2012 at 16:15, John Rose wrote: > I deleted everything in my trunk directory and downloaded Gambas3 > revision #4445. I then recompiled Gambas3, compile log attached. > > In my view the compile/install is not working properly. When I run the > attached Test project, clicking on the 'Select Directory' button still > brings up the /home directory rather than /home/john when Dialog.Path is > set to Home.User. > > /usr/bin/gambas3.gambas is still showing Date Modified as 31 December: > it is the executable linked from /usr/bin/gambas3 which is the menu > item created for Gambas3. I've noticed that in /usr/local/bin, there are > a number of executables & links (e.g. for gambas3 linking to > gambas3.gambas) with Date modified of today. Even when I > invoke /usr/local/bin/gambas3, it still shows the same version (i.e. > 3.0.90 r172). Would the version be the same between the stable 3.0 > version & trunk's version (VERSION file contains 3.0.90)? > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > From bespalov.av at ...626... Thu Feb 2 05:57:15 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Thu, 2 Feb 2012 10:57:15 +0600 Subject: [Gambas-user] =?iso-8859-1?q?Is_Image=2EBalance=28=29_uses_some_l?= =?iso-8859-1?q?ibrary_or_your_algorithm=3F_=28to_Beno=EEt=29?= Message-ID: Hi Beno?t. Please tell me: Is Image.Balance() uses some library or your algorithm? I develop a photo-editor and would like to know the quality of the algorithm. -- ____ Alexey. From bbruen at ...2308... Thu Feb 2 11:32:28 2012 From: bbruen at ...2308... (Bruce Bruen) Date: Thu, 02 Feb 2012 21:02:28 +1030 Subject: [Gambas-user] Issue 123 Message-ID: <1328178748.9055.10.camel@...2688...> Hi Beno?t, This is driving the 3 of us crazy. Hint, hint. :-) Bruce From john.aaron.rose at ...626... Thu Feb 2 12:49:22 2012 From: john.aaron.rose at ...626... (John Rose) Date: Thu, 02 Feb 2012 11:49:22 +0000 Subject: [Gambas-user] Database table row update Message-ID: <1328183362.4988.19.camel@...2661...> I think that I've narrowed down this problem on the attached Test project. The run time error on the starred line below is an error message stating "Update database site table record error" & "Error: Result is read-only": Public Sub ButtonSave_Click() Dim latitude As Float Inc Application.Busy Print "Start of Latitude Update" latitude = ValueBoxLatitude.Value DatabaseConnection.Begin ' ResultSite.MoveTo(1) ' this line is unnecessary ' as the Open form procedure uses it ' I get the same run-time message with it Print "Old latitude", ResultSite["latitude"] Print "New latitude", latitude Print 1 ***** ResultSite["latitude"] = latitude **** Print 2 ResultSite.Update() Print 6 DatabaseConnection.Commit Print "End of Latitude Update" Finally Dec Application.Busy Catch DatabaseConnection.Rollback Error.Raise("Update database site table record error
Error:
" & DConv(Error.Text)) End I'm obviously missing something elementary about updating a field in one of a database's table's rows. PS ResultSite is a Result which contains 2 rows from the site table in the SQLite3 Test.db database -------------- next part -------------- A non-text attachment was scrubbed... Name: Test.tar.gz Type: application/x-compressed-tar Size: 17413 bytes Desc: not available URL: From shanep1967 at ...169... Thu Feb 2 13:01:41 2012 From: shanep1967 at ...169... (Shane Powell) Date: Thu, 02 Feb 2012 23:01:41 +1100 Subject: [Gambas-user] Database table row update In-Reply-To: <1328183362.4988.19.camel@...2661...> References: <1328183362.4988.19.camel@...2661...> Message-ID: <4F2A7B25.2030708@...169...> On 02/02/12 22:49, John Rose wrote: > I think that I've narrowed down this problem on the attached Test > project. The run time error on the starred line below is an error > message stating "Update database site table record error"& "Error: > Result is read-only": > Public Sub ButtonSave_Click() > Dim latitude As Float > Inc Application.Busy > Print "Start of Latitude Update" > latitude = ValueBoxLatitude.Value > DatabaseConnection.Begin > ' ResultSite.MoveTo(1) ' this line is unnecessary > ' as the Open form procedure uses it > ' I get the same run-time message with it > Print "Old latitude", ResultSite["latitude"] > Print "New latitude", latitude > Print 1 > ***** ResultSite["latitude"] = latitude **** > Print 2 > ResultSite.Update() > Print 6 > DatabaseConnection.Commit > Print "End of Latitude Update" > Finally > Dec Application.Busy > Catch > DatabaseConnection.Rollback > Error.Raise("Update database site table record > error
Error:
"& DConv(Error.Text)) > End > > I'm obviously missing something elementary about updating a field in one > of a database's table's rows. > > PS ResultSite is a Result which contains 2 rows from the site table in > the SQLite3 Test.db database > > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > > > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user I have not looked at all your code but are you get your result by doing result = dbconnection.edit("table") then you can edit a field , update ,commit From john.aaron.rose at ...626... Thu Feb 2 13:29:16 2012 From: john.aaron.rose at ...626... (John Rose) Date: Thu, 02 Feb 2012 12:29:16 +0000 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 Message-ID: <1328185756.4988.72.camel@...2661...> I got the stable Gambas3 (i.e. 3.0) from kendek's Launchpad ppa for Ubuntu Lucid: using Synaptic (i.e. apt-get) to download those packages. As I previously said, that version of Gambas3 (e.g. gambas3.gambas) has installed to /usr/bin (which happens to also be the place where Gambas2 (e.g. gambas2.gambas) is resident created by installing the appropriate packages from Ubuntu Lucid's canonical repos). When I try to install the trunk version of Gambas3 using subversion (i.e. the command stated on Gambas's Documentation Subversion page), it installs to /usr/local/bin. I've emailed kendek to try & clarify the situation. I think that my system gets confused by these 2 versions of Gambas3. To solve the problem, I think that I only have to uninstall kendek's packages). Is that reasonable? Regarding deleting the .svn directory, it is on the root directory and have last dates modified of 2010 & 2008 so I'm reluctant to touch them. There is an .subversion directory on my home directory so I could delete that. Similarly, I can delete the trunk directory. However, I would only do that if removing kendek's packages didn't solve the problem. From rmorgan62 at ...626... Thu Feb 2 14:34:34 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Thu, 2 Feb 2012 05:34:34 -0800 Subject: [Gambas-user] Database table row update In-Reply-To: <4F2A7B25.2030708@...169...> References: <1328183362.4988.19.camel@...2661...> <4F2A7B25.2030708@...169...> Message-ID: I would check the permissions on all your database tables. Also check and make sure the table files are writable. I know I've seen this kind of error on MySQL DBs when someone copies files from one machine or user to another. On Thu, Feb 2, 2012 at 4:01 AM, Shane Powell wrote: > On 02/02/12 22:49, John Rose wrote: > > I think that I've narrowed down this problem on the attached Test > > project. The run time error on the starred line below is an error > > message stating "Update database site table record error"& "Error: > > Result is read-only": > > Public Sub ButtonSave_Click() > > Dim latitude As Float > > Inc Application.Busy > > Print "Start of Latitude Update" > > latitude = ValueBoxLatitude.Value > > DatabaseConnection.Begin > > ' ResultSite.MoveTo(1) ' this line is unnecessary > > ' as the Open form procedure uses it > > ' I get the same run-time message with it > > Print "Old latitude", ResultSite["latitude"] > > Print "New latitude", latitude > > Print 1 > > ***** ResultSite["latitude"] = latitude **** > > Print 2 > > ResultSite.Update() > > Print 6 > > DatabaseConnection.Commit > > Print "End of Latitude Update" > > Finally > > Dec Application.Busy > > Catch > > DatabaseConnection.Rollback > > Error.Raise("Update database site table record > > error
Error:
"& DConv(Error.Text)) > > End > > > > I'm obviously missing something elementary about updating a field in one > > of a database's table's rows. > > > > PS ResultSite is a Result which contains 2 rows from the site table in > > the SQLite3 Test.db database > > > > > > > > > > > ------------------------------------------------------------------------------ > > Keep Your Developer Skills Current with LearnDevNow! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-d2d > > > > > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > I have not looked at all your code but are you get your result by doing > result = dbconnection.edit("table") > then you can edit a field , update ,commit > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From bespalov.av at ...626... Thu Feb 2 14:51:02 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Thu, 2 Feb 2012 19:51:02 +0600 Subject: [Gambas-user] how to insert hImage into table sqlite base Message-ID: Hi! Tell me please, how to insert hImage into table sqlite base, into BLOB field? -- ____ ? ????????? ???????. From emil.lenngren at ...626... Thu Feb 2 16:02:27 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Thu, 2 Feb 2012 16:02:27 +0100 Subject: [Gambas-user] =?iso-8859-1?q?Is_Image=2EBalance=28=29_uses_some_l?= =?iso-8859-1?q?ibrary_or_your_algorithm=3F_=28to_Beno=EEt=29?= In-Reply-To: References: Message-ID: You can check out the algorithm in the source code: http://gambas.svn.sourceforge.net/viewvc/gambas/gambas/trunk/main/lib/image.effect/effect.cpp?view=markup /Emil 2012/2/2 ??????? ???????? > Hi Beno?t. > Please tell me: > Is Image.Balance() uses some library or your algorithm? > > I develop a photo-editor and would like to know the quality of the > algorithm. > > > -- > ____ > Alexey. > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From ea7dfh at ...2382... Thu Feb 2 17:21:38 2012 From: ea7dfh at ...2382... (Jesus) Date: Thu, 02 Feb 2012 17:21:38 +0100 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 In-Reply-To: <1328185756.4988.72.camel@...2661...> References: <1328185756.4988.72.camel@...2661...> Message-ID: <4F2AB812.5020000@...2382...> El 02/02/12 13:29, John Rose escribi?: > When I try to install the trunk version of Gambas3 using subversion > (i.e. the command stated on Gambas's Documentation Subversion page), it > installs to /usr/local/bin. I've emailed kendek to try& clarify the > situation. I think that my system gets confused by these 2 versions of > Gambas3. To solve the problem, I think that I only have to uninstall > kendek's packages). Is that reasonable? You are right. This issue has been discussed few weeks ago on this list, so better uninstall kendek's packages and you're done. About deleting trunk folder, I'm doing so each time I want to compile a new revision, so never got a problem with this, IMO it's better. Best regards -- Jesus Guardon From johny.provoost at ...27... Thu Feb 2 18:11:23 2012 From: johny.provoost at ...27... (Johny Provoost) Date: Thu, 02 Feb 2012 18:11:23 +0100 Subject: [Gambas-user] how to insert hImage into table sqlite base In-Reply-To: References: Message-ID: <4F2AC3BB.3010800@...27...> you could look in the examples: PictureDatabase I tried it in version 2 and it worked very well. Hope this is what you search for Johny Op 02-02-12 14:51, ??????? ???????? schreef: > Hi! > Tell me please, how to insert hImage into table sqlite base, into BLOB > field? > > From rolf.frogs at ...221... Thu Feb 2 19:41:00 2012 From: rolf.frogs at ...221... (Rolf Schmidt) Date: Thu, 02 Feb 2012 19:41:00 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time Message-ID: <4F2AD8BC.90501@...2594...> Hi everybody out there is there a function which allows to convert an unix timestamp into the appropriated date/time in Gambas3? If, how is it called and how to use. Many thanks Rolf From john.aaron.rose at ...626... Thu Feb 2 21:44:56 2012 From: john.aaron.rose at ...626... (John Rose) Date: Thu, 02 Feb 2012 20:44:56 +0000 Subject: [Gambas-user] Database table row update Message-ID: <1328215496.4988.78.camel@...2661...> I've solved this. I was using the Exec method (invoking a select statement) to obtain ResultSite: the documentation says that this is therefore read-only i.e. as the run-time error says. So I've changed the Exec to Edit with the appropriate changes to its parameters. It now works OK. I've just noticed Shane's reply who also suggested the solution. It's a learning experience! From john.aaron.rose at ...626... Thu Feb 2 21:52:16 2012 From: john.aaron.rose at ...626... (John Rose) Date: Thu, 02 Feb 2012 20:52:16 +0000 Subject: [Gambas-user] Issue 206 in gambas: Can't compile Gambas3 Message-ID: <1328215936.4988.85.camel@...2661...> Uninstalling kendek's Gambas3 packages has solved the problem. It also removed all the Gambas3 stuff from /usr/bin. I deleted the stuff in trunk, downloaded revision #4445 using subversion (at end of download, subversion displays that number) as instructed on the Gambas Ubuntu webpage and recompiled Gambas3. I was previously using the Ubuntu Launchpad ppa of madnessmike for Gambas2. This would have given the same problem (with gambas2) before I started using Gambas3. Thanks Jesus, Jussi & Randall. From john.aaron.rose at ...626... Thu Feb 2 21:54:24 2012 From: john.aaron.rose at ...626... (John Rose) Date: Thu, 02 Feb 2012 20:54:24 +0000 Subject: [Gambas-user] SelectDirectory does not use Dialog.Path correctly Message-ID: <1328216064.4988.86.camel@...2661...> I confirm that this 'bug' has been fixed in version #4445 of Gambas3. From zachsmith022 at ...626... Fri Feb 3 05:41:53 2012 From: zachsmith022 at ...626... (Zach Smith) Date: Thu, 2 Feb 2012 22:41:53 -0600 Subject: [Gambas-user] gb.GeneralDate formatting is inconsistent Message-ID: The gb.GeneralDate formatting appears to be inconsistent in the handling of time 00:00:00.. Dim d1 As Date, d2 As Date, d3 As Date d1 = CDate("1/1/2003 00:00:00") d2 = CDate("1/1/2003") d3 = CDate("00:00:00") Print Format(d1, gb.GeneralDate) Print Format(d2, gb.GeneralDate) Print Format(d3, gb.GeneralDate) Results in: 01/01/03 01/01/03 00:00:00 Shouldn't the first line return this? 01/01/03 00:00:00 From bespalov.av at ...626... Fri Feb 3 08:10:30 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Fri, 3 Feb 2012 13:10:30 +0600 Subject: [Gambas-user] how to insert hImage into table sqlite base In-Reply-To: <4F2AC3BB.3010800@...27...> References: <4F2AC3BB.3010800@...27...> Message-ID: Thank you. My code: Dim sql As String Dim ImageBlob As String Dim ResultImg As Result ImageBlob = File.Load(sFile) Conn = Connections["Connection1"] This code works: ResultImg = Conn.Create("images_test") ResultImg["dirname"] = sFile ResultImg["image"] = ImageBlob ResultImg.Update() This code not works sql = "INSERT INTO images_test (dirname, image) VALUES(&1, &2)" sql = Conn.Subst(sql, sFile, ImageBlob) Conn.Exec(sql) Gambas is freezes. 2012/2/3 Johny Provoost > you could look in the examples: PictureDatabase > I tried it in version 2 and it worked very well. Hope this is what you > search for > > Johny > > > > Op 02-02-12 14:51, ??????? ???????? schreef: > > Hi! > > Tell me please, how to insert hImage into table sqlite base, into BLOB > > field? > > > > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ____ ? ????????? ???????. From eilert-sprachen at ...221... Fri Feb 3 08:47:54 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Fri, 03 Feb 2012 08:47:54 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2AD8BC.90501@...2594...> References: <4F2AD8BC.90501@...2594...> Message-ID: <4F2B912A.6040200@...221...> Am 02.02.2012 19:41, schrieb Rolf Schmidt: > Hi everybody out there > > is there a function which allows to convert an unix timestamp into the > appropriated date/time in Gambas3? > > If, how is it called and how to use. > > Many thanks > Rolf Take a look at this one: http://gambasdoc.org/help/lang/stat?v3 file.stat should deliver a file date. Or did I get you wrong? Regards another Rolf :-) From rolf.frogs at ...221... Fri Feb 3 10:32:00 2012 From: rolf.frogs at ...221... (Rolf Schmidt) Date: Fri, 03 Feb 2012 10:32:00 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2B912A.6040200@...221...> References: <4F2AD8BC.90501@...2594...> <4F2B912A.6040200@...221...> Message-ID: <4F2BA990.8050605@...2594...> Hi "another Rolf" >> is there a function which allows to convert an unix timestamp into the >> appropriated date/time in Gambas3? >> >> If, how is it called and how to use. > Take a look at this one: > http://gambasdoc.org/help/lang/stat?v3 > file.stat should deliver a file date. Or did I get you wrong? For my problem, you get wrong. The unix timestamp is not only the time of a file. It is the time in seconds since the 1. Jan. 1970. Even the system clock only counts the seconds. My problem is, that a network application send a timestamp as a string. I have to convert this string into Date and Time - which is usually done in C or PHP or... by a function of a system library (which of course know leap years). And some times I would like to generate a timestamp as well, for example to send it to a database. Another helper out there? Rolf From ron at ...1740... Fri Feb 3 10:42:14 2012 From: ron at ...1740... (Ron) Date: Fri, 03 Feb 2012 10:42:14 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2BA990.8050605@...2594...> References: <4F2AD8BC.90501@...2594...> <4F2B912A.6040200@...221...> <4F2BA990.8050605@...2594...> Message-ID: <4F2BABF6.9090105@...1740...> Just google for gambas calculate get unix time Regards, Ron_2nd. > Hi "another Rolf" > >>> is there a function which allows to convert an unix timestamp into the >>> appropriated date/time in Gambas3? >>> >>> If, how is it called and how to use. >> Take a look at this one: >> http://gambasdoc.org/help/lang/stat?v3 >> file.stat should deliver a file date. Or did I get you wrong? > For my problem, you get wrong. The unix timestamp is not only the time > of a file. It is the time in seconds since the 1. Jan. 1970. Even the > system clock only counts the seconds. > > My problem is, that a network application send a timestamp as a string. > I have to convert this string into Date and Time - which is usually done > in C or PHP or... by a function of a system library (which of course > know leap years). > > And some times I would like to generate a timestamp as well, for example > to send it to a database. > > Another helper out there? > > Rolf > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From wally at ...2037... Fri Feb 3 11:00:25 2012 From: wally at ...2037... (Wally) Date: Fri, 03 Feb 2012 11:00:25 +0100 Subject: [Gambas-user] Gambas Preprocessor Message-ID: <4763280.afcfGKAvz1@...46...> Where can i find information aboy gambas preprocessor commands ? #IF, #ELSE, #EndIf i found, whats about e.g. #define ? From eilert-sprachen at ...221... Fri Feb 3 11:08:33 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Fri, 03 Feb 2012 11:08:33 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2BA990.8050605@...2594...> References: <4F2AD8BC.90501@...2594...> <4F2B912A.6040200@...221...> <4F2BA990.8050605@...2594...> Message-ID: <4F2BB221.5020600@...221...> Am 03.02.2012 10:32, schrieb Rolf Schmidt: > Hi "another Rolf" > >>> is there a function which allows to convert an unix timestamp into the >>> appropriated date/time in Gambas3? >>> >>> If, how is it called and how to use. > >> Take a look at this one: >> http://gambasdoc.org/help/lang/stat?v3 >> file.stat should deliver a file date. Or did I get you wrong? > > For my problem, you get wrong. The unix timestamp is not only the time > of a file. It is the time in seconds since the 1. Jan. 1970. Even the > system clock only counts the seconds. > > My problem is, that a network application send a timestamp as a string. > I have to convert this string into Date and Time - which is usually done > in C or PHP or... by a function of a system library (which of course > know leap years). > > And some times I would like to generate a timestamp as well, for example > to send it to a database. > > Another helper out there? > > Rolf > May I nevertheless? :-) Ok, I tried around a bit, take a look: PUBLIC SUB Button1_Click() DIM t$ AS String t$ = CStr(CFloat(Now)) Message.Info(t$) t$ = CDate(CFloat(t$)) Message.Info(t$) END Does it help? Rolf From rmorgan62 at ...626... Fri Feb 3 11:09:24 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Fri, 3 Feb 2012 02:09:24 -0800 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2BABF6.9090105@...1740...> References: <4F2AD8BC.90501@...2594...> <4F2B912A.6040200@...221...> <4F2BA990.8050605@...2594...> <4F2BABF6.9090105@...1740...> Message-ID: I haven't tried it but try passing the nix time stamp to the secods parameter of the date/time function. I seem to recall someone saying this would do the trick... Set the minutes, hours ect. to 0. On Fri, Feb 3, 2012 at 1:42 AM, Ron wrote: > Just google for gambas calculate get unix time > > Regards, > Ron_2nd. > > Hi "another Rolf" > > > >>> is there a function which allows to convert an unix timestamp into the > >>> appropriated date/time in Gambas3? > >>> > >>> If, how is it called and how to use. > >> Take a look at this one: > >> http://gambasdoc.org/help/lang/stat?v3 > >> file.stat should deliver a file date. Or did I get you wrong? > > For my problem, you get wrong. The unix timestamp is not only the time > > of a file. It is the time in seconds since the 1. Jan. 1970. Even the > > system clock only counts the seconds. > > > > My problem is, that a network application send a timestamp as a string. > > I have to convert this string into Date and Time - which is usually done > > in C or PHP or... by a function of a system library (which of course > > know leap years). > > > > And some times I would like to generate a timestamp as well, for example > > to send it to a database. > > > > Another helper out there? > > > > Rolf > > > > > ------------------------------------------------------------------------------ > > Try before you buy = See our experts in action! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-dev2 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From mohareve at ...626... Fri Feb 3 12:14:43 2012 From: mohareve at ...626... (M. Cs.) Date: Fri, 3 Feb 2012 12:14:43 +0100 Subject: [Gambas-user] I need your help with Processes Message-ID: Public $hProcess As Process Private $sText As String Private answers As New String[] Public Sub Main() Dim fajl As File Dim tovabb As Boolean Dim i As Integer $hProcess = Exec ["bash", "--noediting"] For Input Output As "Process" tovabb = Run_command("ftp") tovabb = Run_command("open") tovabb = Run_command("ftp.mysite.com") tovabb = Run_command("myusername") tovabb = Run_command("mypassword") tovabb = Run_command("ls ./public_html -R") fajl = Open User.Home & "/Csabax.txt" For Create Close (fajl) fajl = Open User.Home & "/Csabax.txt" For Write For i = 0 To answers.Max Print #fajl, answers[i] Next Close (fajl) $hProcess.Kill End Public Sub Process_Read() Dim sStr As String Read #$hProcess, sStr, -256 $sText = sStr answers.Add($sText) End Public Sub Process_Error(sStr As String) $sText = $sText & sStr End Public Sub Run_command(cmd As String) As Boolean Dim sLig As String sLig = cmd & gb.NewLine sLig = Conv$(sLig, Desktop.Charset, System.Charset) Print #$hProcess, sLig Return True End Private Function Normalize(sStr As String) As String Dim sNorm As String Dim iInd As Integer Dim iCar As Integer Dim bEsc As Boolean sNorm = sStr If System.Charset = Desktop.Charset Then Return sNorm Else Return Conv$(sNorm, System.Charset, Desktop.Charset) Endif End This is what I have stolen from the Console example. What I want is to have a FTP site's content listed and stored in a local text file or in variable for further processing. The problem is that this module returns nothing. How could I simulate the behaviour of a real console with predefined myuser, mypassword and ftp address. The same thing works with Console example, but I don't need a form or anything else, just the result of "ls ./public_html -R" at the end. Main() is called from other part of the program. Thanks! Csaba From adamnt42 at ...626... Fri Feb 3 13:09:01 2012 From: adamnt42 at ...626... (GMail) Date: Fri, 03 Feb 2012 22:39:01 +1030 Subject: [Gambas-user] Gambas Preprocessor In-Reply-To: <4763280.afcfGKAvz1@...46...> References: <4763280.afcfGKAvz1@...46...> Message-ID: <1328270941.9055.17.camel@...2688...> On Fri, 2012-02-03 at 11:00 +0100, Wally wrote: > Where can i find information aboy gambas preprocessor commands ? > #IF, #ELSE, #EndIf i found, whats about e.g. #define ? > The help file is explicit. I, too, would like to see a bit more freedom. But what is there, is there. "Preprocessor Expression" is constrained to those "rudimentary boolean expression"s. Never mind. .. maybe next month? hth Bruce From john.aaron.rose at ...626... Fri Feb 3 15:04:29 2012 From: john.aaron.rose at ...626... (John Rose) Date: Fri, 03 Feb 2012 14:04:29 +0000 Subject: [Gambas-user] IDE displays 'must abort' popup Message-ID: <1328277869.3990.0.camel@...2661...> This bug has been fixed in Gambas3 revision #4445. From john.aaron.rose at ...626... Fri Feb 3 15:11:49 2012 From: john.aaron.rose at ...626... (John Rose) Date: Fri, 03 Feb 2012 14:11:49 +0000 Subject: [Gambas-user] ValueBox value validation Message-ID: <1328278309.3990.5.camel@...2661...> This is fixed in Gambas3 revision #4445. I've just tried recording that on the Gambas Issues webpage and it's returned a webpage showing 'Google' with '400 that's an error' followed by 'Your client has issued a malformed or illegal request. That?s all we know.'. Only thing I can think of is that Ubuntu Lucid 'Update manager' has upgraded Firefox to version 9.0.1. Is that the cause? From wally at ...2037... Fri Feb 3 15:13:57 2012 From: wally at ...2037... (Wally) Date: Fri, 03 Feb 2012 15:13:57 +0100 Subject: [Gambas-user] Pointer-Memory Question Message-ID: <2877541.QEkvIETUOs@...46...> What is wrong in this code ? Public Sub Button1_Click() Dim f, r As Single Dim pPtr As Pointer Dim strm As Stream f = 1 / 3 pPtr = Alloc(1, 4) 'alloc 4 * 1 Byte for single strm = Memory pPtr For Read Write Write #strm, f As Single r = Read #strm As Single Print f ' --> 0.3333333 Print r ' --> 1.261169E-44 Close #strm Free(pPtr) End From gambas at ...1... Fri Feb 3 15:42:25 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Fri, 03 Feb 2012 15:42:25 +0100 Subject: [Gambas-user] Pointer-Memory Question In-Reply-To: <2877541.QEkvIETUOs@...46...> References: <2877541.QEkvIETUOs@...46...> Message-ID: <4F2BF251.70503@...1...> Le 03/02/2012 15:13, Wally a ?crit : > > What is wrong in this code ? > > Public Sub Button1_Click() > > Dim f, r As Single > Dim pPtr As Pointer > Dim strm As Stream > > f = 1 / 3 > > pPtr = Alloc(1, 4) 'alloc 4 * 1 Byte for single > > strm = Memory pPtr For Read Write > > Write #strm, f As Single > > r = Read #strm As Single > > Print f ' --> 0.3333333 > Print r ' --> 1.261169E-44 > > Close #strm > Free(pPtr) > > End > The stream pointer goes forward after a Write or a Read. You must use Seek! -- Beno?t Minisini From wally at ...2037... Fri Feb 3 15:47:58 2012 From: wally at ...2037... (Wally) Date: Fri, 03 Feb 2012 15:47:58 +0100 Subject: [Gambas-user] Pointer-Memory Question In-Reply-To: <4F2BF251.70503@...1...> References: <2877541.QEkvIETUOs@...46...> <4F2BF251.70503@...1...> Message-ID: <15629309.CpHXLY1tJt@...46...> sure :) thx On Friday, February 03, 2012 15:42:25 Beno?t Minisini wrote: > Le 03/02/2012 15:13, Wally a ?crit : > > What is wrong in this code ? > > > > Public Sub Button1_Click() > > > > Dim f, r As Single > > Dim pPtr As Pointer > > Dim strm As Stream > > > > f = 1 / 3 > > > > pPtr = Alloc(1, 4) 'alloc 4 * 1 Byte for single > > > > strm = Memory pPtr For Read Write > > > > Write #strm, f As Single > > > > r = Read #strm As Single > > > > Print f ' --> 0.3333333 > > Print r ' --> 1.261169E-44 > > > > Close #strm > > Free(pPtr) > > > > End > > The stream pointer goes forward after a Write or a Read. You must use Seek! From rolf.frogs at ...221... Fri Feb 3 15:48:42 2012 From: rolf.frogs at ...221... (Rolf Schmidt) Date: Fri, 03 Feb 2012 15:48:42 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2BB221.5020600@...221...> References: <4F2AD8BC.90501@...2594...> <4F2B912A.6040200@...221...> <4F2BA990.8050605@...2594...> <4F2BB221.5020600@...221...> Message-ID: <4F2BF3CA.7090701@...2594...> Hi Rolf, hi Ron. >>>> is there a function which allows to convert an unix timestamp into the >>>> appropriated date/time in Gambas3? >>>> >>>> If, how is it called and how to use. >> >>> Take a look at this one: >>> http://gambasdoc.org/help/lang/stat?v3 >>> file.stat should deliver a file date. Or did I get you wrong? >> >> For my problem, you get wrong. The unix timestamp is not only the time >> of a file. It is the time in seconds since the 1. Jan. 1970. Even the >> system clock only counts the seconds. >> >> My problem is, that a network application send a timestamp as a string. >> I have to convert this string into Date and Time - which is usually done >> in C or PHP or... by a function of a system library (which of course >> know leap years). >> >> And some times I would like to generate a timestamp as well, for example >> to send it to a database. >> >> Another helper out there? >> > May I nevertheless? :-) > > Ok, I tried around a bit, take a look: > > PUBLIC SUB Button1_Click() > DIM t$ AS String > > t$ = CStr(CFloat(Now)) > Message.Info(t$) > > t$ = CDate(CFloat(t$)) > Message.Info(t$) > > END > > Does it help? Not realy, than Now is a float value in "Exel"-Stil i.e. Days (since when - don't hope since 1.1.1900) and seconds since midnight, but as I wrote Unix timestamp is an integer i.e. has only seconds. @Ron. Your Module is excellent, but I can't belief, that a programming language for the UNIX-environment isn't able to handle timestamps only after "reinventig the wheel". I think, we shoud ask Benoit why he didn't implement such a function or where he hide the information. Rolf. From gambas at ...1... Fri Feb 3 16:07:26 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Fri, 03 Feb 2012 16:07:26 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2BF3CA.7090701@...2594...> References: <4F2AD8BC.90501@...2594...> <4F2B912A.6040200@...221...> <4F2BA990.8050605@...2594...> <4F2BB221.5020600@...221...> <4F2BF3CA.7090701@...2594...> Message-ID: <4F2BF82E.2000604@...1...> Le 03/02/2012 15:48, Rolf Schmidt a ?crit : > > @Ron. > Your Module is excellent, but I can't belief, that a programming > language for the UNIX-environment isn't able to handle timestamps only > after "reinventig the wheel". > I think, we shoud ask Benoit why he didn't implement such a function or > where he hide the information. > > Rolf. > Unix time stamp is a number of seconds since 1/1/1970. So to convert a Gambas date to Unix timestamp: Print DateDiff(CDate("1/1/1970"), Now, gb.Second) And to convert an Unix timestamp to Gambas date: Print DateAdd(CDate("1/1/1970"), TimeStamp, gb.Second) -- Beno?t Minisini From jussi.lahtinen at ...626... Fri Feb 3 17:34:08 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Fri, 3 Feb 2012 18:34:08 +0200 Subject: [Gambas-user] I need your help with Processes In-Reply-To: References: Message-ID: Hmmm... seem like you need to wait for the execution of the commands. Try: Public Sub Main() > Dim fajl As File > Dim tovabb As Boolean > Dim i As Integer > $hProcess = Exec ["bash", "--noediting"] For Input Output As "Process" > tovabb = Run_command("ftp") > tovabb = Run_command("open") > tovabb = Run_command("ftp.mysite.com") > tovabb = Run_command("myusername") > tovabb = Run_command("mypassword") > tovabb = Run_command("ls ./public_html -R") > Wait 1 Or implement more intelligent method to wait something to appear to read event. This isn't necessary: > fajl = Open User.Home & "/Csabax.txt" For Create > Close (fajl) > Instead use this: fajl = Open User.Home & "/Csabax.txt" For Write Create > For i = 0 To answers.Max > Print #fajl, answers[i] > Next > Close (fajl) > This kills the process before commands are executed: $hProcess.Kill > Instead of this: > Public Sub Process_Read() > Dim sStr As String > Read #$hProcess, sStr, -256 > $sText = sStr > answers.Add($sText) > End > Use this: Public Sub Process_Read() Dim sStr As String Read #$hProcess, sStr, -256 answers.Add(sStr) End Because otherwise, you can lose message written to $sText in error event. Instead of this: Public Sub Process_Error(sStr As String) > > $sText = $sText & sStr > > End > > Use this: Public Sub Process_Error(sStr As String) answers.Add(sStr) End Hope this helps. Jussi From mohareve at ...626... Fri Feb 3 18:04:58 2012 From: mohareve at ...626... (M. Cs.) Date: Fri, 3 Feb 2012 18:04:58 +0100 Subject: [Gambas-user] I need your help with Processes In-Reply-To: References: Message-ID: Thanks! I've tried to add: Repeat wait 1 Until checker=TRUE checker=FALSE After every Run_command() and Public Sub Process_Read() Dim sStr As String Read #$hProcess, sStr, -256 answers.Add(sStr) checker=TRUE End My problem is how to solve insertion of user name and password as well as the command 'ls -R' How would you solve this? 2012/2/3, Jussi Lahtinen : > Hmmm... seem like you need to wait for the execution of the commands. > > Try: > > Public Sub Main() >> Dim fajl As File >> Dim tovabb As Boolean >> Dim i As Integer >> $hProcess = Exec ["bash", "--noediting"] For Input Output As "Process" >> tovabb = Run_command("ftp") >> tovabb = Run_command("open") >> tovabb = Run_command("ftp.mysite.com") >> tovabb = Run_command("myusername") >> tovabb = Run_command("mypassword") >> tovabb = Run_command("ls ./public_html -R") >> > > Wait 1 > > Or implement more intelligent method to wait something to appear to read > event. > > > This isn't necessary: > > >> fajl = Open User.Home & "/Csabax.txt" For Create >> Close (fajl) >> > > > > Instead use this: > > fajl = Open User.Home & "/Csabax.txt" For Write Create >> For i = 0 To answers.Max >> Print #fajl, answers[i] >> Next >> Close (fajl) >> > > > This kills the process before commands are executed: > > $hProcess.Kill >> > > > > Instead of this: > > >> Public Sub Process_Read() >> Dim sStr As String >> Read #$hProcess, sStr, -256 >> $sText = sStr >> answers.Add($sText) >> End >> > > > Use this: > > Public Sub Process_Read() > Dim sStr As String > Read #$hProcess, sStr, -256 > answers.Add(sStr) > End > > > Because otherwise, you can lose message written to $sText in error event. > > > Instead of this: > > Public Sub Process_Error(sStr As String) >> >> $sText = $sText & sStr >> >> End >> >> > Use this: > > > Public Sub Process_Error(sStr As String) > > answers.Add(sStr) > > End > > > > Hope this helps. > > > Jussi > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From fabianfloresvadell at ...626... Fri Feb 3 18:11:24 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 3 Feb 2012 14:11:24 -0300 Subject: [Gambas-user] dirs and files structure of a Gambas project Message-ID: Hi. Exists any spec for the structure of directories and files (and its meaning) of a Gambas project? What I want is to know all conditions that the compiler and interpreter expect, in order to call them from the command line. I need to know too any information about config files or data from them, needed for the IDE but not for the compiler neither interpreter. Thanks. From jussi.lahtinen at ...626... Fri Feb 3 18:20:50 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Fri, 3 Feb 2012 19:20:50 +0200 Subject: [Gambas-user] I need your help with Processes In-Reply-To: References: Message-ID: > Repeat > wait 1 > Until checker=TRUE > checker=FALSE > After every Run_command() > Maybe you want to include that into Run_command(), that would make the code tidier. Also when wait is in loop, I think one second is too long time, if there is multiple commands to execute... > My problem is how to solve insertion of user name and password as well > as the command 'ls -R' > You can watch for some mark of end of execution, example: Instead of: ls -R Use: ls -R ; echo '-->command executed<--' And in read event check when sStr includes that mark. There is no input at all after user name and password? You cannot configure ftp server to give any? Maybe you need to use wait with those two... at the moment no good ideas in my mind. Jussi From rolf.frogs at ...221... Fri Feb 3 18:41:43 2012 From: rolf.frogs at ...221... (Rolf Schmidt) Date: Fri, 03 Feb 2012 18:41:43 +0100 Subject: [Gambas-user] How to convert unix timestamp into gambas date and time In-Reply-To: <4F2BF82E.2000604@...1...> References: <4F2AD8BC.90501@...2594...> <4F2B912A.6040200@...221...> <4F2BA990.8050605@...2594...> <4F2BB221.5020600@...221...> <4F2BF3CA.7090701@...2594...> <4F2BF82E.2000604@...1...> Message-ID: <4F2C1C57.7000804@...2594...> Hello Beno?t > Unix time stamp is a number of seconds since 1/1/1970. > > So to convert a Gambas date to Unix timestamp: > > Print DateDiff(CDate("1/1/1970"), Now, gb.Second) > > And to convert an Unix timestamp to Gambas date: > > Print DateAdd(CDate("1/1/1970"), TimeStamp, gb.Second) > After swapping the last two arguments of DateAdd it works as expected. Perhaps this could be a note in the documentation of Gambas. Many Thanks Rolf From mohareve at ...626... Fri Feb 3 19:42:47 2012 From: mohareve at ...626... (M. Cs.) Date: Fri, 3 Feb 2012 19:42:47 +0100 Subject: [Gambas-user] I need your help with Processes In-Reply-To: References: Message-ID: I've managed to decrease the problem. I can create a ~/.netrc and I can place all the required data into it. So I'm able to reach the ftp server with Run_command("ftp ftp.mysite.com") , and I'm in. But how can I execute something inside that very same process? I don't understand that bubbling conception of Processes! If I would tell SHELL "ls ./public_home -R" it would open another virtual terminal, isn't? What would $hProcess=Exec["ls","./public_html","-R"] for Read do? I need some solid things! 2012/2/3, Jussi Lahtinen : >> Repeat >> wait 1 >> Until checker=TRUE >> checker=FALSE >> After every Run_command() >> > > Maybe you want to include that into Run_command(), that would make the code > tidier. > Also when wait is in loop, I think one second is too long time, if there is > multiple commands to execute... > > > > >> My problem is how to solve insertion of user name and password as well >> as the command 'ls -R' >> > > You can watch for some mark of end of execution, example: > Instead of: > ls -R > > Use: > ls -R ; echo '-->command executed<--' > > And in read event check when sStr includes that mark. > > There is no input at all after user name and password? > You cannot configure ftp server to give any? > > Maybe you need to use wait with those two... at the moment no good ideas in > my mind. > > > Jussi > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From mohareve at ...626... Fri Feb 3 20:31:27 2012 From: mohareve at ...626... (M. Cs.) Date: Fri, 3 Feb 2012 20:31:27 +0100 Subject: [Gambas-user] I need your help with Processes In-Reply-To: References: Message-ID: Success! I'm going to share it with you: Public $hProcess As Process Private $sText As String Public Sub Main() Dim fajl As File Dim i As Integer $hProcess = Exec ["ftp", "ftp.mysite.com"] For Input Output As "Process" Run_command("cd ./public_html") Repeat Wait 0.1 Until InStr($sText, "OK. Current directory") > 0 $sText = "" Run_command("ls -lR") Repeat Wait 0.1 Until InStr($sText, "matches total") > 0 fajl = Open User.Home & "/Csabax.txt" For Write Create Print #fajl, $sText Close (fajl) $sText = "" Run_command("quit") '$hProcess.Kill End Public Sub Process_Read() Dim sStr As String Read #$hProcess, sStr, -256 $sText = $sText & sStr End Public Sub Run_command(cmd As String) Dim sLig As String sLig = cmd & gb.NewLine sLig = Conv$(sLig, Desktop.Charset, System.Charset) Print #$hProcess, sLig End 2012/2/3, M. Cs. : > I've managed to decrease the problem. I can create a ~/.netrc and I > can place all the required data into it. So I'm able to reach the ftp > server with > Run_command("ftp ftp.mysite.com") , and I'm in. > But how can I execute something inside that very same process? > I don't understand that bubbling conception of Processes! > If I would tell SHELL "ls ./public_home -R" it would open another > virtual terminal, isn't? > What would $hProcess=Exec["ls","./public_html","-R"] for Read do? > I need some solid things! > > 2012/2/3, Jussi Lahtinen : >>> Repeat >>> wait 1 >>> Until checker=TRUE >>> checker=FALSE >>> After every Run_command() >>> >> >> Maybe you want to include that into Run_command(), that would make the >> code >> tidier. >> Also when wait is in loop, I think one second is too long time, if there >> is >> multiple commands to execute... >> >> >> >> >>> My problem is how to solve insertion of user name and password as well >>> as the command 'ls -R' >>> >> >> You can watch for some mark of end of execution, example: >> Instead of: >> ls -R >> >> Use: >> ls -R ; echo '-->command executed<--' >> >> And in read event check when sStr includes that mark. >> >> There is no input at all after user name and password? >> You cannot configure ftp server to give any? >> >> Maybe you need to use wait with those two... at the moment no good ideas >> in >> my mind. >> >> >> Jussi >> ------------------------------------------------------------------------------ >> Try before you buy = See our experts in action! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-dev2 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > From john.aaron.rose at ...626... Fri Feb 3 20:51:53 2012 From: john.aaron.rose at ...626... (John Rose) Date: Fri, 03 Feb 2012 19:51:53 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1328298713.3990.19.camel@...2661...> I've looked at the Database example and I still don't understand how to use the DataSource & DataBrowser controls. My DataSourceCountry control has its Table property set to country (one of the tables in the Test.db SQLite3 database in the Data directory of the attached Test project. In the Form_Open procedure, the variable DatabaseConnection was previously created successfully (i.e. before I added these 2 controls) and database opened OK. In that procedure, the Connection property of DataSourceCountry is set to this variable: should I do that? My DataBrowserCountry control has Columns set to country (which is one of the columns in the country table, though not the primary key) and Editable set to True. The project compiles & saves OK. When I try to run it, a popup comes up either with 'Null object' or 'Driver name missing'. Any ideas please. -------------- next part -------------- A non-text attachment was scrubbed... Name: Test.tar.gz Type: application/x-compressed-tar Size: 18063 bytes Desc: not available URL: From tobiasboe1 at ...20... Fri Feb 3 21:13:20 2012 From: tobiasboe1 at ...20... (tobias) Date: Fri, 03 Feb 2012 21:13:20 +0100 Subject: [Gambas-user] Last in group event handler called as function Message-ID: <4F2C3FE0.8040402@...20...> hi, consider the following (where "PickColor" is the event name of a group of ToogleButton controls) Public Sub Form_Open() PickColor_Click() End Public Sub PickColor_Click() Print Last End since the event handlers are just subroutines one may call them as every other sub. i can imagine that Last is set properly for a single event raising object to avoid errors when the event handler uses Last but is not a risen event (i haven't looked at any event handler dispatcher code of the interpreter or something, so i don't know where Last is set). but what's about an event group? which object will Last be in this situation? in my code (which is, of course, a bit more complex) i always get the same ToggleButton printed but i can't spot any reason. regards, tobi From tobiasboe1 at ...20... Sat Feb 4 01:12:49 2012 From: tobiasboe1 at ...20... (tobias) Date: Sat, 04 Feb 2012 01:12:49 +0100 Subject: [Gambas-user] Help for Image and Picture Colors Message-ID: <4F2C7801.3060907@...20...> Hi, I really need help. There's a lot of work with colors in Images and Pictures in a project and between these classes. This is generally speaking as follows: I have a class which has an 8*8px Image which is manipulated (due to the easy of accessing pixels directly). Using a property of my class, I provide access to a scaled version of the Image as a Picture (which is created when requested). So I do some things and when manually resizing the Image to get the prototype of the Picture to return (it is needed as bigger version of the Image without anti-aliasing, I don't get this result with Image.Stretch(), and doing it manually is not a problem) there seem to appear problems with transparency. I read that Pictures do not have an alpha channel and I noticed that colors from the ColorChooser or Color class are given with alpha channel set to 0x00 which will be transparent for the Image class... so I tried adding &Hff000000& to whatever color is assigned to any pixel in the 8*8px Image or not to do it and some other experiments but nothing worked on the entire project. there's always something transparent or black or whatever. I really go nuts with this. Anyone to my rescue? Regards, Tobi From tobiasboe1 at ...20... Sat Feb 4 01:19:46 2012 From: tobiasboe1 at ...20... (tobias) Date: Sat, 04 Feb 2012 01:19:46 +0100 Subject: [Gambas-user] Help for Image and Picture Colors In-Reply-To: <4F2C7801.3060907@...20...> References: <4F2C7801.3060907@...20...> Message-ID: <4F2C79A1.3010706@...20...> On 04.02.2012 01:12, tobias wrote: > Hi, > > I really need help. There's a lot of work with colors in Images and > Pictures in a project and between these classes. This is generally > speaking as follows: I have a class which has an 8*8px Image which is > manipulated (due to the easy of accessing pixels directly). Using a > property of my class, I provide access to a scaled version of the Image > as a Picture (which is created when requested). So I do some things and > when manually resizing the Image to get the prototype of the Picture to > return (it is needed as bigger version of the Image without > anti-aliasing, I don't get this result with Image.Stretch(), and doing > it manually is not a problem) there seem to appear problems with > transparency. I read that Pictures do not have an alpha channel and I > noticed that colors from the ColorChooser or Color class are given with > alpha channel set to 0x00 which will be transparent for the Image > class... so I tried adding&Hff000000& to whatever color is assigned to > any pixel in the 8*8px Image or not to do it and some other experiments > but nothing worked on the entire project. there's always something > transparent or black or whatever. I really go nuts with this. Anyone to > my rescue? > > Regards, > Tobi wait a minute. I forgot to say that I don't even need the transparency feature of the Image class. I only use Image - as I said - because of Image[x, y] pixel access. For the meantime - or as a final solution? there may be a lot of those accesses and I thought using Image[x, y] will be the most efficient way to go - I switch to using an 8*8px Picture and Draw.Pixel() instead but I would really appreciate anyone clarify this topic to me. From shanep1967 at ...169... Sat Feb 4 02:05:24 2012 From: shanep1967 at ...169... (Shane Powell) Date: Sat, 04 Feb 2012 12:05:24 +1100 Subject: [Gambas-user] inheritance problems Message-ID: <4F2C8454.40800@...169...> I have this in my program class 1 public array of class 2 class 2 inherits class 1 access array of class 2 in class 1 but array is empty but i know it has elements in it what am i doing wrong ? From nando_f at ...951... Sat Feb 4 05:55:58 2012 From: nando_f at ...951... (nando) Date: Fri, 3 Feb 2012 23:55:58 -0500 Subject: [Gambas-user] Pointer-Memory Question In-Reply-To: <2877541.QEkvIETUOs@...46...> References: <2877541.QEkvIETUOs@...46...> Message-ID: <20120204045315.M6475@...951...> Is this a possible reason? Write #strm moves the "pointer" to 4 past where it was first set. Read is reading a SINGLE immediately after what you wrote You need to seek backwards 4 places ?? -Fernando ---------- Original Message ----------- From: Wally To: Gambas-user at lists.sourceforge.net Sent: Fri, 03 Feb 2012 15:13:57 +0100 Subject: [Gambas-user] Pointer-Memory Question > What is wrong in this code ? > > Public Sub Button1_Click() > > Dim f, r As Single > Dim pPtr As Pointer > Dim strm As Stream > > f = 1 / 3 > > pPtr = Alloc(1, 4) 'alloc 4 * 1 Byte for single > > strm = Memory pPtr For Read Write > > Write #strm, f As Single > > r = Read #strm As Single > > Print f ' --> 0.3333333 > Print r ' --> 1.261169E-44 > > Close #strm > Free(pPtr) > > End > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From nando_f at ...951... Sat Feb 4 05:57:54 2012 From: nando_f at ...951... (nando) Date: Fri, 3 Feb 2012 23:57:54 -0500 Subject: [Gambas-user] inheritance problems In-Reply-To: <4F2C8454.40800@...169...> References: <4F2C8454.40800@...169...> Message-ID: <20120204045658.M57246@...951...> How can it be empty AND have elements in it? ---------- Original Message ----------- From: Shane Powell To: mailing list for gambas users Sent: Sat, 04 Feb 2012 12:05:24 +1100 Subject: [Gambas-user] inheritance problems > I have this in my program > > class 1 > public array of class 2 > > class 2 > inherits class 1 > access array of class 2 in class 1 > but array is empty but i know it has elements in it > > what am i doing wrong ? > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From shanep1967 at ...169... Sat Feb 4 07:16:17 2012 From: shanep1967 at ...169... (Shane Powell) Date: Sat, 04 Feb 2012 17:16:17 +1100 Subject: [Gambas-user] inheritance problems In-Reply-To: <20120204045658.M57246@...951...> References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> Message-ID: <4F2CCD31.9020706@...169...> On 04/02/12 15:57, nando wrote: > How can it be empty AND have elements in it? > > > ---------- Original Message ----------- > From: Shane Powell > To: mailing list for gambas users > Sent: Sat, 04 Feb 2012 12:05:24 +1100 > Subject: [Gambas-user] inheritance problems > >> I have this in my program >> >> class 1 >> public array of class 2 >> >> class 2 >> inherits class 1 >> access array of class 2 in class 1 >> but array is empty but i know it has elements in it >> >> what am i doing wrong ? >> >> ------------------------------------------------------------------------------ >> Try before you buy = See our experts in action! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-dev2 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > thats what i want to know it seems that public variables are copy when a class is inherited and the value they where when you inherit them is only used from then on i made a test app i must be doing something wrong this app just uses integers -------------- next part -------------- A non-text attachment was scrubbed... Name: ClassTest-0.0.1.tar.gz Type: application/x-gzip Size: 4938 bytes Desc: not available URL: From nando_f at ...951... Sat Feb 4 07:42:31 2012 From: nando_f at ...951... (nando) Date: Sat, 4 Feb 2012 01:42:31 -0500 Subject: [Gambas-user] inheritance problems In-Reply-To: <4F2CCD31.9020706@...169...> References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> <4F2CCD31.9020706@...169...> Message-ID: <20120204064145.M2922@...951...> PUBLIC myint is only exactly one variable. It's public. ---------- Original Message ----------- From: Shane Powell To: nando_f at ...951..., mailing list for gambas users Sent: Sat, 04 Feb 2012 17:16:17 +1100 Subject: Re: [Gambas-user] inheritance problems > On 04/02/12 15:57, nando wrote: > > How can it be empty AND have elements in it? > > > > > > ---------- Original Message ----------- > > From: Shane Powell > > To: mailing list for gambas users > > Sent: Sat, 04 Feb 2012 12:05:24 +1100 > > Subject: [Gambas-user] inheritance problems > > > >> I have this in my program > >> > >> class 1 > >> public array of class 2 > >> > >> class 2 > >> inherits class 1 > >> access array of class 2 in class 1 > >> but array is empty but i know it has elements in it > >> > >> what am i doing wrong ? > >> > >> ------------------------------------------------------------------------------ > >> Try before you buy = See our experts in action! > >> The most comprehensive online learning library for Microsoft developers > >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > >> Metro Style Apps, more. Free future releases when you subscribe now! > >> http://p.sf.net/sfu/learndevnow-dev2 > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > ------- End of Original Message ------- > > > > > > ------------------------------------------------------------------------------ > > Try before you buy = See our experts in action! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-dev2 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > thats what i want to know it seems that public variables are copy when a > class is inherited > and the value they where when you inherit them is only used from then on > > i made a test app i must be doing something wrong > this app just uses integers ------- End of Original Message ------- From shanep1967 at ...169... Sat Feb 4 09:31:27 2012 From: shanep1967 at ...169... (Shane Powell) Date: Sat, 04 Feb 2012 19:31:27 +1100 Subject: [Gambas-user] inheritance problems In-Reply-To: <20120204064145.M2922@...951...> References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> <4F2CCD31.9020706@...169...> <20120204064145.M2922@...951...> Message-ID: <4F2CECDF.9070304@...169...> On 04/02/12 17:42, nando wrote: > PUBLIC myint is only exactly one variable. > It's public. > > > ---------- Original Message ----------- > From: Shane Powell > To: nando_f at ...951..., mailing list for gambas users > > Sent: Sat, 04 Feb 2012 17:16:17 +1100 > Subject: Re: [Gambas-user] inheritance problems > >> On 04/02/12 15:57, nando wrote: >>> How can it be empty AND have elements in it? >>> >>> >>> ---------- Original Message ----------- >>> From: Shane Powell >>> To: mailing list for gambas users >>> Sent: Sat, 04 Feb 2012 12:05:24 +1100 >>> Subject: [Gambas-user] inheritance problems >>> >>>> I have this in my program >>>> >>>> class 1 >>>> public array of class 2 >>>> >>>> class 2 >>>> inherits class 1 >>>> access array of class 2 in class 1 >>>> but array is empty but i know it has elements in it >>>> >>>> what am i doing wrong ? >>>> >>>> ------------------------------------------------------------------------------ >>>> Try before you buy = See our experts in action! >>>> The most comprehensive online learning library for Microsoft developers >>>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >>>> Metro Style Apps, more. Free future releases when you subscribe now! >>>> http://p.sf.net/sfu/learndevnow-dev2 >>>> _______________________________________________ >>>> Gambas-user mailing list >>>> Gambas-user at lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> ------- End of Original Message ------- >>> >>> >>> ------------------------------------------------------------------------------ >>> Try before you buy = See our experts in action! >>> The most comprehensive online learning library for Microsoft developers >>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >>> Metro Style Apps, more. Free future releases when you subscribe now! >>> http://p.sf.net/sfu/learndevnow-dev2 >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >>> >>> >> thats what i want to know it seems that public variables are copy when a >> class is inherited >> and the value they where when you inherit them is only used from then on >> >> i made a test app i must be doing something wrong >> this app just uses integers > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > sorry don't know what you mean From jussi.lahtinen at ...626... Sat Feb 4 13:42:15 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sat, 4 Feb 2012 14:42:15 +0200 Subject: [Gambas-user] inheritance problems In-Reply-To: <4F2C8454.40800@...169...> References: <4F2C8454.40800@...169...> Message-ID: Seems like circular reference. Class2 inherits array of it self, which then inherits array of it self, which ... Jussi On Sat, Feb 4, 2012 at 03:05, Shane Powell wrote: > > I have this in my program > > class 1 > public array of class 2 > > class 2 > inherits class 1 > access array of class 2 in class 1 > but array is empty but i know it has elements in it > > what am i doing wrong ? > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jussi.lahtinen at ...626... Sat Feb 4 13:43:38 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sat, 4 Feb 2012 14:43:38 +0200 Subject: [Gambas-user] inheritance problems In-Reply-To: References: <4F2C8454.40800@...169...> Message-ID: I think you need to send project which demonstrates this problem. Maybe Gambas should raise error. Jussi On Sat, Feb 4, 2012 at 14:42, Jussi Lahtinen wrote: > Seems like circular reference. > Class2 inherits array of it self, which then inherits array of it self, > which ... > > Jussi > > > > > On Sat, Feb 4, 2012 at 03:05, Shane Powell wrote: > >> >> I have this in my program >> >> class 1 >> public array of class 2 >> >> class 2 >> inherits class 1 >> access array of class 2 in class 1 >> but array is empty but i know it has elements in it >> >> what am i doing wrong ? >> >> >> >> ------------------------------------------------------------------------------ >> Try before you buy = See our experts in action! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-dev2 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > From gambas at ...2524... Sat Feb 4 16:05:05 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sat, 04 Feb 2012 15:05:05 +0000 Subject: [Gambas-user] Issue 199 in gambas: LostFocus & Leave events not activated for ValueBox In-Reply-To: <4-6813199134517018827-10985591416947314832-gambas=googlecode.com@...2524...> References: <4-6813199134517018827-10985591416947314832-gambas=googlecode.com@...2524...> <0-6813199134517018827-10985591416947314832-gambas=googlecode.com@...2524...> Message-ID: <5-6813199134517018827-10985591416947314832-gambas=googlecode.com@...2524...> Comment #5 on issue 199 by john.aaron.rose at ...626...: LostFocus & Leave events not activated for ValueBox http://code.google.com/p/gambas/issues/detail?id=199 Tested in version #4445 and OK. From mohareve at ...626... Sat Feb 4 17:48:59 2012 From: mohareve at ...626... (M. Cs.) Date: Sat, 4 Feb 2012 17:48:59 +0100 Subject: [Gambas-user] Creating button as class element with variable function Message-ID: Is it possible to create a button with dinamically changeable action? I would like to have something like: Public Sub AddGomb2(sz As Integer, m As Integer, x As Integer, y As Integer, q As Container, szoveg As String, operation as String) Dim gomb As Button gomb = New Button(q) As "Gomb2" gomb.Width = sz gomb.Height = m gomb.X = x gomb.Y = y gomb.Text = szoveg End I would like to replace "Gomb1" with a passed value, so to have a reusable button upon creation. I mean, if I have multiple buttons on a form, i would use: myclass.AddGomb2(....,"action1") myclass.AddGomb2(....,"action2") myclass.AddGomb2(....,"action3") Is that manageable? From nando_f at ...951... Sat Feb 4 19:51:57 2012 From: nando_f at ...951... (nando) Date: Sat, 4 Feb 2012 13:51:57 -0500 Subject: [Gambas-user] inheritance problems In-Reply-To: <4F2CECDF.9070304@...169...> References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> <4F2CCD31.9020706@...169...> <20120204064145.M2922@...951...> <4F2CECDF.9070304@...169...> Message-ID: <20120204184421.M41312@...951...> The sample code you provided used PUBLIC INT myint What happens is that myint is only one instantiated variable and is public in scope. Code see's the one and only variable. There are not separate vars. Your example of array of classes and inheritance is kinda odd because of circular references. If you deliberately program this way, you'll get a headache. Looks like it's starting. ---------- Original Message ----------- From: Shane Powell To: nando_f at ...951..., mailing list for gambas users Sent: Sat, 04 Feb 2012 19:31:27 +1100 Subject: Re: [Gambas-user] inheritance problems > On 04/02/12 17:42, nando wrote: > > PUBLIC myint is only exactly one variable. > > It's public. > > > > > > ---------- Original Message ----------- > > From: Shane Powell > > To: nando_f at ...951..., mailing list for gambas users > > > > Sent: Sat, 04 Feb 2012 17:16:17 +1100 > > Subject: Re: [Gambas-user] inheritance problems > > > >> On 04/02/12 15:57, nando wrote: > >>> How can it be empty AND have elements in it? > >>> > >>> > >>> ---------- Original Message ----------- > >>> From: Shane Powell > >>> To: mailing list for gambas users > >>> Sent: Sat, 04 Feb 2012 12:05:24 +1100 > >>> Subject: [Gambas-user] inheritance problems > >>> > >>>> I have this in my program > >>>> > >>>> class 1 > >>>> public array of class 2 > >>>> > >>>> class 2 > >>>> inherits class 1 > >>>> access array of class 2 in class 1 > >>>> but array is empty but i know it has elements in it > >>>> > >>>> what am i doing wrong ? > >>>> > >>>> ------------------------------------------------------------------------------ > >>>> Try before you buy = See our experts in action! > >>>> The most comprehensive online learning library for Microsoft developers > >>>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > >>>> Metro Style Apps, more. Free future releases when you subscribe now! > >>>> http://p.sf.net/sfu/learndevnow-dev2 > >>>> _______________________________________________ > >>>> Gambas-user mailing list > >>>> Gambas-user at lists.sourceforge.net > >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>> ------- End of Original Message ------- > >>> > >>> > >>> ------------------------------------------------------------------------------ > >>> Try before you buy = See our experts in action! > >>> The most comprehensive online learning library for Microsoft developers > >>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > >>> Metro Style Apps, more. Free future releases when you subscribe now! > >>> http://p.sf.net/sfu/learndevnow-dev2 > >>> _______________________________________________ > >>> Gambas-user mailing list > >>> Gambas-user at lists.sourceforge.net > >>> https://lists.sourceforge.net/lists/listinfo/gambas-user > >>> > >>> > >>> > >> thats what i want to know it seems that public variables are copy when a > >> class is inherited > >> and the value they where when you inherit them is only used from then on > >> > >> i made a test app i must be doing something wrong > >> this app just uses integers > > ------- End of Original Message ------- > > > > > > ------------------------------------------------------------------------------ > > Try before you buy = See our experts in action! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-dev2 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > sorry don't know what you mean > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From jussi.lahtinen at ...626... Sat Feb 4 20:34:57 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sat, 4 Feb 2012 21:34:57 +0200 Subject: [Gambas-user] inheritance problems In-Reply-To: <4F2CCD31.9020706@...169...> References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> <4F2CCD31.9020706@...169...> Message-ID: > thats what i want to know it seems that public variables are copy when a > class is inherited > and the value they where when you inherit them is only used from then on > > i made a test app i must be doing something wrong > this app just uses integers > There are two objects, myc1 and myc2. And you increase value of myint of myc1. Only declarations of variables are inherited, not values of them unless their are static. What you expect to happen? Jussi From abbat.81 at ...787... Sun Feb 5 00:01:59 2012 From: abbat.81 at ...787... (abbat) Date: Sat, 4 Feb 2012 15:01:59 -0800 (PST) Subject: [Gambas-user] Send from .module to .class Message-ID: <33264477.post@...1379...> How can I send a string "test_string" from Main.module to Label1 which situated on MFmain.class Thanks -- View this message in context: http://old.nabble.com/Send-from-.module-to-.class-tp33264477p33264477.html Sent from the gambas-user mailing list archive at Nabble.com. From shanep1967 at ...169... Sun Feb 5 00:17:37 2012 From: shanep1967 at ...169... (Shane Powell) Date: Sun, 05 Feb 2012 10:17:37 +1100 Subject: [Gambas-user] inheritance problems In-Reply-To: References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> <4F2CCD31.9020706@...169...> Message-ID: <4F2DBC91.70106@...169...> On 05/02/12 06:34, Jussi Lahtinen wrote: >> thats what i want to know it seems that public variables are copy when a >> class is inherited >> and the value they where when you inherit them is only used from then on >> >> i made a test app i must be doing something wrong >> this app just uses integers >> > There are two objects, myc1 and myc2. > And you increase value of myint of myc1. > > Only declarations of variables are inherited, not values of them unless > their are static. > > What you expect to happen? > > Jussi > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > I'm obviously looking at this inheritance thing all wrong back to the drawing board thanks. From jussi.lahtinen at ...626... Sun Feb 5 01:07:35 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 5 Feb 2012 02:07:35 +0200 Subject: [Gambas-user] Send from .module to .class In-Reply-To: <33264477.post@...1379...> References: <33264477.post@...1379...> Message-ID: Controls have property name Public, set it to True. Jussi On Sun, Feb 5, 2012 at 01:01, abbat wrote: > > How can I send a string "test_string" from > Main.module > to > Label1 which situated on > MFmain.class > > Thanks > > > -- > View this message in context: > http://old.nabble.com/Send-from-.module-to-.class-tp33264477p33264477.html > Sent from the gambas-user mailing list archive at Nabble.com. > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From ian.roper at ...1974... Sun Feb 5 03:55:56 2012 From: ian.roper at ...1974... (Ian Roper) Date: Sun, 05 Feb 2012 10:55:56 +0800 Subject: [Gambas-user] Editor Control (gb.qt4.ext) - Some questions. In-Reply-To: References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> <4F2CCD31.9020706@...169...> Message-ID: <1328410556.3199.59.camel@...2506...> In the Editor control from gb.qt4.ext # Context When reviewing text read from a file in an Editor Control. # Highlighting When MyEditorControl.Highlight attribute is set to 'Normal', the 'end-of-line' ( gb.crlf ) character is displayed as a musical note symbol ? I have tried various fonts but the symbol is the same for each font. If you use another highlight value ( Gambas, SQL...) then the symbol is NOT displayed. Q: Is there any way to disable this symbol displaying in 'Normal' mode ? # Select All When you call the editor function to MyEditorControl.SelectAll in code, it selects all the text lines but dose not highlight the code. All the text is selected and you can copy to clipboard and paste as required. If you do this manually by using the mouse - this works ok - all text is highlighted. If you use the shortcut keys Ctrl-A - this works ok- all text is highlighted. Q: Is there a parameter I can set to highlight all the text when 'MyEditorControl.SelectAll' is actioned ? # Wordwrap There is no parameter I can set to 'word-wrap' text if there is no embedded 'end-of-line' character. Q: Is it possible to add this functionality as a standard control parameter ? # LineNumbering The MyEditorControl.ShowLineNumbers functionality for Editor controls cannot be accessed ( Read Only) In the context Help is says: "Set this flag to display line numbers" but it is read-only. Q: How can you set this flag ? Q: Is it possible to be able to set this to True/False to show line numbers in the control ? Regards, Ian Roper Perth - Western Australia. From rterry at ...1823... Sun Feb 5 08:04:55 2012 From: rterry at ...1823... (richard terry) Date: Sun, 5 Feb 2012 18:04:55 +1100 Subject: [Gambas-user] Ambiguous shortcut overload Message-ID: <201202051804.55764.rterry@...1823...> Hi list I wanted to detect ctrl+alt+letter keypress putting this code in the form_key event detects the ctl+alt Dim ctlDown as boolean Dim altDown as boolean Try CtrlDown = Key.Control Try altDown = Key.alt If CtrlDown And altDown Then 'works ok 'but adding this: Select Case Key.Code case 66 'b 'do something here. end select end if gives this error message. QAction::eventFilter: Ambiguous shortcut overload: Ctrl+Alt+B Any hints as to what I'm doing wrong? Regards Richard From gambas at ...1... Sun Feb 5 08:37:57 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 05 Feb 2012 08:37:57 +0100 Subject: [Gambas-user] extern library In-Reply-To: <4F28F135.2070300@...1740...> References: <3525035.btJeaiBlXI@...46...> <1756961.yBaByDlCDY@...46...> <4F273130.7040608@...1...> <4F28F135.2070300@...1740...> Message-ID: <4F2E31D5.60706@...1...> Le 01/02/2012 09:00, Ron a ?crit : > On 31-1-2012 1:09, Beno?t Minisini wrote: >> Le 29/01/2012 21:33, Wally a ?crit : >>> No other way ? >>> >> Normally the library can be any path, like any data file. So: >> >> - It is searched as a real file (absolute path, or standard library paths). >> >> - If it is not found, then it is searched inside the project. >> >> If you don't succeed in loading your library, please send me a little >> test project. >> >> Regards, >> > I believe storing it anywhere else than a library path didn't work for > me in my project, but I will check again. > I'm talking about gambas2. > > Regards, > Ron_2nd. > I was talking about gambas 3. In Gambas 2, the library is never searched inside the project. -- Beno?t Minisini From kevinfishburne at ...1887... Sun Feb 5 08:39:43 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Sun, 05 Feb 2012 02:39:43 -0500 Subject: [Gambas-user] gb3: converting structures to classes Message-ID: <4F2E323F.9010101@...1887...> I tried to find the previous email suggesting this and couldn't, neither is there an equivalent wiki article describing class creation as there is with structure creation, so I'm asking here. I need to know how to convert structure declarations to class declarations, and if there are any obvious syntactical differences in declaration, assignment as properties to other classes, or assigning actual data. I'm using structures like this: Public Struct Client_Animation Animating As Boolean OrientationDefault As Single OrientationBegin As Single OrientationEnd As Single OrientationCurrent As Single OrientationVelocity As Single PositionDefaultX As Single PositionDefaultY As Single PositionBeginX As Single PositionBeginY As Single PositionEndX As Single PositionEndY As Single PositionCurrentX As Single PositionCurrentY As Single PositionVelocityX As Single PositionVelocityY As Single End Struct Public Struct Client_Gear Orientation As Single Scale As Single SizeCap As Short SizeStem As Short Skin As Short Type As Short Animation As Struct Client_Animation End Struct The logic behind the change is wanting these (numerous) structure declarations to be contained within their own module for organizational purposes and to be accessible between modules. It was suggested in previous emails that this was possible using classes instead of structures. Thanks everyone. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From gambas at ...1... Sun Feb 5 08:40:28 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 05 Feb 2012 08:40:28 +0100 Subject: [Gambas-user] gb.GeneralDate formatting is inconsistent In-Reply-To: References: Message-ID: <4F2E326C.8040201@...1...> Le 03/02/2012 05:41, Zach Smith a ?crit : > The gb.GeneralDate formatting appears to be inconsistent in the > handling of time 00:00:00.. > > > Dim d1 As Date, d2 As Date, d3 As Date > > d1 = CDate("1/1/2003 00:00:00") > d2 = CDate("1/1/2003") > d3 = CDate("00:00:00") > > Print Format(d1, gb.GeneralDate) > Print Format(d2, gb.GeneralDate) > Print Format(d3, gb.GeneralDate) > > > Results in: > 01/01/03 > 01/01/03 > 00:00:00 > > Shouldn't the first line return this? > 01/01/03 00:00:00 > Actually the third formatting is inconsistent. gb.GeneralDate prints the date part the short way (dd/mm/yy) and prints the time if it is not zero. But CDate("00:00:00") is a special value, the "null" date. It should print nothing, as IsNull(CDate("00:00:00")) = True. Regards, -- Beno?t Minisini From gambas at ...1... Sun Feb 5 09:08:46 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 05 Feb 2012 09:08:46 +0100 Subject: [Gambas-user] gb.GeneralDate formatting is inconsistent In-Reply-To: <4F2E326C.8040201@...1...> References: <4F2E326C.8040201@...1...> Message-ID: <4F2E390E.1070408@...1...> Le 05/02/2012 08:40, Beno?t Minisini a ?crit : > Le 03/02/2012 05:41, Zach Smith a ?crit : >> The gb.GeneralDate formatting appears to be inconsistent in the >> handling of time 00:00:00.. >> >> ... > > Actually the third formatting is inconsistent. > > gb.GeneralDate prints the date part the short way (dd/mm/yy) and prints > the time if it is not zero. > > But CDate("00:00:00") is a special value, the "null" date. It should > print nothing, as IsNull(CDate("00:00:00")) = True. > > Regards, > It should be more consistent now in revision #4449. Regards, -- Beno?t Minisini From gambas at ...1... Sun Feb 5 09:10:14 2012 From: gambas at ...1... (=?UTF-8?B?QmVub8OudCBNaW5pc2luaQ==?=) Date: Sun, 05 Feb 2012 09:10:14 +0100 Subject: [Gambas-user] how to insert hImage into table sqlite base In-Reply-To: References: <4F2AC3BB.3010800@...27...> Message-ID: <4F2E3966.3060207@...1...> Le 03/02/2012 08:10, ??????? ???????? a ?crit : > Thank you. > > My code: > Dim sql As String > Dim ImageBlob As String > Dim ResultImg As Result > ImageBlob = File.Load(sFile) > Conn = Connections["Connection1"] > > This code works: > ResultImg = Conn.Create("images_test") > ResultImg["dirname"] = sFile > ResultImg["image"] = ImageBlob > ResultImg.Update() > > This code not works > sql = "INSERT INTO images_test (dirname, image) VALUES(&1,&2)" > sql = Conn.Subst(sql, sFile, ImageBlob) > Conn.Exec(sql) > > Gambas is freezes. > Please give more details: what is your image exactly? Do you succeed in inserting it by using the "PictureDatabase" example? -- Beno?t Minisini From john.aaron.rose at ...626... Sun Feb 5 09:12:39 2012 From: john.aaron.rose at ...626... (John Rose) Date: Sun, 05 Feb 2012 08:12:39 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1328429559.3750.23.camel@...2661...> I found a message from 16 December 2011 re this problem. The author's solution (author is michael) is: "keep all Db access in a separate class called "data" which handles all communication with the database. I then start my apps with a "Main" module not a form. The Main module will load resources (such as Db Connector), test the Db connection, check password etc, and only then load the first form in the hierarchy.". When I set my attached Test project to use a module named MDatabase (PS this is the way I do it in my development project) which is called by my Startup module named MMain which now calls my form named FMain (no longer Startup), I got a compile error 'Missing As in line 5'. The module starts with: ' Gambas module file ' ' Dialog.Path = User.Home Could anyone indicate how a module, specified as Startup, should be coded at its start? PS I've looked at the Example Database project database but that does not run correctly nor does it show properties of controls (presumably suppressed due to the project being read-only). -------------- next part -------------- A non-text attachment was scrubbed... Name: Test.tar.gz Type: application/x-compressed-tar Size: 18802 bytes Desc: not available URL: From john.aaron.rose at ...626... Sun Feb 5 10:49:59 2012 From: john.aaron.rose at ...626... (John Rose) Date: Sun, 05 Feb 2012 09:49:59 +0000 Subject: [Gambas-user] gb.db.form driver missing Message-ID: <1328435399.3750.32.camel@...2661...> Michael, I've been trying to get the DataSource & DataBrowser controls working on Gambas3 revision #4445 and I also ran into this problem of 'Driver Missing'. I goggled & found yours & Tobias' posts on this. I've tried to implement your method. When I set my attached Test project to use a module named MDatabase which is called by my Startup module named MMain which now calls my form named FMain (no longer Startup), I get a compile error 'Missing As in line 5'. The module starts with: ' Gambas module file ' ' Dialog.Path = User.Home Could you tell me how a module, specified as Startup, should be coded at its start? -------------- next part -------------- A non-text attachment was scrubbed... Name: Test.tar.gz Type: application/x-compressed-tar Size: 18802 bytes Desc: not available URL: From wally at ...2037... Sun Feb 5 18:42:38 2012 From: wally at ...2037... (Wally) Date: Sun, 05 Feb 2012 18:42:38 +0100 Subject: [Gambas-user] extern library In-Reply-To: <4F2E31D5.60706@...1...> References: <3525035.btJeaiBlXI@...46...> <4F28F135.2070300@...1740...> <4F2E31D5.60706@...1...> Message-ID: <1559919.WVzDYH7Lhk@...46...> talking about Gambas 3: When i place my library to /usr/local/lib and run ldconfig it works and my_gb3_project can find the lib and its functions. When i put it into my_gb3_project folder the library can not be found. Where to place the library ganbas3 may find it ? In e.g. my_gb3_Project/ or one of the hidden subfolders ? Do i need to make changes in project properties ? on topmost of the single form project Library "libMyLib:0" (a symbolic link libMyLib.so.0 ---> libMyLib.so exists also tried Library "libMyLib" both are not found. On Sunday, February 05, 2012 08:37:57 Beno?t Minisini wrote: > Le 01/02/2012 09:00, Ron a ?crit : > > On 31-1-2012 1:09, Beno?t Minisini wrote: > >> Le 29/01/2012 21:33, Wally a ?crit : > >>> No other way ? > >> > >> Normally the library can be any path, like any data file. So: > >> > >> - It is searched as a real file (absolute path, or standard library > >> paths). > >> > >> - If it is not found, then it is searched inside the project. > >> > >> If you don't succeed in loading your library, please send me a little > >> test project. > >> > >> Regards, > > > > I believe storing it anywhere else than a library path didn't work for > > me in my project, but I will check again. > > I'm talking about gambas2. > > > > Regards, > > Ron_2nd. > > I was talking about gambas 3. In Gambas 2, the library is never searched > inside the project. From john.aaron.rose at ...626... Sun Feb 5 19:02:37 2012 From: john.aaron.rose at ...626... (John Rose) Date: Sun, 05 Feb 2012 18:02:37 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1328464957.3750.42.camel@...2661...> To try & clarify this problem, my code for the button (in my FMain form) click that opens the form which contains the DataSourceCountry & DataBrowserCountry controls is shown below. When the project runs, the FCountryMaintence form is displayed OK except that the DataSourceCountry control is empty with the controls on its base all grayed out. I know that MDatabase.DatabaseConnection is valid since it is used successfully to do other database retrievals & updates. Public Sub ButtonCountryMaintenance_Click() Dim hForm As Form hform = New FCountryMaintenance FCountryMaintenance.DataSourceCountry.Connection = MDatabase.DatabaseConnection FCountryMaintenance.DataSourceCountry.Table = "country" FCountryMaintenance.DataBrowserCountry.Columns = ["country"] hForm.Show() End From abbat.81 at ...787... Mon Feb 6 00:45:04 2012 From: abbat.81 at ...787... (abbat) Date: Sun, 5 Feb 2012 15:45:04 -0800 (PST) Subject: [Gambas-user] How To INSERT INTO in MySQL? Message-ID: <33268576.post@...1379...> I cant make to work the command for MySQL which works perfect on VB.NET Dim COMMAND = New MySqlCommand("INSERT INTO statistic (" & "TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES ('" & T & "', now(), now(),'" & kluch & "','" & Nc & "')") How to make it work? Thanks -- View this message in context: http://old.nabble.com/How-To-INSERT-INTO-in-MySQL--tp33268576p33268576.html Sent from the gambas-user mailing list archive at Nabble.com. From adamnt42 at ...626... Mon Feb 6 01:13:52 2012 From: adamnt42 at ...626... (GMail) Date: Mon, 06 Feb 2012 10:43:52 +1030 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <33268576.post@...1379...> References: <33268576.post@...1379...> Message-ID: <1328487232.9055.103.camel@...2688...> On Sun, 2012-02-05 at 15:45 -0800, abbat wrote: > I cant make to work the command for MySQL which works perfect on VB.NET > > Dim COMMAND = New MySqlCommand("INSERT INTO statistic (" & > "TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES ('" & > T & "', now(), now(),'" & kluch & "','" & Nc & "')") > > How to make it work? > Thanks > What does your MySqlCommand class look like? From robert1juhasz at ...626... Mon Feb 6 01:28:05 2012 From: robert1juhasz at ...626... (Robert Juhasz) Date: Mon, 06 Feb 2012 01:28:05 +0100 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <33268576.post@...1379...> References: <33268576.post@...1379...> Message-ID: <4F2F1E95.5020403@...626...> On 02/06/2012 12:45 AM, abbat wrote: > I cant make to work the command for MySQL which works perfect on VB.NET > > Dim COMMAND = New MySqlCommand("INSERT INTO statistic ("& > "TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES ('"& > T& "', now(), now(),'"& kluch& "','"& Nc& "')") > > How to make it work? > Thanks > > Hello, If you have a connection (e.g. myCon) then you can use it's Exec function to execute mysql commands (e.g. myCon.Exec("CREATE VIEW....")). If your command is a query then returns the result r (called resultset in VB, I think), e.g. r=myCon.Exec("SELECT * FROM ...") Robi From bespalov.av at ...626... Mon Feb 6 04:34:16 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Mon, 6 Feb 2012 09:34:16 +0600 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <4F2F1E95.5020403@...626...> References: <33268576.post@...1379...> <4F2F1E95.5020403@...626...> Message-ID: abbat, see exeple http://gambas.pro/gambas/gambas_mysql_podkluchenie.htm 2012/2/6 Robert Juhasz > On 02/06/2012 12:45 AM, abbat wrote: > > I cant make to work the command for MySQL which works perfect on VB.NET > > > > Dim COMMAND = New MySqlCommand("INSERT INTO statistic ("& > > "TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES > ('"& > > T& "', now(), now(),'"& kluch& "','"& Nc& "')") > > > > How to make it work? > > Thanks > > > > > Hello, > > If you have a connection (e.g. myCon) then you can use it's Exec > function to execute mysql commands (e.g. myCon.Exec("CREATE VIEW....")). > If your command is a query then returns the result r (called resultset > in VB, I think), e.g. r=myCon.Exec("SELECT * FROM ...") > > Robi > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ____ ? ????????? ???????. From zachsmith022 at ...626... Mon Feb 6 06:44:25 2012 From: zachsmith022 at ...626... (Zach Smith) Date: Sun, 5 Feb 2012 23:44:25 -0600 Subject: [Gambas-user] gb.GeneralDate formatting is inconsistent In-Reply-To: <4F2E390E.1070408@...1...> References: <4F2E326C.8040201@...1...> <4F2E390E.1070408@...1...> Message-ID: > gb.GeneralDate prints the date part the short way (dd/mm/yy) and prints > the time if it is not zero. The middle example is still inconsistent if one expects 00:00:00 to be a valid time, that is, midnight (12:00 AM). Also note that the format is mm/dd/yy only if the time is not 00:00:00. One can get around this by using a "mm/dd/yyyy hh:nn:ss" format string but having gb.GeneralDate work for all dates and times would be helpful. --------------------------------------------------- Dim d1 As Date, d2 As Date, d3 As Date d1 = CDate("12/31/2002 23:59:59") d2 = CDate("1/1/2003 00:00:00") d3 = CDate("1/1/2003 00:00:01") Print Format(d1, gb.GeneralDate) Print Format(d2, gb.GeneralDate) Print Format(d3, gb.GeneralDate) --------------------------------------------------- 12/31/2002 23:59:59 01/01/03 01/01/2003 00:00:01 From abbat.81 at ...787... Mon Feb 6 09:14:34 2012 From: abbat.81 at ...787... (abbat) Date: Mon, 6 Feb 2012 00:14:34 -0800 (PST) Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <1328487232.9055.103.camel@...2688...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> Message-ID: <33269884.post@...1379...> I have MODmain.module with connection: ' Gambas module file Public $Con As New Connection ' Public Procedure Connect() Try $Con.Close() ' Close the connection $Con.Type = "MySQL" ' Type of connection $Con.Host = "192.168.1.100" ' Name of the server $Con.Login = "user" ' User's name for the connection ' $Con.Port = "3306" ' Port to use in the connection, usually 3306 $Con.Name = "bd" ' Name of the database we want to use $Con.Password = "123" ' User's password $Con.Open() ' Open the connection End And I have success request in FMain: MODMain.$Con.Exec("SELECT PointsLeft FROM base WHERE TimeCode ='" & T & "'") So, it works as it worked on BV.NET, but next request from VB.NET I cant make to work in Gambas: Dim COMMAND = New MySqlCommand("INSERT INTO statistic (" & "TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES ('" & T & "', now(), now(),'" & kluch & "','" & Nc & "')") I tried next: MODMain.$Con.Exec("INSERT INTO statistic (" & "TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES ('" & T & "', now(), now(),'" & kluch & "','" & Nc & "')") but it not work GMail-79 wrote: > > On Sun, 2012-02-05 at 15:45 -0800, abbat wrote: > >> I cant make to work the command for MySQL which works perfect on VB.NET >> >> Dim COMMAND = New MySqlCommand("INSERT INTO statistic (" & >> "TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES ('" >> & >> T & "', now(), now(),'" & kluch & "','" & Nc & "')") >> >> How to make it work? >> Thanks >> > > What does your MySqlCommand class look like? > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- View this message in context: http://old.nabble.com/How-To-INSERT-INTO-in-MySQL--tp33268576p33269884.html Sent from the gambas-user mailing list archive at Nabble.com. From demosthenesk at ...626... Mon Feb 6 09:16:01 2012 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Mon, 06 Feb 2012 10:16:01 +0200 Subject: [Gambas-user] checkconfig errors Message-ID: <4F2F8C41.1020306@...626...> hi to all, i downloaded the latest svn and i see that the checkconfig fails when try to install examples. i get ------------------------------------------- Making install in examples make[1]: Entering directory `/home/user/Downloads/Gambas/gambas3-svn4454/examples' make[2]: Entering directory `/home/user/Downloads/Gambas/gambas3-svn4454/examples' Installing the gambas examples... rm: fts_read failed: No such file or directory make[2]: *** [install-exec-local] Error 1 make[2]: Leaving directory `/home/user/Downloads/Gambas/gambas3-svn4454/examples' make[1]: *** [install-am] Error 2 make[1]: Leaving directory `/home/user/Downloads/Gambas/gambas3-svn4454/examples' make: *** [install-recursive] Error 1 **** Installation failed. Aborting package creation. Cleaning up...OK Bye. ------------------------------------------- why i get rm: fts_read failed: No such file or directory this is not a compilation problem but a checkconfig install problem i also tried to install other versions of checkconfig and i get the same errors. Is there something in examples that checkconfig cannot handle? From Gambas at ...1950... Mon Feb 6 09:21:00 2012 From: Gambas at ...1950... (Caveat) Date: Mon, 06 Feb 2012 09:21:00 +0100 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <33269884.post@...1379...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> Message-ID: <1328516460.23889.44.camel@...2150...> On Mon, 2012-02-06 at 00:14 -0800, abbat wrote: > > but it not work Can you at least tell us the error message you got? Why do we have to try to GUESS why it's not working? From Gambas at ...1950... Mon Feb 6 09:46:29 2012 From: Gambas at ...1950... (Caveat) Date: Mon, 06 Feb 2012 09:46:29 +0100 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <1328516460.23889.44.camel@...2150...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> Message-ID: <1328517989.23889.48.camel@...2150...> Here's some working code... conn = DataAccess.getConnection() conn.Exec("delete from UTI001 where CLEF = &1", "Caveat") conn.Exec("insert into UTI001 (CLEF, Langue, Backup) VALUES (&1, &2, &3)", "Caveat", "EN", "C:\\Temp") rSet = conn.Exec("select * from UTI001 where CLEF = &1", "Caveat") If rSet Not Null Then If rSet.Count > 0 Then rSet.MoveFirst Print rSet["CLEF"], rSet["Langue"] Endif Endif As expected, it prints: Caveat EN Regards, Caveat On Mon, 2012-02-06 at 09:21 +0100, Caveat wrote: > On Mon, 2012-02-06 at 00:14 -0800, abbat wrote: > > > > but it not work > > > > Can you at least tell us the error message you got? Why do we have to > try to GUESS why it's not working? > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From adamnt42 at ...626... Mon Feb 6 09:53:33 2012 From: adamnt42 at ...626... (GMail) Date: Mon, 06 Feb 2012 19:23:33 +1030 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <1328516460.23889.44.camel@...2150...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> Message-ID: <1328518413.9055.109.camel@...2688...> On Mon, 2012-02-06 at 09:21 +0100, Caveat wrote: > On Mon, 2012-02-06 at 00:14 -0800, abbat wrote: > > > > but it not work > > > > Can you at least tell us the error message you got? Why do we have to > try to GUESS why it's not working? > Yes. At the very least PRINT the Exec string you are trying to create, before you try to "MODMain.$Con.Exec" it! It is very hard to guess. We don't even know the structure of the database table you are trying to insert into. From bespalov.av at ...626... Mon Feb 6 09:53:52 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Mon, 6 Feb 2012 14:53:52 +0600 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <1328516460.23889.44.camel@...2150...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> Message-ID: Try this: sql = "INSERT INTO statistic (TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES (&1,&2,&3,&4,&5)" MODMain.$Con.Subst(sql, T, Now(), Now(), kluch, Nc) MODMain.$Con.Exec(sql) 2012/2/6 Caveat > On Mon, 2012-02-06 at 00:14 -0800, abbat wrote: > > > > but it not work > > > > Can you at least tell us the error message you got? Why do we have to > try to GUESS why it's not working? > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ____ ? ????????? ???????. From abbat.81 at ...787... Mon Feb 6 11:40:24 2012 From: abbat.81 at ...787... (abbat) Date: Mon, 6 Feb 2012 02:40:24 -0800 (PST) Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <1328517989.23889.48.camel@...2150...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> <1328517989.23889.48.camel@...2150...> Message-ID: <33270528.post@...1379...> http://old.nabble.com/file/p33270528/2012-02-06-123728_1440x900_scrot.png Caveat wrote: > > Here's some working code... > > conn = DataAccess.getConnection() > conn.Exec("delete from UTI001 where CLEF = &1", "Caveat") > conn.Exec("insert into UTI001 (CLEF, Langue, Backup) VALUES (&1, &2, > &3)", "Caveat", "EN", "C:\\Temp") > rSet = conn.Exec("select * from UTI001 where CLEF = &1", "Caveat") > If rSet Not Null Then > If rSet.Count > 0 Then > rSet.MoveFirst > Print rSet["CLEF"], rSet["Langue"] > Endif > Endif > > As expected, it prints: > > Caveat EN > > Regards, > Caveat > > On Mon, 2012-02-06 at 09:21 +0100, Caveat wrote: >> On Mon, 2012-02-06 at 00:14 -0800, abbat wrote: >> > >> > but it not work >> >> >> >> Can you at least tell us the error message you got? Why do we have to >> try to GUESS why it's not working? >> >> >> ------------------------------------------------------------------------------ >> Try before you buy = See our experts in action! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-dev2 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > http://old.nabble.com/file/p33270528/2012-02-06-123728_1440x900_scrot.png -- View this message in context: http://old.nabble.com/How-To-INSERT-INTO-in-MySQL--tp33268576p33270528.html Sent from the gambas-user mailing list archive at Nabble.com. From bespalov.av at ...626... Mon Feb 6 11:51:51 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Mon, 6 Feb 2012 16:51:51 +0600 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <33270528.post@...1379...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> <1328517989.23889.48.camel@...2150...> <33270528.post@...1379...> Message-ID: The string not finished! Gambas do not cut string. Print in one string. Gambas ?? ???? ????????? ?????? ??? VB. ???? ??? ? ???? ??????. 2012/2/6 abbat > > > http://old.nabble.com/file/p33270528/2012-02-06-123728_1440x900_scrot.png > > > Caveat wrote: > > > > Here's some working code... > > > > conn = DataAccess.getConnection() > > conn.Exec("delete from UTI001 where CLEF = &1", "Caveat") > > conn.Exec("insert into UTI001 (CLEF, Langue, Backup) VALUES (&1, &2, > > &3)", "Caveat", "EN", "C:\\Temp") > > rSet = conn.Exec("select * from UTI001 where CLEF = &1", "Caveat") > > If rSet Not Null Then > > If rSet.Count > 0 Then > > rSet.MoveFirst > > Print rSet["CLEF"], rSet["Langue"] > > Endif > > Endif > > > > As expected, it prints: > > > > Caveat EN > > > > Regards, > > Caveat > > > > On Mon, 2012-02-06 at 09:21 +0100, Caveat wrote: > >> On Mon, 2012-02-06 at 00:14 -0800, abbat wrote: > >> > > >> > but it not work > >> > >> > >> > >> Can you at least tell us the error message you got? Why do we have to > >> try to GUESS why it's not working? > >> > >> > >> > ------------------------------------------------------------------------------ > >> Try before you buy = See our experts in action! > >> The most comprehensive online learning library for Microsoft developers > >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > >> Metro Style Apps, more. Free future releases when you subscribe now! > >> http://p.sf.net/sfu/learndevnow-dev2 > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > > > ------------------------------------------------------------------------------ > > Try before you buy = See our experts in action! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-dev2 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > http://old.nabble.com/file/p33270528/2012-02-06-123728_1440x900_scrot.png > -- > View this message in context: > http://old.nabble.com/How-To-INSERT-INTO-in-MySQL--tp33268576p33270528.html > Sent from the gambas-user mailing list archive at Nabble.com. > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ____ ? ????????? ???????. From francois at ...2770... Mon Feb 6 11:37:06 2012 From: francois at ...2770... (Francois Saidi) Date: Mon, 06 Feb 2012 11:37:06 +0100 Subject: [Gambas-user] gb.xml.rpc sending an array from client to server Message-ID: <4F2FAD52.8060804@...2770...> Hi, I am new to this mailling list, and a beginner in Gambas programming. I am facing a problem i couldn't solve by myself and i would appreciate some help of you guys. I am using the xml.rpc component, and i would like to send an array (of Date) to the server. I have the following code ################################ DIM vVar AS NEW Variant[] DIM bOk AS Boolean DIM array AS NEW Date[] array .Add(Now()) fRpc = NEW RpcFunction("calendar.setplanning", [XmlRpc.xArray], XmlRpc.xBoolean) vVar.Add(array) TRY bOk = cRpc.Call(vVar) ##################################### By doing this i have an error when doing the Call. The error says "type mismatch wanted float got a string...." Is this the right way to send a array? Is it possible? Thanks for your help Hplus From Gambas at ...1950... Mon Feb 6 12:12:46 2012 From: Gambas at ...1950... (Caveat) Date: Mon, 06 Feb 2012 12:12:46 +0100 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <33270528.post@...1379...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> <1328517989.23889.48.camel@...2150...> <33270528.post@...1379...> Message-ID: <1328526766.23889.49.camel@...2150...> >> conn.Exec("insert into UTI001 (CLEF, Langue, Backup) VALUES (&1, &2, >> &3)", "Caveat", "EN", "C:\\Temp") This has to be ONE LINE! On Mon, 2012-02-06 at 02:40 -0800, abbat wrote: > > http://old.nabble.com/file/p33270528/2012-02-06-123728_1440x900_scrot.png > > > Caveat wrote: > > > > Here's some working code... > > > > conn = DataAccess.getConnection() > > conn.Exec("delete from UTI001 where CLEF = &1", "Caveat") > > conn.Exec("insert into UTI001 (CLEF, Langue, Backup) VALUES (&1, &2, > > &3)", "Caveat", "EN", "C:\\Temp") > > rSet = conn.Exec("select * from UTI001 where CLEF = &1", "Caveat") > > If rSet Not Null Then > > If rSet.Count > 0 Then > > rSet.MoveFirst > > Print rSet["CLEF"], rSet["Langue"] > > Endif > > Endif > > > > As expected, it prints: > > > > Caveat EN > > > > Regards, > > Caveat > > > > On Mon, 2012-02-06 at 09:21 +0100, Caveat wrote: > >> On Mon, 2012-02-06 at 00:14 -0800, abbat wrote: > >> > > >> > but it not work > >> > >> > >> > >> Can you at least tell us the error message you got? Why do we have to > >> try to GUESS why it's not working? > >> > >> > >> ------------------------------------------------------------------------------ > >> Try before you buy = See our experts in action! > >> The most comprehensive online learning library for Microsoft developers > >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > >> Metro Style Apps, more. Free future releases when you subscribe now! > >> http://p.sf.net/sfu/learndevnow-dev2 > >> _______________________________________________ > >> Gambas-user mailing list > >> Gambas-user at lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > > ------------------------------------------------------------------------------ > > Try before you buy = See our experts in action! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-dev2 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > http://old.nabble.com/file/p33270528/2012-02-06-123728_1440x900_scrot.png From eilert-sprachen at ...221... Mon Feb 6 12:37:46 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Mon, 06 Feb 2012 12:37:46 +0100 Subject: [Gambas-user] Naming/Renaming projects Message-ID: <4F2FBB8A.1070508@...221...> This is just minor IDE thing, but it confuses me each time I want to start a new project. Guess this hasn't changed in Gambas3, correct me if I'm wrong, I just can't check on this machine here at the moment. In the dialog that asks for the project title and name, the explanations for the two input fields don't make the purposes of the input texts quite clear to me: Which one is for the directory, and which one means the "internal" title for the project? I do see a distinction here necessary, the directory name may be a brief of the project title for instance. Or I want a directory name without spaces ("new20") but a title that says "My new project 2.0". But each time I start, I'm unsure what to type where, so I tend to type the same thing (directory name) into both fields. The second point is, when I want to open an existing project, I'm asked for the directory, right? But the dialog is a file-opening one, so if you don't know, you get confused here: Do I have to point to a concrete file, or is it ok to point to a directory only? Then there is a third thing which in turn has to do with my first issue: I wanted to rename a project, making a new directory for it (i. e. making a copy but also a new name). As I'm not sure what happens when I change the name of the project from within the IDE (Save As asks for a directory AND filename... so what do I need to give? Both? Only a directory name? And what happens to the project title then?) I simply made a copy and renamed it by hand. Loading this new one I was surprised to find the new directory name in the IDE title - not the old project title string. This made me think: What do I have to give a project title for if it isn't used anyway :-) So shouldn't these dialogs be thought over in terms of user friendliness, what do you think? Rolf From gambas.fr at ...626... Mon Feb 6 13:38:27 2012 From: gambas.fr at ...626... (Fabien Bodard) Date: Mon, 6 Feb 2012 13:38:27 +0100 Subject: [Gambas-user] gb.xml.rpc sending an array from client to server In-Reply-To: <4F2FAD52.8060804@...2770...> References: <4F2FAD52.8060804@...2770...> Message-ID: 2012/2/6 Francois Saidi : > Hi, > > I am new to this mailling list, and a beginner in Gambas programming. > I am facing a problem i couldn't solve by ?myself and i would appreciate > some help of you guys. > I am using the xml.rpc component, and i would like to send an array (of > Date) ?to the server. > I have the following code > ################################ > DIM vVar AS NEW Variant[] > DIM bOk AS Boolean > DIM array AS NEW Date[] > > array .Add(Now()) > > fRpc = NEW RpcFunction("calendar.setplanning", [XmlRpc.xArray], > XmlRpc.xBoolean) > > vVar.Add(array) > TRY bOk = cRpc.Call(vVar) > > ##################################### > > By doing this i have an error ?when doing the Call. The error says "type > mismatch wanted float got a string...." > > Is this the right way to send a array? Is it possible? > > Thanks for your help > > Hplus > > > > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -- Fabien Bodard first don't give array as a name for a variable ... it's a class ! From gambas.fr at ...626... Mon Feb 6 13:41:51 2012 From: gambas.fr at ...626... (Fabien Bodard) Date: Mon, 6 Feb 2012 13:41:51 +0100 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <1328526766.23889.49.camel@...2150...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> <1328517989.23889.48.camel@...2150...> <33270528.post@...1379...> <1328526766.23889.49.camel@...2150...> Message-ID: sql = "INSERT INTO statistic (TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES (&1,&2,&3,&4,&5)" MODMain.$Con.Subst(sql, T, Now(), Now(), kluch, Nc) MODMain.$Con.Exec(sql) ???? i prefer like that : MODMain.$Con.Exec("INSERT INTO statistic (TimeCode, SessionStart, SessionEnd, Kluch, Comp) VALUES (&1,&2,&3,&4,&5)",T, Now(), Now(), kluch, Nc) From francois at ...2770... Mon Feb 6 13:59:26 2012 From: francois at ...2770... (Francois Saidi) Date: Mon, 06 Feb 2012 13:59:26 +0100 Subject: [Gambas-user] gb.xml.rpc sending an array from client to server In-Reply-To: References: <4F2FAD52.8060804@...2770...> Message-ID: <4F2FCEAE.5080303@...2770...> ok, this was not actually the real code, i've just typed this as an example. Hplus Le 06/02/2012 13:38, Fabien Bodard a ?crit : > 2012/2/6 Francois Saidi: >> Hi, >> >> I am new to this mailling list, and a beginner in Gambas programming. >> I am facing a problem i couldn't solve by myself and i would appreciate >> some help of you guys. >> I am using the xml.rpc component, and i would like to send an array (of >> Date) to the server. >> I have the following code >> ################################ >> DIM vVar AS NEW Variant[] >> DIM bOk AS Boolean >> DIM array AS NEW Date[] >> >> array .Add(Now()) >> >> fRpc = NEW RpcFunction("calendar.setplanning", [XmlRpc.xArray], >> XmlRpc.xBoolean) >> >> vVar.Add(array) >> TRY bOk = cRpc.Call(vVar) >> >> ##################################### >> >> By doing this i have an error when doing the Call. The error says "type >> mismatch wanted float got a string...." >> >> Is this the right way to send a array? Is it possible? >> >> Thanks for your help >> >> Hplus >> >> >> >> >> >> >> ------------------------------------------------------------------------------ >> Try before you buy = See our experts in action! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-dev2 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > From willy at ...2734... Mon Feb 6 14:06:15 2012 From: willy at ...2734... (Willy Raets) Date: Mon, 06 Feb 2012 14:06:15 +0100 Subject: [Gambas-user] Freeze mouse input for a second Message-ID: <1328533575.2409.10.camel@...2735...> Hi All, I've made a small game called Memory for my kids in Gambas 2.22. You click one picture and make it visible, click the other and make it visible, when matching pictures, disable both pictures, when not matching make invisible again after 1 sec. This all works perfectly (at least for me). When the kids test it they click one picture and the other, then the wait of 1 sec shows them both pictures for a second. So far so good. But what do kids do, they click another picture before the WAIT 1.0 is finished and the application suddenly has 3 pictures turned instead of two. And this is where trouble starts :-) My question: Is there a way in Gambas to freeze the mouse input? So when two pictures are selected and WAIT 1.0 is run, I would like evry click on the mouse to be ignored for that short period. That would solve the whole issue. Been looking in documentation and google for quite a while now, but no answer found so far. Hope one of you has an answer. Thanks, Willy From willy at ...2734... Mon Feb 6 14:40:24 2012 From: willy at ...2734... (Willy Raets) Date: Mon, 06 Feb 2012 14:40:24 +0100 Subject: [Gambas-user] TAB on keyboard Message-ID: <1328535624.2409.36.camel@...2735...> Hi All, When making forms I determine hierarchy of the controls on the form for navigating the form with TAB-key during runtime. This to make the forms more user friendly. Simple example: --------------- Application with 1 form with 3 ValueBoxes. ValBox1 and ValBox2 for input ValBox3 for output (lets say sum of ValboX1 and ValBox2) ValBox3 is read only ValBox1 has focus on opening form Button1 for close Hierarchy on form is ValBox1, ValBox2, Button1, ValBox3. Running application then fill in ValBox1. Hit TAB-key brings you to ValBox2, fill in and ValBox3 gets calculated. Hit Tab-key brings you to Button1 So far so good. Now hitting Tab-key brings you to ValBox3. (no input field but a read only), I would like it to go back to ValBox1 and skip the read only controls. In VB I could determine if a control was effected by use of TAB-key or not by a property on the control. ----------------- I'm running into this on all my input forms in all my applications (Gambas2) and it is bothering me. Been looking for a solution for some time but haven't found any. Is there a way in Gambas2 (or Gambas3), when using TAB-key on keyboard to have it skip (in my case all read only) controls and just go to those that matter for input? Thanks, Willy From mohareve at ...626... Mon Feb 6 15:18:12 2012 From: mohareve at ...626... (M. Cs.) Date: Mon, 6 Feb 2012 15:18:12 +0100 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> <1328517989.23889.48.camel@...2150...> <33270528.post@...1379...> <1328526766.23889.49.camel@...2150...> Message-ID: And I agree with Fabien!!!! I just over with the transcription of former wrongly formatted query style -> query="INSERT INTO....." MyConn.Exec(query) Don't use that style! You will make only troubles with escaping characters. The right way is MyConn.Exec("INSERT Into ... VALUES(&1,&2...);",myvar1,myvar2,...) 2012/2/6, Fabien Bodard : > sql = "INSERT INTO statistic (TimeCode, SessionStart, SessionEnd, Kluch, > Comp) VALUES (&1,&2,&3,&4,&5)" > MODMain.$Con.Subst(sql, T, Now(), Now(), kluch, Nc) > MODMain.$Con.Exec(sql) > > > ???? > > i prefer like that : > > MODMain.$Con.Exec("INSERT INTO statistic (TimeCode, SessionStart, > SessionEnd, Kluch, Comp) VALUES (&1,&2,&3,&4,&5)",T, Now(), Now(), > kluch, Nc) > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From tobiasboe1 at ...20... Mon Feb 6 15:28:23 2012 From: tobiasboe1 at ...20... (tobias) Date: Mon, 06 Feb 2012 15:28:23 +0100 Subject: [Gambas-user] Freeze mouse input for a second In-Reply-To: <1328533575.2409.10.camel@...2735...> References: <1328533575.2409.10.camel@...2735...> Message-ID: <4F2FE387.1060508@...20...> hi, > Hi All, > > I've made a small game called Memory for my kids in Gambas 2.22. > > You click one picture and make it visible, click the other and make it > visible, when matching pictures, disable both pictures, when not > matching make invisible again after 1 sec. > > This all works perfectly (at least for me). When the kids test it they > click one picture and the other, then the wait of 1 sec shows them both > pictures for a second. So far so good. > > But what do kids do, they click another picture before the WAIT 1.0 is > finished and the application suddenly has 3 pictures turned instead of > two. And this is where trouble starts :-) > > My question: Is there a way in Gambas to freeze the mouse input? > So when two pictures are selected and WAIT 1.0 is run, I would like evry > click on the mouse to be ignored for that short period. That would solve > the whole issue. > > Been looking in documentation and google for quite a while now, but no > answer found so far. Hope one of you has an answer. > > Thanks, > > Willy > > well, i remember that it was possible to INC Application.Busy to disable actions on the form (or something) but i would tend to use the SLEEP instruction just as you use WAIT. WAIT according to the docs reenters the event loop and since you do not want events to be acknowledged but "freeze" the program SLEEP may match the need exactly. regards, tobi From nando_f at ...951... Mon Feb 6 15:36:29 2012 From: nando_f at ...951... (nando) Date: Mon, 6 Feb 2012 09:36:29 -0500 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <4F2E323F.9010101@...1887...> References: <4F2E323F.9010101@...1887...> Message-ID: <20120206143548.M42264@...951...> I am doing the same thing. Using class in place of structures. Then arrays or collections of the classes. Works great! ---------- Original Message ----------- From: Kevin Fishburne To: gambas-user at lists.sourceforge.net Sent: Sun, 05 Feb 2012 02:39:43 -0500 Subject: [Gambas-user] gb3: converting structures to classes > I tried to find the previous email suggesting this and couldn't, neither > is there an equivalent wiki article describing class creation as there > is with structure creation, so I'm asking here. > > I need to know how to convert structure declarations to class > declarations, and if there are any obvious syntactical differences in > declaration, assignment as properties to other classes, or assigning > actual data. I'm using structures like this: > > Public Struct Client_Animation > Animating As Boolean > OrientationDefault As Single > OrientationBegin As Single > OrientationEnd As Single > OrientationCurrent As Single > OrientationVelocity As Single > PositionDefaultX As Single > PositionDefaultY As Single > PositionBeginX As Single > PositionBeginY As Single > PositionEndX As Single > PositionEndY As Single > PositionCurrentX As Single > PositionCurrentY As Single > PositionVelocityX As Single > PositionVelocityY As Single > End Struct > > Public Struct Client_Gear > Orientation As Single > Scale As Single > SizeCap As Short > SizeStem As Short > Skin As Short > Type As Short > Animation As Struct Client_Animation > End Struct > > The logic behind the change is wanting these (numerous) structure > declarations to be contained within their own module for organizational > purposes and to be accessible between modules. It was suggested in > previous emails that this was possible using classes instead of > structures. Thanks everyone. > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From nando_f at ...951... Mon Feb 6 15:37:10 2012 From: nando_f at ...951... (nando) Date: Mon, 6 Feb 2012 09:37:10 -0500 Subject: [Gambas-user] Send from .module to .class In-Reply-To: <33264477.post@...1379...> References: <33264477.post@...1379...> Message-ID: <20120206143641.M83516@...951...> MFmain.Label1.text = "test_string" ---------- Original Message ----------- From: abbat To: gambas-user at lists.sourceforge.net Sent: Sat, 4 Feb 2012 15:01:59 -0800 (PST) Subject: [Gambas-user] Send from .module to .class > How can I send a string "test_string" from > Main.module > to > Label1 which situated on > MFmain.class > > Thanks > > -- > View this message in context: http://old.nabble.com/Send-from-.module-to-.class-tp33264477p33264477.html > Sent from the gambas-user mailing list archive at Nabble.com. > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From ron at ...1740... Mon Feb 6 15:42:15 2012 From: ron at ...1740... (Ron) Date: Mon, 06 Feb 2012 15:42:15 +0100 Subject: [Gambas-user] Send from .module to .class In-Reply-To: <20120206143641.M83516@...951...> References: <33264477.post@...1379...> <20120206143641.M83516@...951...> Message-ID: <4F2FE6C7.3080102@...1740...> But you have to tweak your project options to allow this. Regards, Ron_2nd. > MFmain.Label1.text = "test_string" > > > ---------- Original Message ----------- > From: abbat > To: gambas-user at lists.sourceforge.net > Sent: Sat, 4 Feb 2012 15:01:59 -0800 (PST) > Subject: [Gambas-user] Send from .module to .class > >> How can I send a string "test_string" from >> Main.module >> to >> Label1 which situated on >> MFmain.class >> >> Thanks >> >> -- >> View this message in context: > http://old.nabble.com/Send-from-.module-to-.class-tp33264477p33264477.html >> Sent from the gambas-user mailing list archive at Nabble.com. >> >> ------------------------------------------------------------------------------ >> Try before you buy = See our experts in action! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-dev2 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From jussi.lahtinen at ...626... Mon Feb 6 17:00:23 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Mon, 6 Feb 2012 18:00:23 +0200 Subject: [Gambas-user] Missing symbols Message-ID: One of these days... maybe I have missed something, but any clue why Gambas programs cannot find some symbols from libc? Specifically I'm talking about fmod, my libraries (written with C) can find this without problem. And even more strange, Gambas programs can find some symbols from libc. Library "libc:6" Private Extern modf(param As Float, pp As Pointer) As Float Private Extern fmod(param1 As Float, param2 As Float) As Float Public Sub Main() Dim pp As Pointer = Alloc(SizeOf(gb.Float)) Print modf(Pi, pp) Print fmod(Pi, 2) '<-- only this raises "cannot find symbol..." End Demonstration project attached. Jussi -------------- next part -------------- A non-text attachment was scrubbed... Name: MissingSymbol-0.0.1.tar.gz Type: application/x-gzip Size: 4559 bytes Desc: not available URL: From francois at ...2770... Mon Feb 6 17:57:32 2012 From: francois at ...2770... (Francois Saidi) Date: Mon, 06 Feb 2012 17:57:32 +0100 Subject: [Gambas-user] gb.xml.rpc sending an array from client to server In-Reply-To: References: <4F2FAD52.8060804@...2770...> Message-ID: <4F30067C.3030806@...2770...> Ok, I've checked the sources of the component and figured out my problem I have to create an RpcArray with my Date[] first before putting it into the Variant[]... Hplus Le 06/02/2012 13:38, Fabien Bodard a ?crit : > 2012/2/6 Francois Saidi: >> Hi, >> >> I am new to this mailling list, and a beginner in Gambas programming. >> I am facing a problem i couldn't solve by myself and i would appreciate >> some help of you guys. >> I am using the xml.rpc component, and i would like to send an array (of >> Date) to the server. >> I have the following code >> ################################ >> DIM vVar AS NEW Variant[] >> DIM bOk AS Boolean >> DIM array AS NEW Date[] >> >> array .Add(Now()) >> >> fRpc = NEW RpcFunction("calendar.setplanning", [XmlRpc.xArray], >> XmlRpc.xBoolean) >> >> vVar.Add(array) >> TRY bOk = cRpc.Call(vVar) >> >> ##################################### >> >> By doing this i have an error when doing the Call. The error says "type >> mismatch wanted float got a string...." >> >> Is this the right way to send a array? Is it possible? >> >> Thanks for your help >> >> Hplus >> >> >> >> >> >> >> ------------------------------------------------------------------------------ >> Try before you buy = See our experts in action! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-dev2 >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > From gambas at ...1... Mon Feb 6 18:24:19 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 06 Feb 2012 18:24:19 +0100 Subject: [Gambas-user] dirs and files structure of a Gambas project In-Reply-To: References: Message-ID: <4F300CC3.5070307@...1...> Le 03/02/2012 18:11, Fabi?n Flores Vadell a ?crit : > Hi. > > Exists any spec for the structure of directories and files (and its > meaning) of a Gambas project? > > What I want is to know all conditions that the compiler and interpreter > expect, in order to call them from the command line. > > I need to know too any information about config files or data from them, > needed for the IDE but not for the compiler neither interpreter. > > Thanks. Does it help you? http://gambasdoc.org/help/doc/project_structure?v3 -- Beno?t Minisini From emil.lenngren at ...626... Mon Feb 6 18:30:53 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Mon, 6 Feb 2012 18:30:53 +0100 Subject: [Gambas-user] Freeze mouse input for a second In-Reply-To: <4F2FE387.1060508@...20...> References: <1328533575.2409.10.camel@...2735...> <4F2FE387.1060508@...20...> Message-ID: When I did a similar game, I had some boolean variable called locked or something. In the mouse receiver event handlers, I first check if the boolean variable is set or not. If it is set, I return immediately, if not, I continue as normal. You should be able to do that as well. I should not use sleep, as that freezes the whole application. For example it does not redraw the window if it has to. /Emil 2012/2/6 tobias > hi, > > > Hi All, > > > > I've made a small game called Memory for my kids in Gambas 2.22. > > > > You click one picture and make it visible, click the other and make it > > visible, when matching pictures, disable both pictures, when not > > matching make invisible again after 1 sec. > > > > This all works perfectly (at least for me). When the kids test it they > > click one picture and the other, then the wait of 1 sec shows them both > > pictures for a second. So far so good. > > > > But what do kids do, they click another picture before the WAIT 1.0 is > > finished and the application suddenly has 3 pictures turned instead of > > two. And this is where trouble starts :-) > > > > My question: Is there a way in Gambas to freeze the mouse input? > > So when two pictures are selected and WAIT 1.0 is run, I would like evry > > click on the mouse to be ignored for that short period. That would solve > > the whole issue. > > > > Been looking in documentation and google for quite a while now, but no > > answer found so far. Hope one of you has an answer. > > > > Thanks, > > > > Willy > > > > > > well, i remember that it was possible to > INC Application.Busy > to disable actions on the form (or something) but i would tend to use > the SLEEP instruction just as you use WAIT. WAIT according to the docs > reenters the event loop and since you do not want events to be > acknowledged but "freeze" the program SLEEP may match the need exactly. > > regards, > tobi > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From john.aaron.rose at ...626... Mon Feb 6 19:04:17 2012 From: john.aaron.rose at ...626... (John Rose) Date: Mon, 06 Feb 2012 18:04:17 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1328551457.4661.3.camel@...2661...> I thought I'd found the solution (when I looked at the documentation again), namely to use the Update & Refresh methods on the controls as per the code below: FMain.ValueBoxLatitude.Value = MDatabase.ResultSite!latitude FMain.DataSourceCountry.Connection = MDatabase.DatabaseConnection FMain.DataSourceCountry.Table = "country" FCountryMaintenance.DataSourceCountry.Update() FCountryMaintenance.DataSourceCountry.Refresh() FMain.DataBrowserCountry.Columns = ["country"] FCountryMaintenance.DataBrowserCountry.Update() FCountryMaintenance.DataBrowserCountry.Refresh() However, that didn't work. Has anyone got the DataSource & DataBrowser controls working in conjunction with each other? If so, I'd be grateful if you could post some details with its associated project attached. From ea7dfh at ...2382... Mon Feb 6 20:27:12 2012 From: ea7dfh at ...2382... (Jesus) Date: Mon, 06 Feb 2012 20:27:12 +0100 Subject: [Gambas-user] Naming/Renaming projects In-Reply-To: <4F2FBB8A.1070508@...221...> References: <4F2FBB8A.1070508@...221...> Message-ID: <4F302990.3030004@...2382...> El 06/02/12 12:37, Rolf-Werner Eilert escribi?: > This is just minor IDE thing, but it confuses me each time I want to > start a new project. Guess this hasn't changed in Gambas3, correct me if > I'm wrong, I just can't check on this machine here at the moment. > > In the dialog that asks for the project title and name, the explanations > for the two input fields don't make the purposes of the input texts > quite clear to me: Which one is for the directory, and which one means > the "internal" title for the project? > > I do see a distinction here necessary, the directory name may be a brief > of the project title for instance. Or I want a directory name without > spaces ("new20") but a title that says "My new project 2.0". But each > time I start, I'm unsure what to type where, so I tend to type the same > thing (directory name) into both fields. > > The second point is, when I want to open an existing project, I'm asked > for the directory, right? But the dialog is a file-opening one, so if > you don't know, you get confused here: Do I have to point to a concrete > file, or is it ok to point to a directory only? > > Then there is a third thing which in turn has to do with my first issue: > I wanted to rename a project, making a new directory for it (i. e. > making a copy but also a new name). As I'm not sure what happens when I > change the name of the project from within the IDE (Save As asks for a > directory AND filename... so what do I need to give? Both? Only a > directory name? And what happens to the project title then?) I simply > made a copy and renamed it by hand. > > Loading this new one I was surprised to find the new directory name in > the IDE title - not the old project title string. This made me think: > What do I have to give a project title for if it isn't used anyway :-) > > So shouldn't these dialogs be thought over in terms of user > friendliness, what do you think? > > Rolf +1 I totally agree -- Jesus Guardon From ea7dfh at ...2382... Mon Feb 6 20:38:10 2012 From: ea7dfh at ...2382... (Jesus) Date: Mon, 06 Feb 2012 20:38:10 +0100 Subject: [Gambas-user] Send from .module to .class In-Reply-To: <33264477.post@...1379...> References: <33264477.post@...1379...> Message-ID: <4F302C22.3040006@...2382...> El 05/02/12 00:01, abbat escribi?: > > How can I send a string "test_string" from > Main.module > to > Label1 which situated on > MFmain.class > > Thanks > > Use "properties" or setter and getter public functions. Not a good idea making form controls public. Regards -- Jesus Guardon From gambas at ...1... Mon Feb 6 20:47:14 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 06 Feb 2012 20:47:14 +0100 Subject: [Gambas-user] DataSource & DataBrowser problem In-Reply-To: <1328298713.3990.19.camel@...2661...> References: <1328298713.3990.19.camel@...2661...> Message-ID: <4F302E42.8090908@...1...> Le 03/02/2012 20:51, John Rose a ?crit : > I've looked at the Database example and I still don't understand how to > use the DataSource& DataBrowser controls. > > My DataSourceCountry control has its Table property set to country (one > of the tables in the Test.db SQLite3 database in the Data directory of > the attached Test project. In the Form_Open procedure, the variable > DatabaseConnection was previously created successfully (i.e. before I > added these 2 controls) and database opened OK. In that procedure, the > Connection property of DataSourceCountry is set to this variable: should > I do that? My DataBrowserCountry control has Columns set to country > (which is one of the columns in the country table, though not the > primary key) and Editable set to True. The project compiles& saves OK. > > When I try to run it, a popup comes up either with 'Null object' or > 'Driver name missing'. Any ideas please. > If the DataSource Connection property is not set, then DataSource will use the default connection object, which is usually the first one created. In your code, this is the "Private DatabaseConnection As New Connection", which is not initialized. So the 'Driver name missing' error, because DataSource tries to open that connection object during form instanciation, before Form_Open is called. Another point: DataSource is a container. Every other control that depends on it must be put *inside* it. Regards, -- Beno?t Minisini From gambas at ...1... Mon Feb 6 20:53:19 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 06 Feb 2012 20:53:19 +0100 Subject: [Gambas-user] Last in group event handler called as function In-Reply-To: <4F2C3FE0.8040402@...20...> References: <4F2C3FE0.8040402@...20...> Message-ID: <4F302FAF.8010002@...1...> Le 03/02/2012 21:13, tobias a ?crit : > hi, > > consider the following (where "PickColor" is the event name of a group > of ToogleButton controls) > > Public Sub Form_Open() > PickColor_Click() > End > > Public Sub PickColor_Click() > Print Last > End > > since the event handlers are just subroutines one may call them as every > other sub. i can imagine that Last is set properly for a single event > raising object to avoid errors when the event handler uses Last but is > not a risen event (i haven't looked at any event handler dispatcher code > of the interpreter or something, so i don't know where Last is set). but > what's about an event group? which object will Last be in this > situation? in my code (which is, of course, a bit more complex) i always > get the same ToggleButton printed but i can't spot any reason. > > regards, > tobi > 'Last' is the object that raised the event, whatever its "event group" is. If you call the event handler directly, 'Last' will be Null, or maybe the value of another control if you call it from another event handler called regularly. Regards, -- Beno?t Minisini From gambas at ...1... Mon Feb 6 20:53:58 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 06 Feb 2012 20:53:58 +0100 Subject: [Gambas-user] Help for Image and Picture Colors In-Reply-To: <4F2C79A1.3010706@...20...> References: <4F2C7801.3060907@...20...> <4F2C79A1.3010706@...20...> Message-ID: <4F302FD6.7010405@...1...> Le 04/02/2012 01:19, tobias a ?crit : > On 04.02.2012 01:12, tobias wrote: >> Hi, >> >> I really need help. There's a lot of work with colors in Images and >> Pictures in a project and between these classes. This is generally >> speaking as follows: I have a class which has an 8*8px Image which is >> manipulated (due to the easy of accessing pixels directly). Using a >> property of my class, I provide access to a scaled version of the Image >> as a Picture (which is created when requested). So I do some things and >> when manually resizing the Image to get the prototype of the Picture to >> return (it is needed as bigger version of the Image without >> anti-aliasing, I don't get this result with Image.Stretch(), and doing >> it manually is not a problem) there seem to appear problems with >> transparency. I read that Pictures do not have an alpha channel and I >> noticed that colors from the ColorChooser or Color class are given with >> alpha channel set to 0x00 which will be transparent for the Image >> class... so I tried adding&Hff000000& to whatever color is assigned to >> any pixel in the 8*8px Image or not to do it and some other experiments >> but nothing worked on the entire project. there's always something >> transparent or black or whatever. I really go nuts with this. Anyone to >> my rescue? >> >> Regards, >> Tobi > > wait a minute. I forgot to say that I don't even need the transparency > feature of the Image class. I only use Image - as I said - because of > Image[x, y] pixel access. For the meantime - or as a final solution? > there may be a lot of those accesses and I thought using Image[x, y] > will be the most efficient way to go - I switch to using an 8*8px > Picture and Draw.Pixel() instead but I would really appreciate anyone > clarify this topic to me. > I understand nothing. Maybe because I'm a little sick, but if you can be clearer... -- Beno?t Minisini From gambas at ...1... Mon Feb 6 20:58:05 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 06 Feb 2012 20:58:05 +0100 Subject: [Gambas-user] Editor Control (gb.qt4.ext) - Some questions. In-Reply-To: <1328410556.3199.59.camel@...2506...> References: <4F2C8454.40800@...169...> <20120204045658.M57246@...951...> <4F2CCD31.9020706@...169...> <1328410556.3199.59.camel@...2506...> Message-ID: <4F3030CD.3010402@...1...> Le 05/02/2012 03:55, Ian Roper a ?crit : > In the Editor control from gb.qt4.ext > > # Context > When reviewing text read from a file in an Editor Control. > > > > # Highlighting > When MyEditorControl.Highlight attribute is set to 'Normal', the > 'end-of-line' ( gb.crlf ) character is displayed as a musical note > symbol ? gb.CrLf is not the end of line. It is gb.Lf only. Maybe the musical note is the gb.Cr character at the end of the line? > I have tried various fonts but the symbol is the same for each font. > If you use another highlight value ( Gambas, SQL...) then the symbol is > NOT displayed. > > Q: Is there any way to disable this symbol displaying in 'Normal' mode ? > > # Select All > When you call the editor function to MyEditorControl.SelectAll in code, > it selects all the text lines but dose not highlight the code. > All the text is selected and you can copy to clipboard and paste as > required. > If you do this manually by using the mouse - this works ok - all text is > highlighted. > If you use the shortcut keys Ctrl-A - this works ok- all text is > highlighted. > > Q: Is there a parameter I can set to highlight all the text when > 'MyEditorControl.SelectAll' is actioned ? Mmm. Strange, as normally SelectAll() method and hitting CTRL+A should call exactly the same code internally. I will check... Can you send me an example of whay you do exactly? > > # Wordwrap > There is no parameter I can set to 'word-wrap' text if there is no > embedded 'end-of-line' character. > > Q: Is it possible to add this functionality as a standard control > parameter ? Not at the moment. It is very complex to implement it in the Editor control. > > > # LineNumbering > > The MyEditorControl.ShowLineNumbers functionality for Editor controls > cannot be accessed ( Read Only) > In the context Help is says: "Set this flag to display line numbers" but > it is read-only. > > Q: How can you set this flag ? > Q: Is it possible to be able to set this to True/False to show line > numbers in the control ? It works like that: MyEditor.Flags[Editor.ShowLineNumbers] = True A bit weird - I admit I should have used real boolean properties! Regards, -- Beno?t Minisini From tobiasboe1 at ...20... Mon Feb 6 21:19:20 2012 From: tobiasboe1 at ...20... (tobias) Date: Mon, 06 Feb 2012 21:19:20 +0100 Subject: [Gambas-user] Help for Image and Picture Colors In-Reply-To: <4F302FD6.7010405@...1...> References: <4F2C7801.3060907@...20...> <4F2C79A1.3010706@...20...> <4F302FD6.7010405@...1...> Message-ID: <4F3035C8.5000004@...20...> hi, Beno?t Minisini wrote: > Le 04/02/2012 01:19, tobias a ?crit : >> On 04.02.2012 01:12, tobias wrote: >>> Hi, >>> >>> I really need help. There's a lot of work with colors in Images and >>> Pictures in a project and between these classes. This is generally >>> speaking as follows: I have a class which has an 8*8px Image which is >>> manipulated (due to the easy of accessing pixels directly). Using a >>> property of my class, I provide access to a scaled version of the Image >>> as a Picture (which is created when requested). So I do some things and >>> when manually resizing the Image to get the prototype of the Picture to >>> return (it is needed as bigger version of the Image without >>> anti-aliasing, I don't get this result with Image.Stretch(), and doing >>> it manually is not a problem) there seem to appear problems with >>> transparency. I read that Pictures do not have an alpha channel and I >>> noticed that colors from the ColorChooser or Color class are given with >>> alpha channel set to 0x00 which will be transparent for the Image >>> class... so I tried adding&Hff000000& to whatever color is assigned to >>> any pixel in the 8*8px Image or not to do it and some other experiments >>> but nothing worked on the entire project. there's always something >>> transparent or black or whatever. I really go nuts with this. Anyone to >>> my rescue? >>> >>> Regards, >>> Tobi >> wait a minute. I forgot to say that I don't even need the transparency >> feature of the Image class. I only use Image - as I said - because of >> Image[x, y] pixel access. For the meantime - or as a final solution? >> there may be a lot of those accesses and I thought using Image[x, y] >> will be the most efficient way to go - I switch to using an 8*8px >> Picture and Draw.Pixel() instead but I would really appreciate anyone >> clarify this topic to me. >> > > I understand nothing. Maybe because I'm a little sick, but if you can be > clearer... > it's a messy explanation, i just recalled too... the situation is as follows: i have a class that takes care of designing a picture for me according to user input. because of the ease of accessing pixels with the image class i took an image behind the scenes but it has to be converted to a picture for display in a PictureBox at the front end. moreover it has to be resized which i do manually and is no big deal for my format. i used to import pictures and images into the class, etc. which overall introduces as big back and forth of image <-> picture conversion, resizing, etc. the problem first came up when i incorporated palettes created by another program and stored in binary files. i noticed that these were in ARGB format with the A component set to 0x00 all the time (colors came from a ColorChooser, later i noticed that the constants in the Color class do likewise). while this works (color is displayed) when drawing it to a picture, it doesn't when writing it to an image pixel. i tried conversion functions and everything that came in my mind. at the end i rewrote the class to use pictures. those pictures are created with the Transparent = False instanciation parameter. from those i can derive Picture.Image on which i operate to speed things up. this is sort of solved and the program works fine now. i seem to repress the memory of what i tried (pathetic programmer's brain :) ) but i can tell that nothing worked on the entire project (which was certainly a fault due to my quick fixes or project infrastructure) but to clarify things: it resulted in transparency in all kinds of places in the whole program originally introduced by reading colors from standard components that had their alpha channel zeroed which according to the docs signaled the image class that this color is fully transparent. i hope it didn't get as complicated but recalling the situation pointed me to the fact that actually i do not know why it is working now (seems to rely on the Transparent = False picture instanciation?)... regards, tobi From zachsmith022 at ...626... Mon Feb 6 21:36:45 2012 From: zachsmith022 at ...626... (Zach Smith) Date: Mon, 06 Feb 2012 14:36:45 -0600 Subject: [Gambas-user] gb.GeneralDate formatting is inconsistent In-Reply-To: References: <4F2E326C.8040201@...1...> <4F2E390E.1070408@...1...> Message-ID: <4F3039DD.4010309@...626...> On 2/5/2012 11:44 PM, Zach Smith wrote: > only if the time is not 00:00:00 Correction - "only if the time *is* 00:00:00" From ron at ...1740... Mon Feb 6 21:59:14 2012 From: ron at ...1740... (Ron) Date: Mon, 6 Feb 2012 21:59:14 +0100 Subject: [Gambas-user] Send from .module to .class In-Reply-To: <4F302C22.3040006@...2382...> References: <33264477.post@...1379...> <4F302C22.3040006@...2382...> Message-ID: I agree, but the supplied example doesn't work with making controls public. 2012/2/6 Jesus > El 05/02/12 00:01, abbat escribi?: > > > > How can I send a string "test_string" from > > Main.module > > to > > Label1 which situated on > > MFmain.class > > > > Thanks > > > > > > Use "properties" or setter and getter public functions. Not a good idea > making form controls public. > > Regards > > -- > Jesus Guardon > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From math.eber at ...221... Mon Feb 6 22:47:37 2012 From: math.eber at ...221... (Matti) Date: Mon, 06 Feb 2012 22:47:37 +0100 Subject: [Gambas-user] Naming/Renaming projects In-Reply-To: <4F2FBB8A.1070508@...221...> References: <4F2FBB8A.1070508@...221...> Message-ID: <4F304A79.5010408@...221...> Hi Rolf, to your 1st point: in gb3 there is a wizard, asking first for the directory (and you can create a new one), then asking for the name and the title of the project. This should be ok, don't you think so? 2nd point: (also gb3) In the opening dialog you can see clearly if it is a folder or a gambas project. Just look at the icons. Matti Am 06.02.2012 12:37, schrieb Rolf-Werner Eilert: > This is just minor IDE thing, but it confuses me each time I want to > start a new project. Guess this hasn't changed in Gambas3, correct me if > I'm wrong, I just can't check on this machine here at the moment. > > In the dialog that asks for the project title and name, the explanations > for the two input fields don't make the purposes of the input texts > quite clear to me: Which one is for the directory, and which one means > the "internal" title for the project? > > I do see a distinction here necessary, the directory name may be a brief > of the project title for instance. Or I want a directory name without > spaces ("new20") but a title that says "My new project 2.0". But each > time I start, I'm unsure what to type where, so I tend to type the same > thing (directory name) into both fields. > > The second point is, when I want to open an existing project, I'm asked > for the directory, right? But the dialog is a file-opening one, so if > you don't know, you get confused here: Do I have to point to a concrete > file, or is it ok to point to a directory only? > > Then there is a third thing which in turn has to do with my first issue: > I wanted to rename a project, making a new directory for it (i. e. > making a copy but also a new name). As I'm not sure what happens when I > change the name of the project from within the IDE (Save As asks for a > directory AND filename... so what do I need to give? Both? Only a > directory name? And what happens to the project title then?) I simply > made a copy and renamed it by hand. > > Loading this new one I was surprised to find the new directory name in > the IDE title - not the old project title string. This made me think: > What do I have to give a project title for if it isn't used anyway :-) > > So shouldn't these dialogs be thought over in terms of user > friendliness, what do you think? > > Rolf From gambas at ...2524... Mon Feb 6 23:13:56 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Mon, 06 Feb 2012 22:13:56 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <1-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <1-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <2-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Updates: Status: Started Comment #2 on issue 123 by benoit.m... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 If libraries do not automatically load their dependencies (like components), do you think it will solve the problem? From willy at ...2734... Mon Feb 6 23:18:01 2012 From: willy at ...2734... (Willy Raets) Date: Mon, 06 Feb 2012 23:18:01 +0100 Subject: [Gambas-user] Freeze mouse input for a second In-Reply-To: References: <1328533575.2409.10.camel@...2735...> <4F2FE387.1060508@...20...> Message-ID: <1328566681.2396.10.camel@...2735...> Hi Emil, You were right on the SLEEP not doing the job. SLEEP freezes the event from being executed. But as soon as sleep time is finished the event raised during sleep time gets executed anyway. But the solution with working with booleans seems fair enough :-) I'll have a go at that.. Thanks, Willy On ma, 2012-02-06 at 18:30 +0100, Emil Lenngren wrote: > When I did a similar game, I had some boolean variable called locked or > something. In the mouse receiver event handlers, I first check if the > boolean variable is set or not. If it is set, I return immediately, if not, > I continue as normal. > You should be able to do that as well. > > I should not use sleep, as that freezes the whole application. For example > it does not redraw the window if it has to. > > /Emil > > 2012/2/6 tobias > > > hi, > > > > > Hi All, > > > > > > I've made a small game called Memory for my kids in Gambas 2.22. > > > > > > You click one picture and make it visible, click the other and make it > > > visible, when matching pictures, disable both pictures, when not > > > matching make invisible again after 1 sec. > > > > > > This all works perfectly (at least for me). When the kids test it they > > > click one picture and the other, then the wait of 1 sec shows them both > > > pictures for a second. So far so good. > > > > > > But what do kids do, they click another picture before the WAIT 1.0 is > > > finished and the application suddenly has 3 pictures turned instead of > > > two. And this is where trouble starts :-) > > > > > > My question: Is there a way in Gambas to freeze the mouse input? > > > So when two pictures are selected and WAIT 1.0 is run, I would like evry > > > click on the mouse to be ignored for that short period. That would solve > > > the whole issue. > > > > > > Been looking in documentation and google for quite a while now, but no > > > answer found so far. Hope one of you has an answer. > > > > > > Thanks, > > > > > > Willy > > > > > > > > > > well, i remember that it was possible to > > INC Application.Busy > > to disable actions on the form (or something) but i would tend to use > > the SLEEP instruction just as you use WAIT. WAIT according to the docs > > reenters the event loop and since you do not want events to be > > acknowledged but "freeze" the program SLEEP may match the need exactly. > > > > regards, > > tobi > > > > > > ------------------------------------------------------------------------------ > > Try before you buy = See our experts in action! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-dev2 > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -- Met vriendelijke groeten/ With kind regards, Willy Raets, Voorzitter/chairman, Earthship Belgium vzw. Nederlandse website: http://www.earthshipbelgium.be/nl.html English Website: http://www.earthshipbelgium.be/en.html From gambas at ...2524... Tue Feb 7 01:24:24 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 07 Feb 2012 00:24:24 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <2-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <2-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <3-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Comment #3 on issue 123 by adamn... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 I'm not sure on whether that would help as I'm not clear on how both component and library loads work regarding dependencies. I'll try explaining what I do understand and what I'd expect to see if that makes anything clearer. By way of an example, I have three projects that I want to share with other projects: phApplication3 - This is a moderately stable project that provides some basic startup automation for any project(settings, application login, database connecticty etc). I currently only want to install it as a local gambas library until I get around to fixing a little used option in it. It has internal dependencies on gb.settings, gb.db and gb.gui (and gb.form and gb.image). The project contains a single exported class and three forms that are used internally. The three forms in it are very simple and quite desktop agnostic. I have the Component Properties/Requires set with no features and the above 5 components. Lets say that he primary task of this project is to check whether the client project has a settings file and if so create database connections according to those settings. If the client project has no settings file for the user then it shows a form to allow the user to create the settings. When this library is used in another project I expect that it takes care of its own needs in terms of the required components. In fact what happens is this, I create a commandline project and add phApplication3 as a library. In the Main() I call phApplication.Init which is the public method in the exposed class that does all that initialisation stuff. When I run this it fails with a signal 11. I then add gb.db as a component and now the program works correctly. Note that I have not added any gui component to this client project. Now things get a bit messy. First I add gb.qt4 as a component to the client project. It now fails with a signal 6 error. So I change it to use gb.gui. Now it works. Finally, I change it to use gb.gtk (the default desktop here in LXDE) and it still works. So in summary, with this library in a client project it appears to load some of the dependencies (the gui components used in the library and gb.settings) but not others (gb.db). In addition, if the client project gui component choice conflicts with the library gui component, the client project fails. phDB9a - This is a complex project that essentially decouples the client application "business object" classes (BOC's) from their persitence mechanism. In short, it exports one class which is used as the parent class for all BOCs. The exported class provides Load, Save, Add and Delete methods that take care of all the database access for the BOC object. It has one feature of interest, it makes the application BOC object perform like a gb.db Result object, i.e. it can be iterated and accessed as an array. At the moment this library is only implemented for Postgresql, Sqlite, text and XML "back ends" (MySQL is just too buggy!) so I don't make it as a component. This library depends on the settings and connection management provided by phApplication3. Thus the library required components are phApplication3 and gb.db (as loading phApplication3 does not load gb.db as seen above!). This library also has some extensive internal testing code that uses forms. (This is where issue 123 came to be.) Most importantly, none of that test code is exported nor used by any of the stuff accessed by a client project that uses this library. The test code has to be in the library so we can debug it and step through it when necessary. So currently we have to maintain two versions of phDB9a to avoid the gui conflicts (and there is my pain.) phControls3 - This is a set of enhanced gui control classes that mainly tries to work around the gtk/qt4 inconsistences and adds some of my "great ideas" that make gui development easier :-) such as self labelling and event consistency. This is a stable library and I have implemented it as a local gambas component, albeit with some problems with the automake template mentioned in another issue. The only dependency I think I need to include is gb.desktop (as the gui library is taken care of by the client project). This all appears to work and I do not need to add gb.desktop as a client project component. So it seems that the component loads it's declared dependency automatically? From gambas at ...2524... Tue Feb 7 01:28:26 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 07 Feb 2012 00:28:26 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <3-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <3-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <4-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Comment #4 on issue 123 by adamn... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 Oh! By the way, thanks for revisiting this issue. From gambas at ...2524... Tue Feb 7 01:32:29 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 07 Feb 2012 00:32:29 +0000 Subject: [Gambas-user] Issue 103 in gambas: Treeview KeyRelease behaves differently with gtk and qt4 In-Reply-To: <2-6813199134517018827-4136136202187000509-gambas=googlecode.com@...2524...> References: <2-6813199134517018827-4136136202187000509-gambas=googlecode.com@...2524...> <0-6813199134517018827-4136136202187000509-gambas=googlecode.com@...2524...> Message-ID: <3-6813199134517018827-4136136202187000509-gambas=googlecode.com@...2524...> Comment #3 on issue 103 by adamn... at ...626...: Treeview KeyRelease behaves differently with gtk and qt4 http://code.google.com/p/gambas/issues/detail?id=103 I think the gtk method is correct. I will look at whether this has been discussed anywhere on the QT4 internet. From ivanwms64 at ...43... Tue Feb 7 02:36:07 2012 From: ivanwms64 at ...43... (Ivan Williams) Date: Mon, 6 Feb 2012 17:36:07 -0800 (PST) Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> <1328517989.23889.48.camel@...2150...> <33270528.post@...1379...> <1328526766.23889.49.camel@...2150...> Message-ID: <1328578567.58579.YahooMailNeo@...2772...> I build a array of inserts? - first item in the array is "begin transaction" ??????????? i19 = i19 + 1 ??????????? sql = "Insert into disks " ??????????? sql = sql & "( diskno,dirno, nof,disknum, dirnum) " ??????????? sql = sql & "Values ('" ??????????? sql = sql & i17 & "', '" & i3 & "', '" & i20 & "', '" & tmp19 & "', '" & tmp15 & "');" ??????????? rcnt = rcnt + 1 ??????????? qrs2[rcnt] = sql ' ' '??? lots of code omitted ' '???? I insert records in blocks of 10,000 to speed up insert rather than single inserts but feel free to insert one rec at atime if you wish ' ????? IF rcnt > 10000 THEN ??????????? rcnt = rcnt + 1 ??????????? qrs2[rcnt] = "commit;" ??????????? FOR i7 = 1 TO rcnt ??????????????? databaseconnection.Exec(qrs2[i7]) ??????????? NEXT ?????????? rcnt = 1 ?????????? qrs2[rcnt] = "begin transaction;" ???? ENDIF?????? ' ' ' This is how I do it.? Do some error checking to make sure your single quotes and special chars are taken care of - have fun.? ? ? Ivan ?? \~/ ? I never saw a wild thing sorry for itself. A small bird will drop frozen dead from a bough Without ever having felt sorry for itself. -- D.H. Lawrence http://www.usconstitution.net/const.html Linux - Live Free or Die. ________________________________ From: M. Cs. To: mailing list for gambas users Sent: Monday, February 6, 2012 9:18 AM Subject: Re: [Gambas-user] How To INSERT INTO in MySQL? And I agree with Fabien!!!! I just over with the transcription of former wrongly formatted query style -> query="INSERT INTO....." MyConn.Exec(query) Don't use that style! You will make only troubles with escaping characters. The right way is MyConn.Exec("INSERT Into ... VALUES(&1,&2...);",myvar1,myvar2,...) 2012/2/6, Fabien Bodard : > sql = "INSERT INTO statistic (TimeCode, SessionStart, SessionEnd, Kluch, > Comp) VALUES (&1,&2,&3,&4,&5)" > MODMain.$Con.Subst(sql, T, Now(), Now(), kluch, Nc) > MODMain.$Con.Exec(sql) > > > ???? > > i prefer like that : > > MODMain.$Con.Exec("INSERT INTO statistic (TimeCode, SessionStart, > SessionEnd, Kluch, Comp) VALUES (&1,&2,&3,&4,&5)",T, Now(), Now(), > kluch, Nc) > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > ------------------------------------------------------------------------------ Try before you buy = See our experts in action! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-dev2 _______________________________________________ Gambas-user mailing list Gambas-user at lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user From kevinfishburne at ...1887... Tue Feb 7 04:58:46 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Mon, 06 Feb 2012 22:58:46 -0500 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <20120206143548.M42264@...951...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> Message-ID: <4F30A176.3040405@...1887...> On 02/06/2012 09:36 AM, nando wrote: > I am doing the same thing. > Using class in place of structures. > Then arrays or collections of the classes. > Works great! > What are the general steps to do such a thing? How do you declare a class, define its properties, then create an array of the class? I'm starting to think it may be more complicated (or at least different) than with structures. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From nando_f at ...951... Tue Feb 7 05:35:19 2012 From: nando_f at ...951... (nando) Date: Mon, 6 Feb 2012 23:35:19 -0500 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <4F30A176.3040405@...1887...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> Message-ID: <20120207042516.M63100@...951...> Quite easy. Here's a suggestion/example Make a class called Tune... ...Dim a bunch of privates for values (name, artist, date, genre) ...Write SUBs for things to do with Tunes In FMain... PUBLIC Tunes AS Object[] In a SUB somewhere... Dim newTune as NEW Tune( possible constructor information if you want) Tunes.Add( newTune) --- As long as Tunes[] points to class instances of Tune, they remain existing. -Fernando ---------- Original Message ----------- From: Kevin Fishburne To: gambas-user at lists.sourceforge.net Sent: Mon, 06 Feb 2012 22:58:46 -0500 Subject: Re: [Gambas-user] gb3: converting structures to classes > On 02/06/2012 09:36 AM, nando wrote: > > I am doing the same thing. > > Using class in place of structures. > > Then arrays or collections of the classes. > > Works great! > > > > What are the general steps to do such a thing? How do you declare a > class, define its properties, then create an array of the class? I'm > starting to think it may be more complicated (or at least different) > than with structures. > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From abbat.81 at ...787... Tue Feb 7 09:23:53 2012 From: abbat.81 at ...787... (abbat) Date: Tue, 7 Feb 2012 00:23:53 -0800 (PST) Subject: [Gambas-user] Date to string MMddyyyyHHmmss Message-ID: <33277051.post@...1379...> How to get a Date without any sewparators, splash and dots? In VB.NET I can get it by: Dim T = Now.ToString("MMddyyyyHHmmss") I get "02062012192533" In "HOW TO" I could not find such exemple. Thanks -- View this message in context: http://old.nabble.com/Date-to-string-MMddyyyyHHmmss-tp33277051p33277051.html Sent from the gambas-user mailing list archive at Nabble.com. From abbat.81 at ...787... Tue Feb 7 09:24:37 2012 From: abbat.81 at ...787... (abbat) Date: Tue, 7 Feb 2012 00:24:37 -0800 (PST) Subject: [Gambas-user] Date to string MMddyyyyHHmmss Message-ID: <33277051.post@...1379...> How to get a Date without any separators, splash and dots? In VB.NET I can get it by: Dim T = Now.ToString("MMddyyyyHHmmss") I get "02062012192533" In "HOW TO" I could not find such exemple. Thanks -- View this message in context: http://old.nabble.com/Date-to-string-MMddyyyyHHmmss-tp33277051p33277051.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas.fr at ...626... Tue Feb 7 09:40:35 2012 From: gambas.fr at ...626... (Fabien Bodard) Date: Tue, 7 Feb 2012 09:40:35 +0100 Subject: [Gambas-user] How To INSERT INTO in MySQL? In-Reply-To: <1328578567.58579.YahooMailNeo@...2772...> References: <33268576.post@...1379...> <1328487232.9055.103.camel@...2688...> <33269884.post@...1379...> <1328516460.23889.44.camel@...2150...> <1328517989.23889.48.camel@...2150...> <33270528.post@...1379...> <1328526766.23889.49.camel@...2150...> <1328578567.58579.YahooMailNeo@...2772...> Message-ID: databaseconnection.Exec(qrs2[i7].join(" ")) normally.... it will be more speed than a for each From kevinfishburne at ...1887... Tue Feb 7 09:46:36 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Tue, 07 Feb 2012 03:46:36 -0500 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <20120207042516.M63100@...951...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> Message-ID: <4F30E4EC.4060901@...1887...> On 02/06/2012 11:35 PM, nando wrote: > Quite easy. > Here's a suggestion/example > > > > Make a class called Tune... > ...Dim a bunch of privates for values (name, artist, date, genre) > ...Write SUBs for things to do with Tunes > > > In FMain... > PUBLIC Tunes AS Object[] > > > > In a SUB somewhere... > Dim newTune as NEW Tune( possible constructor information if you want) > > Tunes.Add( newTune) > > --- > > As long as Tunes[] points to class instances of Tune, they remain existing. > > > -Fernando > > > > ---------- Original Message ----------- > From: Kevin Fishburne > To: gambas-user at lists.sourceforge.net > Sent: Mon, 06 Feb 2012 22:58:46 -0500 > Subject: Re: [Gambas-user] gb3: converting structures to classes > >> On 02/06/2012 09:36 AM, nando wrote: >>> I am doing the same thing. >>> Using class in place of structures. >>> Then arrays or collections of the classes. >>> Works great! >>> >> What are the general steps to do such a thing? How do you declare a >> class, define its properties, then create an array of the class? I'm >> starting to think it may be more complicated (or at least different) >> than with structures. >> Looks like a class is a structure with optional methods attached to procedures instead of just assignable properties. I'll play around with it and see if I can reproduce the structures as per your example. There should be a super simple project somewhere to show how classes work on a basic level. This is BASIC, so one can't presume people know what classes are. Thanks, classes look like they could be very useful. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From bespalov.av at ...626... Tue Feb 7 09:47:37 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Tue, 7 Feb 2012 14:47:37 +0600 Subject: [Gambas-user] Date to string MMddyyyyHHmmss In-Reply-To: <33277051.post@...1379...> References: <33277051.post@...1379...> Message-ID: very simple Dim d As Date Dim s As String d = Now Print d s = Str(d) Print s s = Replace(s, ".", "") s = Replace(s, ":", "") s = Replace(s, " ", "") Print s 2012/2/7 abbat > > How to get a Date without any separators, splash and dots? > > In VB.NET I can get it by: > Dim T = Now.ToString("MMddyyyyHHmmss") > > I get "02062012192533" > > In "HOW TO" I could not find such exemple. > > Thanks > -- > View this message in context: > http://old.nabble.com/Date-to-string-MMddyyyyHHmmss-tp33277051p33277051.html > Sent from the gambas-user mailing list archive at Nabble.com. > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ____ ? ????????? ???????. From eilert-sprachen at ...221... Tue Feb 7 10:33:14 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Tue, 07 Feb 2012 10:33:14 +0100 Subject: [Gambas-user] Naming/Renaming projects In-Reply-To: <4F304A79.5010408@...221...> References: <4F2FBB8A.1070508@...221...> <4F304A79.5010408@...221...> Message-ID: <4F30EFDA.5080103@...221...> Hi Matti, Am 06.02.2012 22:47, schrieb Matti: > Hi Rolf, > > to your 1st point: > in gb3 there is a wizard, asking first for the directory (and you can create a > new one), then asking for the name and the title of the project. > This should be ok, don't you think so? Well, you are right. The wizard asks for the Type of project (maybe the rest varies according to this choice?), then asks for the directory UNDER WHICH the project shall be stored - but it doesn't tell you that, you have to guess. Maybe this should be made somewhat clearer. Then I'm asked for a "name" and a "title". But what are these good for? Is name the name of the project directory, and title a free string stored within the project file (and what is it used for)? Or vice-versa? Or something else? Who knows... :-) Again, this could be made clearer, either by more self-explanatory titles for the input boxes or by some tooltip or a description at the side or whatever. > > 2nd point: > (also gb3) > In the opening dialog you can see clearly if it is a folder or a gambas project. > Just look at the icons. Errr - I didn't mean that small wizard popping up when you start Gambas. I mean the open dialog. Yes, it actually doesn't ask for a file, but it does provide a list of the files contained in the directories you click on, and you can click on the files, and then the project loads. So a beginner might be confused what to do or if it matters where the double-click went. Wouldn't it be enough to show the directories only? Or even better: the project titles as a default, and optionally the directory structure (for the geeks)? For my own part, I know where to click on, but I was thinking of beginners with Gambas and remembered how I was confused here when I started with it. Hope this makes it clearer... Rolf From bbruen at ...2308... Tue Feb 7 11:39:42 2012 From: bbruen at ...2308... (Bruce Bruen) Date: Tue, 07 Feb 2012 21:09:42 +1030 Subject: [Gambas-user] Date to string MMddyyyyHHmmss In-Reply-To: <33277051.post@...1379...> References: <33277051.post@...1379...> Message-ID: <1328611183.9055.126.camel@...2688...> On Tue, 2012-02-07 at 00:24 -0800, abbat wrote: > How to get a Date without any separators, splash and dots? > > In VB.NET I can get it by: > Dim T = Now.ToString("MMddyyyyHHmmss") > > I get "02062012192533" > > In "HOW TO" I could not find such exemple. > > Thanks abbat, The answers to many of you questions are in the gambas help files. You could perhaps avail yourself of these before posting such basic questions. The first thing I would suggest is to try and stop thinking in terms of VB.NET! Gambas is not VB.NET nor is it a clone of VB.NET, please try and think in gambas terms and not in VB.NET terms. I say this because a) we have all gone through the learning curve for gambas, again it's all in the help files, and b) some of us can get a bit upset by the constant reference to "this works in VB.NET, why not in gambas" questions. I will say one more thing, the gambas help files are very correct and they are also VERY SUCCINCT. In other words, you need to read every word on a help page and grasp its' meaning. For example, if I look up the Now keyword in the language index I see that it says that "dTime = Now [ ( ) ] AS Date" and it "Returns the current date and time." On that page there is also a link to the "Date & Time Functions". On that page I don't see anything that "obviously" solves your problem, BUT! at the end of the page is a link to "Intrinsic Functions" and behold, on that page is a link to "Format$" which by it's description ... "Format a number or a date." looks like exactly the the thing you are after. Please don't take this the wrong way. I just think you need to spend more time reading the help pages (as we all have done). cheers Bruce From rmorgan62 at ...626... Tue Feb 7 13:07:18 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Tue, 7 Feb 2012 04:07:18 -0800 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <4F30E4EC.4060901@...1887...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> Message-ID: Actually, a Structure is a methodless class. On Tue, Feb 7, 2012 at 12:46 AM, Kevin Fishburne < kevinfishburne at ...1887...> wrote: > On 02/06/2012 11:35 PM, nando wrote: > > Quite easy. > > Here's a suggestion/example > > > > > > > > Make a class called Tune... > > ...Dim a bunch of privates for values (name, artist, date, genre) > > ...Write SUBs for things to do with Tunes > > > > > > In FMain... > > PUBLIC Tunes AS Object[] > > > > > > > > In a SUB somewhere... > > Dim newTune as NEW Tune( possible constructor information if you want) > > > > Tunes.Add( newTune) > > > > --- > > > > As long as Tunes[] points to class instances of Tune, they remain > existing. > > > > > > -Fernando > > > > > > > > ---------- Original Message ----------- > > From: Kevin Fishburne > > To: gambas-user at lists.sourceforge.net > > Sent: Mon, 06 Feb 2012 22:58:46 -0500 > > Subject: Re: [Gambas-user] gb3: converting structures to classes > > > >> On 02/06/2012 09:36 AM, nando wrote: > >>> I am doing the same thing. > >>> Using class in place of structures. > >>> Then arrays or collections of the classes. > >>> Works great! > >>> > >> What are the general steps to do such a thing? How do you declare a > >> class, define its properties, then create an array of the class? I'm > >> starting to think it may be more complicated (or at least different) > >> than with structures. > >> > > Looks like a class is a structure with optional methods attached to > procedures instead of just assignable properties. I'll play around with > it and see if I can reproduce the structures as per your example. There > should be a super simple project somewhere to show how classes work on a > basic level. This is BASIC, so one can't presume people know what > classes are. Thanks, classes look like they could be very useful. > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From bbruen at ...2308... Tue Feb 7 14:05:22 2012 From: bbruen at ...2308... (Bruce Bruen) Date: Tue, 07 Feb 2012 23:35:22 +1030 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> Message-ID: <1328619922.9055.144.camel@...2688...> On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: > Actually, a Structure is a methodless class. ggggzzzzzrrpppppppp! ... and you can inherit from, override and make static attributes from a struct too? Please, lets keep things realistic here. From rmorgan62 at ...626... Tue Feb 7 14:07:56 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Tue, 7 Feb 2012 05:07:56 -0800 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <1328619922.9055.144.camel@...2688...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> Message-ID: Just restating the documentation.... On Tue, Feb 7, 2012 at 5:05 AM, Bruce Bruen wrote: > On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: > > Actually, a Structure is a methodless class. > ggggzzzzzrrpppppppp! > > ... and you can inherit from, override and make static attributes from a > struct too? > > Please, lets keep things realistic here. > > > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From rmorgan62 at ...626... Tue Feb 7 14:10:47 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Tue, 7 Feb 2012 05:10:47 -0800 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> Message-ID: http://gambasdoc.org/help/lang/structdecl?en&v3 "A structure is exactly like a class that would have only public variables." On Tue, Feb 7, 2012 at 5:07 AM, Randall Morgan wrote: > Just restating the documentation.... > > > On Tue, Feb 7, 2012 at 5:05 AM, Bruce Bruen wrote: > >> On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: >> > Actually, a Structure is a methodless class. >> ggggzzzzzrrpppppppp! >> >> ... and you can inherit from, override and make static attributes from a >> struct too? >> >> Please, lets keep things realistic here. >> >> >> >> >> >> ------------------------------------------------------------------------------ >> Keep Your Developer Skills Current with LearnDevNow! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-d2d >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > > -- > If you ask me if it can be done. The answer is YES, it can always be done. > The correct questions however are... What will it cost, and how long will > it take? > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From adamnt42 at ...626... Tue Feb 7 14:50:22 2012 From: adamnt42 at ...626... (GMail) Date: Wed, 08 Feb 2012 00:20:22 +1030 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> Message-ID: <1328622622.9055.169.camel@...2688...> On Tue, 2012-02-07 at 05:07 -0800, Randall Morgan wrote: > Just restating the documentation.... > > On Tue, Feb 7, 2012 at 5:05 AM, Bruce Bruen wrote: > > > On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: > > > Actually, a Structure is a methodless class. > > ggggzzzzzrrpppppppp! > > > > ... and you can inherit from, override and make static attributes from a > > struct too? > > > > Please, lets keep things realistic here No, I don't think "A structure is exactly like a class that would have only public variables" is the same thing as saying that a "Structure is a methodless class". In fact, I would almost go further and say that the help should say that a "structure is somewhat like a class, in that it exposes attributes publicly (and in an unprotected manner) but it neither contains nor exposes any functionality or feature typically associated with the generally understood concept of an OO classifier." A class can inherit from any other gambas class (with one notable exception - Form), it can have a constructor, destructor, initialisation and finalization code and other special methods, it can have both exposed (public or property based) data, it can contain specifically differential static data, classes can override the methods of their parent classes etc etc. I'm not having a go at you, its just that there is a bunch of mail lately that seems to imply that a class is just a "fancy" structure. In my opinion, it's quite different; a structure is just a "chunk of data", conversely a class is much much more than that. Comparing the two is like comparing penguins and pineapples. cheers Bruce From rmorgan62 at ...626... Tue Feb 7 16:06:29 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Tue, 7 Feb 2012 07:06:29 -0800 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <1328622622.9055.169.camel@...2688...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> <1328622622.9055.169.camel@...2688...> Message-ID: Well, it sounds like your issue is with the documentation rather than posters. I do recall someone a while back stating that in Gambas structures were implemented as method-less classes. In languages such as C/C++ etc.. structures are very different beasts compared to class. However, the documentation for gambas states, perhaps incorrectly, that they are nearly the same thing. So I guess what is needed is better documentation.... On Tue, Feb 7, 2012 at 5:50 AM, GMail wrote: > On Tue, 2012-02-07 at 05:07 -0800, Randall Morgan wrote: > > Just restating the documentation.... > > > > On Tue, Feb 7, 2012 at 5:05 AM, Bruce Bruen > wrote: > > > > > On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: > > > > Actually, a Structure is a methodless class. > > > ggggzzzzzrrpppppppp! > > > > > > ... and you can inherit from, override and make static attributes from > a > > > struct too? > > > > > > Please, lets keep things realistic here > > No, I don't think "A structure is exactly like a class that would have > only public variables" is the same thing as saying that a "Structure is > a methodless class". > > In fact, I would almost go further and say that the help should say that > a "structure is somewhat like a class, in that it exposes attributes > publicly (and in an unprotected manner) but it neither contains nor > exposes any functionality or feature typically associated with the > generally understood concept of an OO classifier." > > A class can inherit from any other gambas class (with one notable > exception - Form), it can have a constructor, destructor, initialisation > and finalization code and other special methods, it can have both > exposed (public or property based) data, it can contain specifically > differential static data, classes can override the methods of their > parent classes etc etc. > > I'm not having a go at you, its just that there is a bunch of mail > lately that seems to imply that a class is just a "fancy" structure. In > my opinion, it's quite different; a structure is just a "chunk of data", > conversely a class is much much more than that. Comparing the two is > like comparing penguins and pineapples. > > cheers > Bruce > > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From john.aaron.rose at ...626... Tue Feb 7 16:25:54 2012 From: john.aaron.rose at ...626... (John Rose) Date: Tue, 07 Feb 2012 15:25:54 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1328628354.4661.14.camel@...2661...> Thanks, Benoit, for your explanation. Now that I've deleted the DataBrowserCountry control & created it again inside the DataSourceCountry control, I now see the countries (i.e. France & Great Britain) in the DataBrowserCountry control. However, when I try to add a new country (e.g. Fz), it moves the cursor to a blank line following Great Britain and I key in Fz. When I click the save button (in the DataBrowserCountry control), it comes up with a dialog box saying 'Connection not opened' with OK button only (and clicking OK does not result in saving). This also happens if I try to change a country's name & save it. The DataBrowserCountry control has Editable set to true as shown in the code fragment from the FMain class which calls the FCountryMaintenance form: Public Sub ButtonCountryMaintenance_Click() Dim hForm As FCountryMaintenance hForm = New FCountryMaintenance hForm.DataSourceCountry.Connection = MDatabase.DatabaseConnection hForm.DataSourceCountry.Table = "country" hForm.DataSourceCountry.Update() hForm.Refresh() hForm.DataBrowserCountry.Columns = ["country"] hForm.DataBrowserCountry.Editable = True hForm.DataBrowserCountry.Update() hForm.DataBrowserCountry.Refresh() hForm.Show() hForm.DataBrowserCountry.SetFocus() Me.Hide() End PS I do not see a property named Labels for either control class in the documentation. When I run my app, I see 'country', i.e. the country table's column name, as the column label. From rolf.frogs at ...221... Tue Feb 7 16:38:55 2012 From: rolf.frogs at ...221... (Rolf Schmidt) Date: Tue, 7 Feb 2012 16:38:55 +0100 Subject: [Gambas-user] Start a form minized Message-ID: <201202071638.58789.rolf.frogs@...221...> Hi everybody out there is it possible to start a form minimized or invisible. I use a TrayIcon to terminate the program and program should stay in the background and wait for incoming calls. Then a second from will be shown with the connection data but the main form - which only has a close button - should not be shown. Any help? Thanks Rolf -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part. URL: From jussi.lahtinen at ...626... Tue Feb 7 18:56:46 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Tue, 7 Feb 2012 19:56:46 +0200 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> <1328622622.9055.169.camel@...2688...> Message-ID: While structures and classes are different thing generally, I have understand that structures are implemented to Gambas internally as class. And to answer Kevin's question. Create class named Client_Animation, and paste this inside of it: Public Animating As Boolean Public OrientationDefault As Single Public OrientationBegin As Single Public OrientationEnd As Single Public OrientationCurrent As Single Public OrientationVelocity As Single Public PositionDefaultX As Single Public PositionDefaultY As Single Public PositionBeginX As Single Public PositionBeginY As Single Public PositionEndX As Single Public PositionEndY As Single Public PositionCurrentX As Single Public PositionCurrentY As Single Public PositionVelocityX As Single Public PositionVelocityY As Single Then create class named Client_Gear, and paste this inside of it: Public Orientation As Single Public Scale As Single Public SizeCap As Short Public SizeStem As Short Public Skin As Short Public Type As Short Public Animation As New Client_Animation Or alternatively: Inherits Client_Animation Public Orientation As Single Public Scale As Single Public SizeCap As Short Public SizeStem As Short Public Skin As Short Public Type As Short Depends on what you want exactly to do... Jussi On Tue, Feb 7, 2012 at 17:06, Randall Morgan wrote: > Well, it sounds like your issue is with the documentation rather than > posters. > > I do recall someone a while back stating that in Gambas structures were > implemented as method-less classes. > > In languages such as C/C++ etc.. structures are very different beasts > compared to class. However, the documentation for gambas states, perhaps > incorrectly, that they are nearly the same thing. So I guess what is > needed is better documentation.... > > > > On Tue, Feb 7, 2012 at 5:50 AM, GMail wrote: > > > On Tue, 2012-02-07 at 05:07 -0800, Randall Morgan wrote: > > > Just restating the documentation.... > > > > > > On Tue, Feb 7, 2012 at 5:05 AM, Bruce Bruen > > wrote: > > > > > > > On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: > > > > > Actually, a Structure is a methodless class. > > > > ggggzzzzzrrpppppppp! > > > > > > > > ... and you can inherit from, override and make static attributes > from > > a > > > > struct too? > > > > > > > > Please, lets keep things realistic here > > > > No, I don't think "A structure is exactly like a class that would have > > only public variables" is the same thing as saying that a "Structure is > > a methodless class". > > > > In fact, I would almost go further and say that the help should say that > > a "structure is somewhat like a class, in that it exposes attributes > > publicly (and in an unprotected manner) but it neither contains nor > > exposes any functionality or feature typically associated with the > > generally understood concept of an OO classifier." > > > > A class can inherit from any other gambas class (with one notable > > exception - Form), it can have a constructor, destructor, initialisation > > and finalization code and other special methods, it can have both > > exposed (public or property based) data, it can contain specifically > > differential static data, classes can override the methods of their > > parent classes etc etc. > > > > I'm not having a go at you, its just that there is a bunch of mail > > lately that seems to imply that a class is just a "fancy" structure. In > > my opinion, it's quite different; a structure is just a "chunk of data", > > conversely a class is much much more than that. Comparing the two is > > like comparing penguins and pineapples. > > > > cheers > > Bruce > > > > > > > > > > > ------------------------------------------------------------------------------ > > Keep Your Developer Skills Current with LearnDevNow! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-d2d > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > -- > If you ask me if it can be done. The answer is YES, it can always be done. > The correct questions however are... What will it cost, and how long will > it take? > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From ea7dfh at ...2382... Tue Feb 7 19:31:30 2012 From: ea7dfh at ...2382... (Jesus) Date: Tue, 07 Feb 2012 19:31:30 +0100 Subject: [Gambas-user] Send from .module to .class In-Reply-To: References: <33264477.post@...1379...> <4F302C22.3040006@...2382...> Message-ID: <4F316E02.2090500@...2382...> El 06/02/12 21:59, Ron escribi?: > I agree, but the supplied example doesn't work with making controls public. Sorry Ron. I was sure someone suggested doing that. Regards -- Jesus Guardon > > 2012/2/6 Jesus > >> El 05/02/12 00:01, abbat escribi?: >>> >>> How can I send a string "test_string" from >>> Main.module >>> to >>> Label1 which situated on >>> MFmain.class >>> >>> Thanks >>> >>> >> >> Use "properties" or setter and getter public functions. Not a good idea >> making form controls public. >> >> Regards >> >> -- >> Jesus Guardon >> From gambas at ...1... Tue Feb 7 20:29:41 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Tue, 07 Feb 2012 20:29:41 +0100 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <1328622622.9055.169.camel@...2688...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> <1328622622.9055.169.camel@...2688...> Message-ID: <4F317BA5.6000904@...1...> Le 07/02/2012 14:50, GMail a ?crit : > On Tue, 2012-02-07 at 05:07 -0800, Randall Morgan wrote: >> Just restating the documentation.... >> >> On Tue, Feb 7, 2012 at 5:05 AM, Bruce Bruen wrote: >> >>> On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: >>>> Actually, a Structure is a methodless class. >>> ggggzzzzzrrpppppppp! >>> >>> ... and you can inherit from, override and make static attributes from a >>> struct too? >>> >>> Please, lets keep things realistic here > > No, I don't think "A structure is exactly like a class that would have > only public variables" is the same thing as saying that a "Structure is > a methodless class". > > In fact, I would almost go further and say that the help should say that > a "structure is somewhat like a class, in that it exposes attributes > publicly (and in an unprotected manner) but it neither contains nor > exposes any functionality or feature typically associated with the > generally understood concept of an OO classifier." > > A class can inherit from any other gambas class (with one notable > exception - Form), it can have a constructor, destructor, initialisation > and finalization code and other special methods, it can have both > exposed (public or property based) data, it can contain specifically > differential static data, classes can override the methods of their > parent classes etc etc. > > I'm not having a go at you, its just that there is a bunch of mail > lately that seems to imply that a class is just a "fancy" structure. In > my opinion, it's quite different; a structure is just a "chunk of data", > conversely a class is much much more than that. Comparing the two is > like comparing penguins and pineapples. > > cheers > Bruce > Gambas structures are really Gambas objects, except that they can be embedded inside other objects or structures (you cannot embed a Gambas object inside another one). Beside that special behaviour (and two other ones in extern function management and stream management), Gambas makes no difference between a structure object and a normal object. And I have never tested inheritance and structure... Maybe not a good idea. :-) Otherwise, to get the real details, you have to read the interpreter source code! :-) Regards, -- Beno?t Minisini From rmorgan62 at ...626... Tue Feb 7 20:32:56 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Tue, 7 Feb 2012 11:32:56 -0800 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <4F317BA5.6000904@...1...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> <1328622622.9055.169.camel@...2688...> <4F317BA5.6000904@...1...> Message-ID: Thanks for clearing that up Benoit! 2012/2/7 Beno?t Minisini > Le 07/02/2012 14:50, GMail a ?crit : > > On Tue, 2012-02-07 at 05:07 -0800, Randall Morgan wrote: > >> Just restating the documentation.... > >> > >> On Tue, Feb 7, 2012 at 5:05 AM, Bruce Bruen > wrote: > >> > >>> On Tue, 2012-02-07 at 04:07 -0800, Randall Morgan wrote: > >>>> Actually, a Structure is a methodless class. > >>> ggggzzzzzrrpppppppp! > >>> > >>> ... and you can inherit from, override and make static attributes from > a > >>> struct too? > >>> > >>> Please, lets keep things realistic here > > > > No, I don't think "A structure is exactly like a class that would have > > only public variables" is the same thing as saying that a "Structure is > > a methodless class". > > > > In fact, I would almost go further and say that the help should say that > > a "structure is somewhat like a class, in that it exposes attributes > > publicly (and in an unprotected manner) but it neither contains nor > > exposes any functionality or feature typically associated with the > > generally understood concept of an OO classifier." > > > > A class can inherit from any other gambas class (with one notable > > exception - Form), it can have a constructor, destructor, initialisation > > and finalization code and other special methods, it can have both > > exposed (public or property based) data, it can contain specifically > > differential static data, classes can override the methods of their > > parent classes etc etc. > > > > I'm not having a go at you, its just that there is a bunch of mail > > lately that seems to imply that a class is just a "fancy" structure. In > > my opinion, it's quite different; a structure is just a "chunk of data", > > conversely a class is much much more than that. Comparing the two is > > like comparing penguins and pineapples. > > > > cheers > > Bruce > > > > Gambas structures are really Gambas objects, except that they can be > embedded inside other objects or structures (you cannot embed a Gambas > object inside another one). > > Beside that special behaviour (and two other ones in extern function > management and stream management), Gambas makes no difference between a > structure object and a normal object. > > And I have never tested inheritance and structure... Maybe not a good > idea. :-) > > Otherwise, to get the real details, you have to read the interpreter > source code! :-) > > Regards, > > -- > Beno?t Minisini > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From kevinfishburne at ...1887... Tue Feb 7 22:02:30 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Tue, 07 Feb 2012 16:02:30 -0500 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> Message-ID: <4F319166.80907@...1887...> On 02/07/2012 08:10 AM, Randall Morgan wrote: > http://gambasdoc.org/help/lang/structdecl?en&v3 > > "A structure is exactly like a class that would have only public variables." > > > > On Tue, Feb 7, 2012 at 5:07 AM, Randall Morgan wrote: > >> Just restating the documentation.... >> >> >> As my dad would say, "I'll be double-dipped in dog manure." :) Thanks. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From rmorgan62 at ...626... Tue Feb 7 22:24:37 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Tue, 7 Feb 2012 13:24:37 -0800 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <4F319166.80907@...1887...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> <4F319166.80907@...1887...> Message-ID: LOL! My son in law is a rancher. A real cowboy (his tax return says so). And if you dropped the dog that sounds like something he'd say.... On Tue, Feb 7, 2012 at 1:02 PM, Kevin Fishburne < kevinfishburne at ...1887...> wrote: > On 02/07/2012 08:10 AM, Randall Morgan wrote: > > http://gambasdoc.org/help/lang/structdecl?en&v3 > > > > "A structure is exactly like a class that would have only public > variables." > > > > > > > > On Tue, Feb 7, 2012 at 5:07 AM, Randall Morgan > wrote: > > > >> Just restating the documentation.... > >> > >> > >> > > As my dad would say, "I'll be double-dipped in dog manure." :) Thanks. > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From mohareve at ...626... Tue Feb 7 23:28:12 2012 From: mohareve at ...626... (M. Cs.) Date: Tue, 7 Feb 2012 23:28:12 +0100 Subject: [Gambas-user] Start a form minized In-Reply-To: <201202071638.58789.rolf.frogs@...221...> References: <201202071638.58789.rolf.frogs@...221...> Message-ID: Try to add at the Public Sub Form_Open() Me.Minimized=True ..... End 2012/2/7, Rolf Schmidt : > Hi everybody out there > > is it possible to start a form minimized or invisible. > I use a TrayIcon to terminate the program and program should stay in the > background and wait for incoming calls. Then a second from will be shown > with > the connection data but the main form - which only has a close button - > should not be shown. > > Any help? > Thanks > Rolf > From fabianfloresvadell at ...626... Wed Feb 8 01:25:20 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Tue, 7 Feb 2012 21:25:20 -0300 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: <4F317BA5.6000904@...1...> References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> <1328622622.9055.169.camel@...2688...> <4F317BA5.6000904@...1...> Message-ID: Hi Beno?t. 2012/2/7 Beno?t Minisini > > >>> > Gambas structures are really Gambas objects, except that they can be > embedded inside other objects or structures (you cannot embed a Gambas > object inside another one). > Beside that special behaviour (and two other ones in extern function > management and stream management), Gambas makes no difference between a > structure object and a normal object. > Is the intention to provide a feature similar to inner classes of java? -- Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From wally at ...2037... Wed Feb 8 07:34:39 2012 From: wally at ...2037... (Wally) Date: Wed, 08 Feb 2012 07:34:39 +0100 Subject: [Gambas-user] gb.gsl documentation Message-ID: <3435706.uf7HjqgolG@...46...> Where cani find information, how to provide documentation on the gb.gsl component project. I would like to add this helper-popups to gb.gsl. ( see attachment please ) Where is a good place to upload some examples using the gb.gsl component ? wally -------------- next part -------------- A non-text attachment was scrubbed... Name: docPopUp.png Type: image/png Size: 32800 bytes Desc: not available URL: From wally at ...2037... Wed Feb 8 07:51:08 2012 From: wally at ...2037... (Wally) Date: Wed, 08 Feb 2012 07:51:08 +0100 Subject: [Gambas-user] gb.gsl documentation In-Reply-To: <3435706.uf7HjqgolG@...46...> References: <3435706.uf7HjqgolG@...46...> Message-ID: <2467507.hgD9uK2Abx@...46...> On Wednesday, February 08, 2012 07:34:39 Wally wrote: > Where cani find information, how to provide documentation on the gb.gsl > component project. I would like to add this helper-popups to gb.gsl. > ( see attachment please ) > Where is a good place to upload some examples using the gb.gsl component ? > > wally i guess i should use the documentation wiki and register first, right ? From gambas at ...1... Wed Feb 8 07:57:01 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Wed, 08 Feb 2012 07:57:01 +0100 Subject: [Gambas-user] gb3: converting structures to classes In-Reply-To: References: <4F2E323F.9010101@...1887...> <20120206143548.M42264@...951...> <4F30A176.3040405@...1887...> <20120207042516.M63100@...951...> <4F30E4EC.4060901@...1887...> <1328619922.9055.144.camel@...2688...> <1328622622.9055.169.camel@...2688...> <4F317BA5.6000904@...1...> Message-ID: <4F321CBD.3@...1...> Le 08/02/2012 01:25, Fabi?n Flores Vadell a ?crit : > > Is the intention to provide a feature similar to inner classes of java? > Not at all. -- Beno?t Minisini From gambas at ...2524... Wed Feb 8 10:36:08 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Wed, 08 Feb 2012 09:36:08 +0000 Subject: [Gambas-user] Issue 207 in gambas: Event Save get error at DataBrowser Message-ID: <0-6813199134517018827-3591540882422464748-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 207 by bespalov... at ...626...: Event Save get error at DataBrowser http://code.google.com/p/gambas/issues/detail?id=207 If i open table in DataBrowser and press Save, i get error box "Cannot modify record: SQL error or missing database". I can add or delete item at DataBrowser no problem. I think it try save to database empty line in DataBrowser. [System] OperatingSystem=Linux Kernel=3.2.3-2.fc16.i686 Architecture=i686 Memory=2061988 kB DistributionVendor=redhat DistributionRelease=RFRemix release 16 (Verne) Desktop=Gnome [Gambas 3] Version=3.0.0 Path=/usr/bin/gbx3 [Libraries] Qt4=libQtCore.so.4.8.0 GTK+=libgtk-x11-2.0.so.0.2400.8 From gambas at ...2524... Wed Feb 8 11:02:18 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Wed, 08 Feb 2012 10:02:18 +0000 Subject: [Gambas-user] Issue 208 in gambas: DataBrowser not have property "Grid" in property panel IDE. Message-ID: <0-6813199134517018827-17115019145429178783-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 208 by bespalov... at ...626...: DataBrowser not have property "Grid" in property panel IDE. http://code.google.com/p/gambas/issues/detail?id=208 DataBrowser not have property "Grid" (DataBrowser.View.Grid) in property panel IDE. It is often required. [System] OperatingSystem=Linux Kernel=3.2.3-2.fc16.i686 Architecture=i686 Memory=2061988 kB DistributionVendor=redhat DistributionRelease=RFRemix release 16 (Verne) Desktop=Gnome [Gambas 2] Version=2.23.1 Path=/usr/bin/gbx2 [Gambas 3] Version=3.0.0 Path=/usr/bin/gbx3 [Libraries] Qt4=libQtCore.so.4.8.0 GTK+=libgtk-x11-2.0.so.0.2400.8 From rolf.frogs at ...221... Wed Feb 8 13:18:32 2012 From: rolf.frogs at ...221... (Rolf Schmidt) Date: Wed, 8 Feb 2012 13:18:32 +0100 Subject: [Gambas-user] Start a form minized In-Reply-To: References: <201202071638.58789.rolf.frogs@...221...> Message-ID: <201202081318.35942.rolf.frogs@...221...> Hi M. Cs.: > Try to add at the > Public Sub Form_Open() > Me.Minimized=True > ..... > End Because this didn't work, I asked. Any other ideas? Thanks Rolf -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part. URL: From mohareve at ...626... Wed Feb 8 17:38:04 2012 From: mohareve at ...626... (M. Cs.) Date: Wed, 8 Feb 2012 17:38:04 +0100 Subject: [Gambas-user] Start a form minized In-Reply-To: <201202081318.35942.rolf.frogs@...221...> References: <201202071638.58789.rolf.frogs@...221...> <201202081318.35942.rolf.frogs@...221...> Message-ID: Just a trick: Add a Timer to FMain and set the Timer1 Enabled to true. Add the following procedure Public Sub Timer1_Timer() FMain.Minimized = True Timer1.Enabled = False End This will hide FMain 1 seconds after the start. Probably not the solution you are looking for... Csaba 2012/2/8, Rolf Schmidt : > Hi M. Cs.: > >> Try to add at the >> Public Sub Form_Open() >> Me.Minimized=True >> ..... >> End > > Because this didn't work, I asked. > > Any other ideas? > Thanks > Rolf > From jussi.lahtinen at ...626... Wed Feb 8 17:43:36 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 8 Feb 2012 18:43:36 +0200 Subject: [Gambas-user] Start a form minized In-Reply-To: <201202071638.58789.rolf.frogs@...221...> References: <201202071638.58789.rolf.frogs@...221...> Message-ID: One option is to start your program from module [Public Sub Main()] and show the form only when needed. Jussi On Tue, Feb 7, 2012 at 17:38, Rolf Schmidt wrote: > Hi everybody out there > > is it possible to start a form minimized or invisible. > I use a TrayIcon to terminate the program and program should stay in the > background and wait for incoming calls. Then a second from will be shown > with > the connection data but the main form - which only has a close button - > should not be shown. > > Any help? > Thanks > Rolf > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > From jussi.lahtinen at ...626... Wed Feb 8 17:45:50 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 8 Feb 2012 18:45:50 +0200 Subject: [Gambas-user] Missing symbols In-Reply-To: References: Message-ID: Can someone confirm this problem, does it exist only on my system? Gambas 3 r4445 @ Xubuntu 11.10 64bit Jussi On Mon, Feb 6, 2012 at 18:00, Jussi Lahtinen wrote: > One of these days... maybe I have missed something, but any clue why > Gambas programs cannot find some symbols from libc? > Specifically I'm talking about fmod, my libraries (written with C) can > find this without problem. > And even more strange, Gambas programs can find some symbols from libc. > > > Library "libc:6" > Private Extern modf(param As Float, pp As Pointer) As Float > Private Extern fmod(param1 As Float, param2 As Float) As Float > > Public Sub Main() > Dim pp As Pointer = Alloc(SizeOf(gb.Float)) > > Print modf(Pi, pp) > Print fmod(Pi, 2) '<-- only this raises "cannot find symbol..." > > End > > > Demonstration project attached. > > Jussi > From wally at ...2037... Wed Feb 8 18:29:38 2012 From: wally at ...2037... (Wally) Date: Wed, 08 Feb 2012 18:29:38 +0100 Subject: [Gambas-user] Missing symbols In-Reply-To: References: Message-ID: <1347289.hpLcmNcFpQ@...46...> Jussi, same problem here, OpenSuse 12.1 / gambas 3 svn wally On Wednesday, February 08, 2012 18:45:50 Jussi Lahtinen wrote: > Can someone confirm this problem, does it exist only on my system? > > Gambas 3 r4445 @ Xubuntu 11.10 64bit > > Jussi > > On Mon, Feb 6, 2012 at 18:00, Jussi Lahtinen wrote: > > One of these days... maybe I have missed something, but any clue why > > Gambas programs cannot find some symbols from libc? > > Specifically I'm talking about fmod, my libraries (written with C) can > > find this without problem. > > And even more strange, Gambas programs can find some symbols from libc. > > > > > > Library "libc:6" > > Private Extern modf(param As Float, pp As Pointer) As Float > > Private Extern fmod(param1 As Float, param2 As Float) As Float > > > > Public Sub Main() > > Dim pp As Pointer = Alloc(SizeOf(gb.Float)) > > > > Print modf(Pi, pp) > > Print fmod(Pi, 2) '<-- only this raises "cannot find symbol..." > > > > End > > > > > > Demonstration project attached. > > > > Jussi > > ---------------------------------------------------------------------------- > -- Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From jussi.lahtinen at ...626... Wed Feb 8 18:36:14 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 8 Feb 2012 19:36:14 +0200 Subject: [Gambas-user] Missing symbols In-Reply-To: <1347289.hpLcmNcFpQ@...46...> References: <1347289.hpLcmNcFpQ@...46...> Message-ID: 64 or 32 bit system? Jussi On Wed, Feb 8, 2012 at 19:29, Wally wrote: > Jussi, > > same problem here, OpenSuse 12.1 / gambas 3 svn > > wally > > > On Wednesday, February 08, 2012 18:45:50 Jussi Lahtinen wrote: > > Can someone confirm this problem, does it exist only on my system? > > > > Gambas 3 r4445 @ Xubuntu 11.10 64bit > > > > Jussi > > > > On Mon, Feb 6, 2012 at 18:00, Jussi Lahtinen > wrote: > > > One of these days... maybe I have missed something, but any clue why > > > Gambas programs cannot find some symbols from libc? > > > Specifically I'm talking about fmod, my libraries (written with C) can > > > find this without problem. > > > And even more strange, Gambas programs can find some symbols from libc. > > > > > > > > > Library "libc:6" > > > Private Extern modf(param As Float, pp As Pointer) As Float > > > Private Extern fmod(param1 As Float, param2 As Float) As Float > > > > > > Public Sub Main() > > > Dim pp As Pointer = Alloc(SizeOf(gb.Float)) > > > > > > Print modf(Pi, pp) > > > Print fmod(Pi, 2) '<-- only this raises "cannot find symbol..." > > > > > > End > > > > > > > > > Demonstration project attached. > > > > > > Jussi > > > > > ---------------------------------------------------------------------------- > > -- Keep Your Developer Skills Current with LearnDevNow! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-d2d > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From wally at ...2037... Wed Feb 8 18:47:08 2012 From: wally at ...2037... (Wally) Date: Wed, 08 Feb 2012 18:47:08 +0100 Subject: [Gambas-user] Missing symbols In-Reply-To: References: <1347289.hpLcmNcFpQ@...46...> Message-ID: <1750749.BcqgEPdhL3@...46...> 32 On Wednesday, February 08, 2012 19:36:14 Jussi Lahtinen wrote: > 64 or 32 bit system? > > Jussi > > On Wed, Feb 8, 2012 at 19:29, Wally wrote: > > Jussi, > > > > same problem here, OpenSuse 12.1 / gambas 3 svn > > > > wally > > > > On Wednesday, February 08, 2012 18:45:50 Jussi Lahtinen wrote: > > > Can someone confirm this problem, does it exist only on my system? > > > > > > Gambas 3 r4445 @ Xubuntu 11.10 64bit > > > > > > Jussi > > > > > > On Mon, Feb 6, 2012 at 18:00, Jussi Lahtinen > > > > wrote: > > > > One of these days... maybe I have missed something, but any clue > > > > why > > > > Gambas programs cannot find some symbols from libc? > > > > Specifically I'm talking about fmod, my libraries (written with > > > > C) can find this without problem. > > > > And even more strange, Gambas programs can find some symbols > > > > from libc. > > > > > > > > > > > > Library "libc:6" > > > > Private Extern modf(param As Float, pp As Pointer) As Float > > > > Private Extern fmod(param1 As Float, param2 As Float) As Float > > > > > > > > Public Sub Main() > > > > Dim pp As Pointer = Alloc(SizeOf(gb.Float)) > > > > > > > > Print modf(Pi, pp) > > > > Print fmod(Pi, 2) '<-- only this raises "cannot find > > > > symbol..." > > > > > > > > End > > > > > > > > > > > > Demonstration project attached. > > > > > > > > Jussi > > > > ------------------------------------------------------------------------ > > ----> > > > -- Keep Your Developer Skills Current with LearnDevNow! > > > The most comprehensive online learning library for Microsoft > > > developers > > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, > > > MVC3, Metro Style Apps, more. Free future releases when you > > > subscribe now! http://p.sf.net/sfu/learndevnow-d2d > > > _______________________________________________ > > > Gambas-user mailing list > > > Gambas-user at lists.sourceforge.net > > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > ------------------------------------------------------------------------ > > ------ Keep Your Developer Skills Current with LearnDevNow! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-d2d > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > ---------------------------------------------------------------------------- > -- Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From jussi.lahtinen at ...626... Wed Feb 8 19:03:09 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 8 Feb 2012 20:03:09 +0200 Subject: [Gambas-user] Missing symbols In-Reply-To: <1750749.BcqgEPdhL3@...46...> References: <1347289.hpLcmNcFpQ@...46...> <1750749.BcqgEPdhL3@...46...> Message-ID: OK, thanks! Jussi On Wed, Feb 8, 2012 at 19:47, Wally wrote: > > 32 > > On Wednesday, February 08, 2012 19:36:14 Jussi Lahtinen wrote: > > 64 or 32 bit system? > > > > Jussi > > > > On Wed, Feb 8, 2012 at 19:29, Wally wrote: > > > Jussi, > > > > > > same problem here, OpenSuse 12.1 / gambas 3 svn > > > > > > wally > > > > > > On Wednesday, February 08, 2012 18:45:50 Jussi Lahtinen wrote: > > > > Can someone confirm this problem, does it exist only on my system? > > > > > > > > Gambas 3 r4445 @ Xubuntu 11.10 64bit > > > > > > > > Jussi > > > > > > > > On Mon, Feb 6, 2012 at 18:00, Jussi Lahtinen > > > > > > wrote: > > > > > One of these days... maybe I have missed something, but any clue > > > > > why > > > > > Gambas programs cannot find some symbols from libc? > > > > > Specifically I'm talking about fmod, my libraries (written with > > > > > C) can find this without problem. > > > > > And even more strange, Gambas programs can find some symbols > > > > > from libc. > > > > > > > > > > > > > > > Library "libc:6" > > > > > Private Extern modf(param As Float, pp As Pointer) As Float > > > > > Private Extern fmod(param1 As Float, param2 As Float) As Float > > > > > > > > > > Public Sub Main() > > > > > Dim pp As Pointer = Alloc(SizeOf(gb.Float)) > > > > > > > > > > Print modf(Pi, pp) > > > > > Print fmod(Pi, 2) '<-- only this raises "cannot find > > > > > symbol..." > > > > > > > > > > End > > > > > > > > > > > > > > > Demonstration project attached. > > > > > > > > > > Jussi > > > > > > > ------------------------------------------------------------------------ > > > ----> > > > > -- Keep Your Developer Skills Current with LearnDevNow! > > > > The most comprehensive online learning library for Microsoft > > > > developers > > > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, > > > > MVC3, Metro Style Apps, more. Free future releases when you > > > > subscribe now! http://p.sf.net/sfu/learndevnow-d2d > > > > _______________________________________________ > > > > Gambas-user mailing list > > > > Gambas-user at lists.sourceforge.net > > > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > > ------------------------------------------------------------------------ > > > ------ Keep Your Developer Skills Current with LearnDevNow! > > > The most comprehensive online learning library for Microsoft developers > > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, > MVC3, > > > Metro Style Apps, more. Free future releases when you subscribe now! > > > http://p.sf.net/sfu/learndevnow-d2d > > > _______________________________________________ > > > Gambas-user mailing list > > > Gambas-user at lists.sourceforge.net > > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > ---------------------------------------------------------------------------- > > -- Keep Your Developer Skills Current with LearnDevNow! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-d2d > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Wed Feb 8 19:19:42 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Wed, 08 Feb 2012 19:19:42 +0100 Subject: [Gambas-user] Missing symbols In-Reply-To: References: Message-ID: <4F32BCBE.1010407@...1...> Le 06/02/2012 17:00, Jussi Lahtinen a ?crit : > One of these days... maybe I have missed something, but any clue why Gambas > programs cannot find some symbols from libc? fmod is not in 'libc' but in 'libm'. Regards, -- Beno?t Minisini From jussi.lahtinen at ...626... Wed Feb 8 19:36:06 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 8 Feb 2012 20:36:06 +0200 Subject: [Gambas-user] Missing symbols In-Reply-To: <4F32BCBE.1010407@...1...> References: <4F32BCBE.1010407@...1...> Message-ID: I thought libc stands for C standard library. Apparently they are all over different binaries... Thanks! Jussi 2012/2/8 Beno?t Minisini > Le 06/02/2012 17:00, Jussi Lahtinen a ?crit : > > One of these days... maybe I have missed something, but any clue why > Gambas > > programs cannot find some symbols from libc? > > fmod is not in 'libc' but in 'libm'. > > Regards, > > -- > Beno?t Minisini > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...2524... Wed Feb 8 21:35:48 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Wed, 08 Feb 2012 20:35:48 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <4-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <4-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <5-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Comment #5 on issue 123 by benoit.m... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 Libraries dependencies are not loaded automatically anymore in revision #4463. Tell me if the situation is better for you. Now I have to find a way for libraries (that are just normal projects) to have real dependencies. Maybe by using the same interface as the one used by components... From abbat.81 at ...787... Wed Feb 8 22:14:17 2012 From: abbat.81 at ...787... (abbat) Date: Wed, 8 Feb 2012 13:14:17 -0800 (PST) Subject: [Gambas-user] COPY file if "file allready exist" Message-ID: <33289311.post@...1379...> Sorry, if it's abasic question (but GAMBAS is Almost mean BASIC :-)) How to copy a file if it is already exist? And do not get any error. Overwrite Tnx. -- View this message in context: http://old.nabble.com/COPY-file-if-%22file-allready-exist%22-tp33289311p33289311.html Sent from the gambas-user mailing list archive at Nabble.com. From willy at ...2734... Wed Feb 8 22:30:52 2012 From: willy at ...2734... (Willy Raets) Date: Wed, 08 Feb 2012 22:30:52 +0100 Subject: [Gambas-user] COPY file if "file allready exist" In-Reply-To: <33289311.post@...1379...> References: <33289311.post@...1379...> Message-ID: <1328736652.2108.11.camel@...2735...> Example: File: CopyMe.txt Location: Userhome directory/MyFiles Copy to: Userhome directory/MyCopyFiles DIM sSourcePath, sCopyPath AS String sSourcePath = User.Home & "/MyFiles" sCopyPath = User.Home & "/MyCopyFiles" 'First check if file exists If Exist(sSourcePath & "/CopyMe.txt") THEN 'Now check if copyto directory exists IF NOT (Exist(sCopyPath)) THEN MKDIR sCopyPath ENDIF 'Now check if file exists IF NOT (Exist(sCopyPath & "/CopyMe.txt")) THEN COPY sSourcePath & "CopyMe.txt" TO sCopyPath & "/CopyMe.txt" ELSE 'If Exists first remove old file then copy new file KILL sCopyPath & "/CopyMe.txt" COPY sSourcePath & "CopyMe.txt" TO sCopyPath & "/CopyMe.txt" ENDIF ENDIF This will only generate errors in case you have not enough access rights on the directory. Hope this helps... Willy On wo, 2012-02-08 at 13:14 -0800, abbat wrote: > Sorry, if it's abasic question (but GAMBAS is Almost mean BASIC :-)) > > How to copy a file if it is already exist? > And do not get any error. > Overwrite > > Tnx. -- Met vriendelijke groeten/ With kind regards, Willy Raets, Voorzitter/chairman, Earthship Belgium vzw. Nederlandse website: http://www.earthshipbelgium.be/nl.html English Website: http://www.earthshipbelgium.be/en.html From eilert-sprachen at ...221... Thu Feb 9 08:32:30 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 09 Feb 2012 08:32:30 +0100 Subject: [Gambas-user] COPY file if "file allready exist" In-Reply-To: <33289311.post@...1379...> References: <33289311.post@...1379...> Message-ID: <4F33768E.2030804@...221...> Am 08.02.2012 22:14, schrieb abbat: > > Sorry, if it's abasic question (but GAMBAS is Almost mean BASIC :-)) > > How to copy a file if it is already exist? > And do not get any error. > Overwrite > > Tnx. You can verify with If Exist() Then before you copy and decide what to do with it (either simply KILL or rename the file, which is more complicated). Rolf From adamnt42 at ...626... Thu Feb 9 10:21:29 2012 From: adamnt42 at ...626... (GMail) Date: Thu, 09 Feb 2012 19:51:29 +1030 Subject: [Gambas-user] COPY file if "file allready exist" In-Reply-To: <1328736652.2108.11.camel@...2735...> References: <33289311.post@...1379...> <1328736652.2108.11.camel@...2735...> Message-ID: <1328779289.24666.1.camel@...2688...> Thanks Rolf and Willy, I had exactly the same problem today! Bruce From john.aaron.rose at ...626... Fri Feb 10 10:44:42 2012 From: john.aaron.rose at ...626... (John Rose) Date: Fri, 10 Feb 2012 09:44:42 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1328867082.2908.9.camel@...2661...> As I previously said, when I add a new row (by first clicking the New button in my DataBrowser control) / change data displayed in my DataBrowser control and then click the save button (in my DataBrowser control), it comes up with a dialog box saying 'Connection not opened' with OK button only (and clicking OK does not result in saving). The Editable property is set to true. Has anybody successfully used the Save button in a DataBrowser control in Gambas3? From fr.archer at ...2736... Fri Feb 10 11:20:21 2012 From: fr.archer at ...2736... (=?koi8-r?B?4sXT0MHMz9cg4czFy9PFyg==?=) Date: Fri, 10 Feb 2012 17:20:21 +0700 Subject: [Gambas-user] DataSource & DataBrowser problem In-Reply-To: <1328867082.2908.9.camel@...2661...> References: <1328867082.2908.9.camel@...2661...> Message-ID: <70691328869221@...2773...> My DataBrowser control saved automatic, you can not press save. 10.02.2012, 16:44, "John Rose" : > As I previously said, when I add a new row (by first clicking the New > button in ?my DataBrowser control) / change data displayed in my > DataBrowser control and then click the save button (in my DataBrowser > control), it comes up with a dialog box saying 'Connection not opened' > with OK button only (and clicking OK does not result in saving). The > Editable property is set to true. Has anybody successfully used the Save > button in a DataBrowser control in Gambas3? > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -- ____ ? ?????????, ???????? ???????. From gambas at ...2524... Fri Feb 10 15:21:08 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Fri, 10 Feb 2012 14:21:08 +0000 Subject: [Gambas-user] Issue 207 in gambas: Event Save get error at DataBrowser In-Reply-To: <0-6813199134517018827-3591540882422464748-gambas=googlecode.com@...2524...> References: <0-6813199134517018827-3591540882422464748-gambas=googlecode.com@...2524...> Message-ID: <1-6813199134517018827-3591540882422464748-gambas=googlecode.com@...2524...> Comment #1 on issue 207 by john.aaron.rose at ...626...: Event Save get error at DataBrowser http://code.google.com/p/gambas/issues/detail?id=207 When I try to Save after adding/changing rows , I get a dialog box saying 'Connection not opened' with OK button only (and clicking OK does not result in saving). This is on a SQLite3 database. [OperatingSystem] OperatingSystem=Linux KernelRelease=2.6.32-38-generic DistributionVendor=Ubuntu DistributionRelease="Ubuntu 10.04.3 LTS" [System] CPUArchitecture=i686 TotalRam=1930772 kB Desktop=Gnome [Gambas] Gambas1=Not Installed Gambas2=Not Installed Gambas3=3.0.90 Gambas3Path=/usr/local/bin/gbx3 From fabianfloresvadell at ...626... Fri Feb 10 20:39:12 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 16:39:12 -0300 Subject: [Gambas-user] Gambas bug? Message-ID: Hi. When I execute this: Print Object.Call(["John", "Peter"], "Count") I get an error like this: "Count Symbol unknown in the String []" Thanks in advance. -- Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From nando_f at ...951... Fri Feb 10 20:44:43 2012 From: nando_f at ...951... (nando) Date: Fri, 10 Feb 2012 14:44:43 -0500 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: <20120210194406.M90779@...951...> First, what are you trying to do? ---------- Original Message ----------- From: Fabi?n Flores Vadell To: mailing list for gambas users Sent: Fri, 10 Feb 2012 16:39:12 -0300 Subject: [Gambas-user] Gambas bug? > Hi. > > When I execute this: > > Print Object.Call(["John", "Peter"], "Count") > > I get an error like this: > > "Count Symbol unknown in the String []" > > Thanks in advance. > > -- > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From fabianfloresvadell at ...626... Fri Feb 10 21:12:43 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 17:12:43 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: <20120210194406.M90779@...951...> References: <20120210194406.M90779@...951...> Message-ID: 2012/2/10 nando > First, what are you trying to do?-- > I'm trying to find a design pattern that allows me to use the introspective features of Gambas to avoid the boring work consisting in write (in a class) the signatures of some methods that belong to one of its collaborators (that I need to expose). In this case, I need to expose some methods from an array in my class, but I don't want to write the wrapper signatures, e.g.: Public Sub Add(somethig As type) myArray.Add(something) End Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From emil.lenngren at ...626... Fri Feb 10 21:15:51 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Fri, 10 Feb 2012 21:15:51 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: <20120210194406.M90779@...951...> Message-ID: Can't you just store the array in an "Object", then each calls are dispatched? Dim o As Object o = the_array o.Add(whatever) /Emil 2012/2/10 Fabi?n Flores Vadell > 2012/2/10 nando > > > First, what are you trying to do?-- > > > > > I'm trying to find a design pattern that allows me to use the introspective > features of Gambas to avoid the boring work consisting in write (in a > class) the signatures of some methods that belong to one of its > collaborators (that I need to expose). > In this case, I need to expose some methods from an array in my class, but > I don't want to write the wrapper signatures, e.g.: > > Public Sub Add(somethig As type) > myArray.Add(something) > End > > > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...2524... Fri Feb 10 21:17:05 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Fri, 10 Feb 2012 20:17:05 +0000 Subject: [Gambas-user] Issue 209 in gambas: Inheritance and translatable constant strings does not work Message-ID: <0-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 209 by emil.len... at ...626...: Inheritance and translatable constant strings does not work http://code.google.com/p/gambas/issues/detail?id=209 1) Describe the problem. Let's say you have a base class with a string constant that is not translatable. If you now inherit the class and override the string constant with a translatable string, the translated version of the string is not always used. The problem is caused by an optimization in gbx_exec_push.c 2) GIVE THE FOLLOWING INFORMATIONS (if they are appropriate): Version: TRUNK Revision: r4463 3) Provide a little project that reproduces the bug or the crash. Class1: Public Const ConstString As String = "hello" Class2: Inherits Class1 Public Const ConstString As String = ("hello2") And the code: Dim i As Integer Dim e As Class1 For i = 1 To 2 If i = 1 Then e = New Class1 Else e = New Class2 End If Print e.ConstString Next 5) Explain clearly how to reproduce the bug or the crash. Mark the project as translatable, and translate the string "hello2". The program will output: hello hello2 and NOT the translated version of hello2. It is same problem when the base class has a translatable string, but the inherited marks the string as non-translatable. From emil.lenngren at ...626... Fri Feb 10 21:23:41 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Fri, 10 Feb 2012 21:23:41 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: You probably get the error because Count is a property and not a method. There is a Object.GetProperty method you can use instead ;) Print Object.GetProperty(["John", "Peter"], "Count") /Emil 2012/2/10 Fabi?n Flores Vadell > Hi. > > When I execute this: > > Print Object.Call(["John", "Peter"], "Count") > > I get an error like this: > > "Count Symbol unknown in the String []" > > Thanks in advance. > > -- > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From fabianfloresvadell at ...626... Fri Feb 10 21:38:35 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 17:38:35 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: 2012/2/10 Emil Lenngren > You probably get the error because Count is a property and not a method. > > There is a Object.GetProperty method you can use instead ;) > > Print Object.GetProperty(["John", "Peter"], "Count") > Thanks Emil. It seems to me like the encapsulation is broken because I need to be conscious of the implementation (property or method) in order to pass the message that I want. That could not be a great problem in the daily programming, but to programming in a reflexive way it seems to me inflexible. What you think? > -- > Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From jussi.lahtinen at ...626... Fri Feb 10 21:46:51 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Fri, 10 Feb 2012 22:46:51 +0200 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: You can check whether it is property or method. Dim hCls As Class = Object.Class(["John", "Peter"]) If hCls["Count"].Kind = Class.Method Then ... Jussi 2012/2/10 Fabi?n Flores Vadell > 2012/2/10 Emil Lenngren > > > You probably get the error because Count is a property and not a method. > > > > There is a Object.GetProperty method you can use instead ;) > > > > Print Object.GetProperty(["John", "Peter"], "Count") > > > > Thanks Emil. > > It seems to me like the encapsulation is broken because I need to be > conscious of the implementation (property or method) in order to pass the > message that I want. > > That could not be a great problem in the daily programming, but to > programming in a reflexive way it seems to me inflexible. > > What you think? > > > > -- > > > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From emil.lenngren at ...626... Fri Feb 10 21:47:11 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Fri, 10 Feb 2012 21:47:11 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: Did the Object solution not solve your problem? It should work in all cases when the name of the function/property is the same at all calls/property readings. If you use different symbol names each time, maybe you can use something like this: Try Return Object.GetProperty(object, name) Catch Return Object.Call(object, name) But you probably should try another code design if you really need this kind of code ;) /Emil 2012/2/10 Fabi?n Flores Vadell > 2012/2/10 Emil Lenngren > > > You probably get the error because Count is a property and not a method. > > > > There is a Object.GetProperty method you can use instead ;) > > > > Print Object.GetProperty(["John", "Peter"], "Count") > > > > Thanks Emil. > > It seems to me like the encapsulation is broken because I need to be > conscious of the implementation (property or method) in order to pass the > message that I want. > > That could not be a great problem in the daily programming, but to > programming in a reflexive way it seems to me inflexible. > > What you think? > > > > -- > > > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From fabianfloresvadell at ...626... Fri Feb 10 21:56:32 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 17:56:32 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: 2012/2/10 Jussi Lahtinen > You can check whether it is property or method. > > Dim hCls As Class = Object.Class(["John", "Peter"]) > > If hCls["Count"].Kind = Class.Method Then > Yes, I figured out. Thanks Jussi From gambas at ...1... Fri Feb 10 21:58:41 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Fri, 10 Feb 2012 21:58:41 +0100 Subject: [Gambas-user] Help for Image and Picture Colors In-Reply-To: <4F3035C8.5000004@...20...> References: <4F2C7801.3060907@...20...> <4F2C79A1.3010706@...20...> <4F302FD6.7010405@...1...> <4F3035C8.5000004@...20...> Message-ID: <4F358501.8080706@...1...> Le 06/02/2012 21:19, tobias a ?crit : > hi, > > Beno?t Minisini wrote: >> Le 04/02/2012 01:19, tobias a ?crit : >>> On 04.02.2012 01:12, tobias wrote: >>>> Hi, >>>> >>>> I really need help. There's a lot of work with colors in Images and >>>> Pictures in a project and between these classes. This is generally >>>> speaking as follows: I have a class which has an 8*8px Image which is >>>> manipulated (due to the easy of accessing pixels directly). Using a >>>> property of my class, I provide access to a scaled version of the Image >>>> as a Picture (which is created when requested). So I do some things and >>>> when manually resizing the Image to get the prototype of the Picture to >>>> return (it is needed as bigger version of the Image without >>>> anti-aliasing, I don't get this result with Image.Stretch(), and doing >>>> it manually is not a problem) there seem to appear problems with >>>> transparency. I read that Pictures do not have an alpha channel and I >>>> noticed that colors from the ColorChooser or Color class are given with >>>> alpha channel set to 0x00 which will be transparent for the Image >>>> class... so I tried adding&Hff000000& to whatever color is assigned to >>>> any pixel in the 8*8px Image or not to do it and some other experiments >>>> but nothing worked on the entire project. there's always something >>>> transparent or black or whatever. I really go nuts with this. Anyone to >>>> my rescue? >>>> >>>> Regards, >>>> Tobi >>> wait a minute. I forgot to say that I don't even need the transparency >>> feature of the Image class. I only use Image - as I said - because of >>> Image[x, y] pixel access. For the meantime - or as a final solution? >>> there may be a lot of those accesses and I thought using Image[x, y] >>> will be the most efficient way to go - I switch to using an 8*8px >>> Picture and Draw.Pixel() instead but I would really appreciate anyone >>> clarify this topic to me. >>> >> >> I understand nothing. Maybe because I'm a little sick, but if you can be >> clearer... >> > > it's a messy explanation, i just recalled too... > > the situation is as follows: i have a class that takes care of designing > a picture for me according to user input. because of the ease of > accessing pixels with the image class i took an image behind the scenes > but it has to be converted to a picture for display in a PictureBox at > the front end. moreover it has to be resized which i do manually and is > no big deal for my format. i used to import pictures and images into the > class, etc. which overall introduces as big back and forth of image<-> > picture conversion, resizing, etc. > the problem first came up when i incorporated palettes created by > another program and stored in binary files. i noticed that these were in > ARGB format with the A component set to 0x00 all the time (colors came > from a ColorChooser, later i noticed that the constants in the Color > class do likewise). while this works (color is displayed) when drawing > it to a picture, it doesn't when writing it to an image pixel. i tried > conversion functions and everything that came in my mind. > at the end i rewrote the class to use pictures. those pictures are > created with the Transparent = False instanciation parameter. from those > i can derive Picture.Image on which i operate to speed things up. > this is sort of solved and the program works fine now. > > i seem to repress the memory of what i tried (pathetic programmer's > brain :) ) but i can tell that nothing worked on the entire project > (which was certainly a fault due to my quick fixes or project > infrastructure) but to clarify things: > it resulted in transparency in all kinds of places in the whole program > originally introduced by reading colors from standard components that > had their alpha channel zeroed which according to the docs signaled the > image class that this color is fully transparent. > > i hope it didn't get as complicated but recalling the situation pointed > me to the fact that actually i do not know why it is working now (seems > to rely on the Transparent = False picture instanciation?)... > > regards, > tobi > Mff... If you need to create a Picture, start from an Image, and convert it to a Picture at the last step. Do not use the Transparent property of Pictures. As for transparency: it is inverted between pixels in memory and Gambas color values. If you use the Image class and the [] operator, then this is taken into account transparently. This is all I can say: I hope it will help you! -- Beno?t Minisini From tobiasboege01 at ...1601... Fri Feb 10 22:04:19 2012 From: tobiasboege01 at ...1601... (tobi) Date: Fri, 10 Feb 2012 22:04:19 +0100 Subject: [Gambas-user] Help for Image and Picture Colors In-Reply-To: <4F358501.8080706@...1...> References: <4F2C7801.3060907@...20...> <4F2C79A1.3010706@...20...> <4F302FD6.7010405@...1...> <4F3035C8.5000004@...20...> <4F358501.8080706@...1...> Message-ID: <20120210210419.GA5433@...2774...> On Fri, 10 Feb 2012, Beno?t Minisini wrote: > Le 06/02/2012 21:19, tobias a ?crit : > > hi, > > > > Beno?t Minisini wrote: > >> Le 04/02/2012 01:19, tobias a ?crit : > >>> On 04.02.2012 01:12, tobias wrote: > >>>> Hi, > >>>> > >>>> I really need help. There's a lot of work with colors in Images and > >>>> Pictures in a project and between these classes. This is generally > >>>> speaking as follows: I have a class which has an 8*8px Image which is > >>>> manipulated (due to the easy of accessing pixels directly). Using a > >>>> property of my class, I provide access to a scaled version of the Image > >>>> as a Picture (which is created when requested). So I do some things and > >>>> when manually resizing the Image to get the prototype of the Picture to > >>>> return (it is needed as bigger version of the Image without > >>>> anti-aliasing, I don't get this result with Image.Stretch(), and doing > >>>> it manually is not a problem) there seem to appear problems with > >>>> transparency. I read that Pictures do not have an alpha channel and I > >>>> noticed that colors from the ColorChooser or Color class are given with > >>>> alpha channel set to 0x00 which will be transparent for the Image > >>>> class... so I tried adding&Hff000000& to whatever color is assigned to > >>>> any pixel in the 8*8px Image or not to do it and some other experiments > >>>> but nothing worked on the entire project. there's always something > >>>> transparent or black or whatever. I really go nuts with this. Anyone to > >>>> my rescue? > >>>> > >>>> Regards, > >>>> Tobi > >>> wait a minute. I forgot to say that I don't even need the transparency > >>> feature of the Image class. I only use Image - as I said - because of > >>> Image[x, y] pixel access. For the meantime - or as a final solution? > >>> there may be a lot of those accesses and I thought using Image[x, y] > >>> will be the most efficient way to go - I switch to using an 8*8px > >>> Picture and Draw.Pixel() instead but I would really appreciate anyone > >>> clarify this topic to me. > >>> > >> > >> I understand nothing. Maybe because I'm a little sick, but if you can be > >> clearer... > >> > > > > it's a messy explanation, i just recalled too... > > > > the situation is as follows: i have a class that takes care of designing > > a picture for me according to user input. because of the ease of > > accessing pixels with the image class i took an image behind the scenes > > but it has to be converted to a picture for display in a PictureBox at > > the front end. moreover it has to be resized which i do manually and is > > no big deal for my format. i used to import pictures and images into the > > class, etc. which overall introduces as big back and forth of image<-> > > picture conversion, resizing, etc. > > the problem first came up when i incorporated palettes created by > > another program and stored in binary files. i noticed that these were in > > ARGB format with the A component set to 0x00 all the time (colors came > > from a ColorChooser, later i noticed that the constants in the Color > > class do likewise). while this works (color is displayed) when drawing > > it to a picture, it doesn't when writing it to an image pixel. i tried > > conversion functions and everything that came in my mind. > > at the end i rewrote the class to use pictures. those pictures are > > created with the Transparent = False instanciation parameter. from those > > i can derive Picture.Image on which i operate to speed things up. > > this is sort of solved and the program works fine now. > > > > i seem to repress the memory of what i tried (pathetic programmer's > > brain :) ) but i can tell that nothing worked on the entire project > > (which was certainly a fault due to my quick fixes or project > > infrastructure) but to clarify things: > > it resulted in transparency in all kinds of places in the whole program > > originally introduced by reading colors from standard components that > > had their alpha channel zeroed which according to the docs signaled the > > image class that this color is fully transparent. > > > > i hope it didn't get as complicated but recalling the situation pointed > > me to the fact that actually i do not know why it is working now (seems > > to rely on the Transparent = False picture instanciation?)... > > > > regards, > > tobi > > > > Mff... If you need to create a Picture, start from an Image, and convert > it to a Picture at the last step. Do not use the Transparent property of > Pictures. > > As for transparency: it is inverted between pixels in memory and Gambas > color values. If you use the Image class and the [] operator, then this > is taken into account transparently. > > This is all I can say: I hope it will help you! > > -- > Beno?t Minisini > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user i got a working solution now but your statement cleared up the reason for which my conversion function (simply adding 0xff000000 to all colors smaller than that value before passing them to Image[]) didn't succeed... thanks anyway. From fabianfloresvadell at ...626... Fri Feb 10 22:18:21 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 18:18:21 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: 2012/2/10 Emil Lenngren > Did the Object solution not solve your problem? It should work in all cases > when the name of the function/property is the same at all calls/property > readings. > II want to write just one method that allow me to call whatever method I could need from one collaborator (the array in this case). That is why I think that this approach will not work. > If you use different symbol names each time, maybe you can use something > like this: > Try > Return Object.GetProperty(object, name) > Catch > Return Object.Call(object, name) > To check or to catch. That is the question. :) > But you probably should try another code design if you really need this > kind of code ;) > > /Emil > Humm. I want to avoid the need to write a wrapper for each method that I need expose from the "helper" class. The easy way is to move the fingers faster. But eventually that will become in a disease. (the issue of the carpal tunnel) :) But, if you knows a better way to do that, please let me know. Thank you. Fabi?n From fabianfloresvadell at ...626... Fri Feb 10 22:20:33 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 18:20:33 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: 2012/2/10 Fabi?n Flores Vadell > 2012/2/10 Emil Lenngren > >> Did the Object solution not solve your problem? It should work in all >> cases >> when the name of the function/property is the same at all calls/property >> readings. >> > > II want to write just one method that allow me to call whatever method I > could need from one collaborator (the array in this case). That is why I > think that this approach will not work. > whatever method or property, that's what i meant. > -- > Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From emil.lenngren at ...626... Fri Feb 10 22:27:07 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Fri, 10 Feb 2012 22:27:07 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: Can you give some examples how you mean? What do you need wrappers for? I don't think I understand fully what you mean, but it seems interesting :) /Emil 2012/2/10 Fabi?n Flores Vadell > 2012/2/10 Fabi?n Flores Vadell > > > 2012/2/10 Emil Lenngren > > > >> Did the Object solution not solve your problem? It should work in all > >> cases > >> when the name of the function/property is the same at all calls/property > >> readings. > >> > > > > II want to write just one method that allow me to call whatever method I > > could need from one collaborator (the array in this case). That is why I > > think that this approach will not work. > > > > whatever method or property, that's what i meant. > > > > > -- > > > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Fri Feb 10 22:54:58 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Fri, 10 Feb 2012 22:54:58 +0100 Subject: [Gambas-user] extern library In-Reply-To: <1559919.WVzDYH7Lhk@...46...> References: <3525035.btJeaiBlXI@...46...> <4F28F135.2070300@...1740...> <4F2E31D5.60706@...1...> <1559919.WVzDYH7Lhk@...46...> Message-ID: <4F359232.9000607@...1...> Le 05/02/2012 18:42, Wally a ?crit : > talking about Gambas 3: > > When i place my library to /usr/local/lib and run ldconfig it works and > my_gb3_project can find the lib and its functions. > When i put it into my_gb3_project folder the library can not be found. > Where to place the library ganbas3 may find it ? It should work. Can you send me a little project with your library inside so that I can check what happens exactly? -- Beno?t Minisini From fabianfloresvadell at ...626... Fri Feb 10 23:36:50 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 19:36:50 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: 2012/2/10 Emil Lenngren > Can you give some examples how you mean? > What do you need wrappers for? > I don't think I understand fully what you mean, but it seems interesting :) > > /Emil > I would like to show you an example, but I can't. If I did, I would have to kill you. :P There is a foolish example: '***************** ' Class Person '***************** $FirstName As String $LastName As String Property Read FirstName As String Property Read LastName As String Public Sub _new(fname As String, lname As String) $FirstName = fname $LastName = lname End Private Function FirstName_Read() As String Return $FirstName End Private Function LastName_Read() As String Return $LastName End '********************* ' PeopleList class '********************* 'aPeople is a collaborator from which I want to expose some methods (by the PeopleList message protocol) Private $aPeople As New Person[] 'The Call method implement the "instrospective call" "pattern" (okay, I just made it up... but it works!) Public Sub Call(aMethodName As String, Optional arguments As Array = Null) As Variant Dim result As Variant If Not [Add, Clear, Count, Insert, {Max}].Exist(aMethodName) Then Return Object.Call($aPeople, aMethodName, arguments) Catch Return Object.GetProperty($aPeople, aMethodName) End 'I want avoid code like this: ' Public Sub Add(aPerson As Person) ' $aPeople.Add(aPerson) ' End ' ' Public Sub Insert(arrayPerson As Person[]) ' $aPeople.Insert(arrayPerson) ' End ' ' Public Sub Clear() ' $aPeople.Clear ' End ' ' Property Read Max ' ' Private Function Max_Read() ' $aPeople.Max ' End ' 'and so on 'More methods for PeopleList: Public Sub PrintList() Dim aPerson As Person For Each aPerson In $aPeople Print aPerson.FirstName & ", " & aPerson.LastName Next End '************** ' Test Class '************** Static Public Sub Main() Dim aPeopleList As New PeopleList Dim MaxItems As Integer Dim Person1, Person2, Person3, Person4 As Person Dim Person5, Person6, Person7, Person8 As Person Person1 = New Person("Carlos", "Delfino") Person2 = New Person("Lionel", "Messi") Person3 = New Person("Luis", "Scola") Person4 = New Person("Emmanuel", "Gin?bili") 'Here are introspective calls: With aPeopleList 'Very ugly sintactically, but that is all we got .Call(.Insert, [[Person1, Person2, Person3]]) .Call(.Add, [Person4]) End With Person5 = New Person("Jhon", "Doe") Person6 = New Person("Jane", "Doe") Person7 = New Person("Nobody", "Gates") Person8 = New Person("Genius", "Minisini") 'Here are introspective calls: With aPeopleList .Call(.Insert, [[Person5, Person6, Person7], .Call(.Max)]) .Call(.Add, [Person8]) Print .Call(.Count) End With aPeopleList.PrintList End > -- > Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From emil.lenngren at ...626... Fri Feb 10 23:57:07 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Fri, 10 Feb 2012 23:57:07 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: So what you want is to extend the array class with some extra methods? Just use Inherits Person[] in the PersonList class ;) /Emil 2012/2/10 Fabi?n Flores Vadell > 2012/2/10 Emil Lenngren > > > Can you give some examples how you mean? > > What do you need wrappers for? > > I don't think I understand fully what you mean, but it seems interesting > :) > > > > /Emil > > > > I would like to show you an example, but I can't. > If I did, I would have to kill you. :P > > > > > > There is a foolish example: > > > '***************** > ' Class Person > '***************** > > $FirstName As String > $LastName As String > > Property Read FirstName As String > Property Read LastName As String > > Public Sub _new(fname As String, lname As String) > $FirstName = fname > $LastName = lname > End > > Private Function FirstName_Read() As String > Return $FirstName > End > > Private Function LastName_Read() As String > Return $LastName > End > > '********************* > ' PeopleList class > '********************* > > 'aPeople is a collaborator from which I want to expose some methods (by the > PeopleList message protocol) > > Private $aPeople As New Person[] > > 'The Call method implement the "instrospective call" "pattern" (okay, I > just made it up... but it works!) > > Public Sub Call(aMethodName As String, Optional arguments As Array = Null) > As Variant > Dim result As Variant > > If Not [Add, Clear, Count, Insert, {Max}].Exist(aMethodName) Then Return > > Object.Call($aPeople, aMethodName, arguments) > > Catch > Return Object.GetProperty($aPeople, aMethodName) > End > > 'I want avoid code like this: > > ' Public Sub Add(aPerson As Person) > ' $aPeople.Add(aPerson) > ' End > ' > ' Public Sub Insert(arrayPerson As Person[]) > ' $aPeople.Insert(arrayPerson) > ' End > ' > ' Public Sub Clear() > ' $aPeople.Clear > ' End > ' > ' Property Read Max > ' > ' Private Function Max_Read() > ' $aPeople.Max > ' End > ' > 'and so on > > 'More methods for PeopleList: > > Public Sub PrintList() > Dim aPerson As Person > > For Each aPerson In $aPeople > Print aPerson.FirstName & ", " & aPerson.LastName > Next > End > > '************** > ' Test Class > '************** > > Static Public Sub Main() > Dim aPeopleList As New PeopleList > Dim MaxItems As Integer > Dim Person1, Person2, Person3, Person4 As Person > Dim Person5, Person6, Person7, Person8 As Person > > Person1 = New Person("Carlos", "Delfino") > Person2 = New Person("Lionel", "Messi") > Person3 = New Person("Luis", "Scola") > Person4 = New Person("Emmanuel", "Gin?bili") > > 'Here are introspective calls: > With aPeopleList > 'Very ugly sintactically, but that is all we got > .Call(.Insert, [[Person1, Person2, Person3]]) > .Call(.Add, [Person4]) > End With > > Person5 = New Person("Jhon", "Doe") > Person6 = New Person("Jane", "Doe") > Person7 = New Person("Nobody", "Gates") > Person8 = New Person("Genius", "Minisini") > > 'Here are introspective calls: > With aPeopleList > .Call(.Insert, [[Person5, Person6, Person7], .Call(.Max)]) > .Call(.Add, [Person8]) > Print .Call(.Count) > End With > > aPeopleList.PrintList > End > > > > > -- > > > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From fabianfloresvadell at ...626... Sat Feb 11 00:33:25 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 20:33:25 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: 2012/2/10 Emil Lenngren > So what you want is to extend the array class with some extra methods? > Just use > Inherits Person[] > in the PersonList class ;) > Did you read the code and comments? Not at all. I don't want use inheritance because I won't all methods and properties from Array[] in the PeopleList interfaz. Hence, I have to use aggregation (composition, delegation). If I use inheritance, the clients of PeopleList could do bad things or things that have no sense (as the case), e.g. PeopleList.Fill PeopleList.Push PeopleList.Pop This isn't the best example. But if you think about a minute, you will catch it. Do not focus on the example, because really, what I want isn't to add to a class methods from an array (that's just an example). I looking for a design pattern that allows me to solve a typical problem. That problem could be described as "How to add methods from a helper object without have to rewrite a wrapper for each method (with just a call within) in the host class?". -- Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From emil.lenngren at ...626... Sat Feb 11 00:55:39 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Sat, 11 Feb 2012 00:55:39 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: Ok, I understand your issue. But unfortunately, I don't know any good way how to do it in Gambas. In C++ there are private inheritance that solves the problem, but Gambas only has public inheritance. Maybe Benoit can find out some way how to inherit only "some" of the symbols from a base class, if many Gambas programmers want that, and disallow such an inherited object to be cast to an ancestor class? /Emil 2012/2/11 Fabi?n Flores Vadell > 2012/2/10 Emil Lenngren > > > So what you want is to extend the array class with some extra methods? > > Just use > > Inherits Person[] > > in the PersonList class ;) > > > > Did you read the code and comments? > > Not at all. I don't want use inheritance because I won't all methods and > properties from Array[] in the PeopleList interfaz. Hence, I have to use > aggregation (composition, delegation). > > If I use inheritance, the clients of PeopleList could do bad things or > things that have no sense (as the case), e.g. > > PeopleList.Fill > PeopleList.Push > PeopleList.Pop > > This isn't the best example. But if you think about a minute, you will > catch it. > > Do not focus on the example, because really, what I want isn't to add to a > class methods from an array (that's just an example). I looking for a > design pattern that allows me to solve a typical problem. > > That problem could be described as "How to add methods from a helper object > without have to rewrite a wrapper for each method (with just a call within) > in the host class?". > > -- > Fabi?n Flores Vadell > www.comoprogramarcongambas.blogspot.com > www.speedbooksargentina.blogspot.com > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From fabianfloresvadell at ...626... Sat Feb 11 01:59:56 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Fri, 10 Feb 2012 21:59:56 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: 2012/2/10 Emil Lenngren > Ok, I understand your issue. But unfortunately, I don't know any good way > how to do it in Gambas. > Well, that's what it is solve this problem by a single method that make a dinamic call. > In C++ there are private inheritance that solves the problem, but Gambas > only has public inheritance. > > Maybe Benoit can find out some way how to inherit only "some" of the > symbols from a base class, if many Gambas programmers want that, and > disallow such an inherited object to be cast to an ancestor class? > > /Emil I changed my mind about this, few years ago. The problem with inheritance is that involves an conceptual issue: inheritance implies that an instance of the subclass "is a" exemplar (specimen) of both, its class and its superclass, and the subclass is an extension of the behaviour of the superclass. So, a subclass that have less behaviour that its superclass is something that is at odds with the object theory. In fact, the object theory could prescind from inheritance (as implementation mechanism) and just support delegation. The Google GO language is going down that road. The example that I wrote is very poor. The problem is shown more clearly when it is considered that an object can have many collaborators and sometimes the host object will need to expose methods from several of they. This is the case, and a solution based on inheritance would require a mechanism to support selective multiple inheritance (Frankenstein and all his family). I agree with you about that would be great that the interpreter provide us a feature that would allow us to do this selectively, but by delegation. Regards. -- > Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From wally at ...2037... Sat Feb 11 04:56:15 2012 From: wally at ...2037... (Wally) Date: Sat, 11 Feb 2012 04:56:15 +0100 Subject: [Gambas-user] extern library In-Reply-To: <4F359232.9000607@...1...> References: <3525035.btJeaiBlXI@...46...> <1559919.WVzDYH7Lhk@...46...> <4F359232.9000607@...1...> Message-ID: <1995024.MaiKR0Y7JI@...46...> On Friday, February 10, 2012 22:54:58 Beno?t Minisini wrote: > Le 05/02/2012 18:42, Wally a ?crit : > > talking about Gambas 3: > > > > When i place my library to /usr/local/lib and run ldconfig it works and > > my_gb3_project can find the lib and its functions. > > When i put it into my_gb3_project folder the library can not be found. > > Where to place the library ganbas3 may find it ? > > It should work. Can you send me a little project with your library > inside so that I can check what happens exactly? It works when libMylib.so is in the project folder and i do Library "./libMylib" in top of the form. Library "./libMylib:0" also works if in project folder is a symbolic link libMylib.so.0 --> libMylib.so I can live with that but it would be nice if it would be mentioned in docs. Maybe i just did not find it in the docs. wally From bbruen at ...2308... Sat Feb 11 08:36:03 2012 From: bbruen at ...2308... (Bruce Bruen) Date: Sat, 11 Feb 2012 18:06:03 +1030 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: <1328945763.24666.19.camel@...2688...> On Fri, 2012-02-10 at 21:59 -0300, Fabi?n Flores Vadell wrote: > 2012/2/10 Emil Lenngren > Interesting, I have a similar problem, perhaps the same but maybe slightly different. I have a base class that is CREATE PRIVATE, it cannot be instantiated directly by a client application. It contains various methods that must be available to it's child classes (which CAN be instantiated) and can be called by the client application. For example, DBAdd is public in the base class so that the child class can call it. What I have done, with some success is as follows: In the base class I inspect the System.Backtrace and compare the object indicated by the second item (i.e. System.Backtrace[1]) to see that it "IS" a Me. (is that clear, if not I'll have to go find the code?) IOW I check that the caller object is an instance of Me, which can only be the base class itself or a class that inherits the base class. If not, I just raise an "Illegal Call" error. This works within reason, however it has the following drawbacks: a) there is obviously an overhead involved in the check code b) it does not prevent a client application from instantiating an object that inherits directly from the base class. So it goes. To expand this further. I also have examples where I need (read "want") to have methods in the base class that MUST be overridden in the specialised child classes. This is because these methods are templates only. However, they must be present in the base class, as the base class calls these methods! IOW the base class calls "SomeMethod", which my design says "must be implemented in the child class". Gambas is (almost) great at achieving this by its' use of virtual dispatch. If the child class has correctly overridden the base class method, then that is the one that is called. And in the base class, I can have a "stub" method that simply raises an error. If the child class does not override the method the the error is raised. I would love to be able to solve problem b) above. But hope this helps. Bruce From adamnt42 at ...626... Sat Feb 11 08:46:18 2012 From: adamnt42 at ...626... (GMail) Date: Sat, 11 Feb 2012 18:16:18 +1030 Subject: [Gambas-user] Gambas bug? In-Reply-To: <1328945763.24666.19.camel@...2688...> References: <1328945763.24666.19.camel@...2688...> Message-ID: <1328946378.24666.22.camel@...2688...> On Sat, 2012-02-11 at 18:06 +1030, Bruce Bruen wrote: > On Fri, 2012-02-10 at 21:59 -0300, Fabi?n Flores Vadell wrote: > > 2012/2/10 Emil Lenngren > > > > > Interesting, I have a similar problem, perhaps the same but maybe > slightly different. > > I have a base class that is CREATE PRIVATE, it cannot be instantiated > directly by a client application. It contains various methods that must > be available to it's child classes (which CAN be instantiated) and can > be called by the client application. For example, DBAdd is public in > the base class so that the child class can call it. > > What I have done, with some success is as follows: > > In the base class I inspect the System.Backtrace and compare the object > indicated by the second item (i.e. System.Backtrace[1]) to see that it > "IS" a Me. (is that clear, if not I'll have to go find the code?) > IOW I check that the caller object is an instance of Me, which can only > be the base class itself or a class that inherits the base class. If > not, I just raise an "Illegal Call" error. > > This works within reason, however it has the following drawbacks: > a) there is obviously an overhead involved in the check code > b) it does not prevent a client application from instantiating an object > that inherits directly from the base class. > So it goes. > > To expand this further. I also have examples where I need (read "want") > to have methods in the base class that MUST be overridden in the > specialised child classes. This is because these methods are templates > only. However, they must be present in the base class, as the base class > calls these methods! IOW the base class calls "SomeMethod", which my > design says "must be implemented in the child class". Gambas is > (almost) great at achieving this by its' use of virtual dispatch. If the > child class has correctly overridden the base class method, then that is > the one that is called. And in the base class, I can have a "stub" > method that simply raises an error. If the child class does not > override the method the the error is raised. > > I would love to be able to solve problem b) above. > Oh, by the way, the only way I can think of solving b) is to exchange some sort of signature when the objects are created. However, I don't think this can work as the base class is instantiated first by gambas. B From gambas at ...1... Sat Feb 11 08:59:39 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 11 Feb 2012 08:59:39 +0100 Subject: [Gambas-user] TAB on keyboard In-Reply-To: <1328535624.2409.36.camel@...2735...> References: <1328535624.2409.36.camel@...2735...> Message-ID: <4F361FEB.10304@...1...> Le 06/02/2012 14:40, Willy Raets a ?crit : > Hi All, > > When making forms I determine hierarchy of the controls on the form for > navigating the form with TAB-key during runtime. This to make the forms > more user friendly. > > Simple example: > --------------- > Application with 1 form with 3 ValueBoxes. > ValBox1 and ValBox2 for input > ValBox3 for output (lets say sum of ValboX1 and ValBox2) > ValBox3 is read only > ValBox1 has focus on opening form > Button1 for close > Hierarchy on form is ValBox1, ValBox2, Button1, ValBox3. > > Running application then fill in ValBox1. > Hit TAB-key brings you to ValBox2, fill in and ValBox3 gets calculated. > Hit Tab-key brings you to Button1 > > So far so good. > Now hitting Tab-key brings you to ValBox3. (no input field but a read > only), I would like it to go back to ValBox1 and skip the read only > controls. In VB I could determine if a control was effected by use of > TAB-key or not by a property on the control. > ----------------- > > I'm running into this on all my input forms in all my applications > (Gambas2) and it is bothering me. Been looking for a solution for some > time but haven't found any. > > Is there a way in Gambas2 (or Gambas3), when using TAB-key on keyboard > to have it skip (in my case all read only) controls and just go to those > that matter for input? > > Thanks, > > Willy > Qt4 has a way of making controls not accepting focus on TAB, but not GTK+ apparently. I must investigate more to see if it is possible... -- Beno?t Minisini From gambas at ...1... Sat Feb 11 09:12:19 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 11 Feb 2012 09:12:19 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: <4F3622E3.8070805@...1...> Le 10/02/2012 23:36, Fabi?n Flores Vadell a ?crit : > 2012/2/10 Emil Lenngren > >> Can you give some examples how you mean? >> What do you need wrappers for? >> I don't think I understand fully what you mean, but it seems interesting :) >> >> /Emil >> > > I would like to show you an example, but I can't. > If I did, I would have to kill you. :P > > > > > > There is a foolish example: > > > '***************** > ' Class Person > '***************** > > $FirstName As String > $LastName As String > > Property Read FirstName As String > Property Read LastName As String > > Public Sub _new(fname As String, lname As String) > $FirstName = fname > $LastName = lname > End > > Private Function FirstName_Read() As String > Return $FirstName > End > > Private Function LastName_Read() As String > Return $LastName > End > > '********************* > ' PeopleList class > '********************* > > 'aPeople is a collaborator from which I want to expose some methods (by the > PeopleList message protocol) > > Private $aPeople As New Person[] > > 'The Call method implement the "instrospective call" "pattern" (okay, I > just made it up... but it works!) > > Public Sub Call(aMethodName As String, Optional arguments As Array = Null) > As Variant > Dim result As Variant > > If Not [Add, Clear, Count, Insert, {Max}].Exist(aMethodName) Then Return > > Object.Call($aPeople, aMethodName, arguments) > > Catch > Return Object.GetProperty($aPeople, aMethodName) > End > > 'I want avoid code like this: > > ' Public Sub Add(aPerson As Person) > ' $aPeople.Add(aPerson) > ' End > ' > ' Public Sub Insert(arrayPerson As Person[]) > ' $aPeople.Insert(arrayPerson) > ' End > ' > ' Public Sub Clear() > ' $aPeople.Clear > ' End > ' > ' Property Read Max > ' > ' Private Function Max_Read() > ' $aPeople.Max > ' End > ' > 'and so on I don't understand why you want to avoid code like this. This is the best way to implement a PeopleList class. -- Beno?t Minisini From gambas at ...1... Sat Feb 11 09:14:52 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 11 Feb 2012 09:14:52 +0100 Subject: [Gambas-user] Gambas bug? In-Reply-To: References: Message-ID: <4F36237C.5070005@...1...> Le 11/02/2012 00:33, Fabi?n Flores Vadell a ?crit : > > That problem could be described as "How to add methods from a helper object > without have to rewrite a wrapper for each method (with just a call within) > in the host class?". > Why don't you want to write wrappers? Is it just because it is boring? -- Beno?t Minisini From gambas at ...1... Sat Feb 11 09:38:14 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 11 Feb 2012 09:38:14 +0100 Subject: [Gambas-user] gb.GeneralDate formatting is inconsistent In-Reply-To: References: <4F2E326C.8040201@...1...> <4F2E390E.1070408@...1...> Message-ID: <4F3628F6.7090800@...1...> Le 06/02/2012 06:44, Zach Smith a ?crit : >> gb.GeneralDate prints the date part the short way (dd/mm/yy) and prints >> the time if it is not zero. > > The middle example is still inconsistent if one expects 00:00:00 to be > a valid time, that is, midnight (12:00 AM). Also note that the format > is mm/dd/yy only if the time is not 00:00:00. One can get around this > by using a "mm/dd/yyyy hh:nn:ss" format string but having > gb.GeneralDate work for all dates and times would be helpful. I think it should be more coherent with revision #4464. Can you confirm? -- Beno?t Minisini From charles at ...1784... Sat Feb 11 14:10:02 2012 From: charles at ...1784... (charlesg) Date: Sat, 11 Feb 2012 05:10:02 -0800 (PST) Subject: [Gambas-user] TAB on keyboard In-Reply-To: <1328535624.2409.36.camel@...2735...> References: <1328535624.2409.36.camel@...2735...> Message-ID: <33306008.post@...1379...> Willy Raets wrote: > > Is there a way in Gambas2 (or Gambas3), when using TAB-key on keyboard > to have it skip (in my case all read only) controls and just go to those > that matter for input? > 2 workarounds: firstly: > Public Sub TextBox3_GotFocus() > TextBox1.SetFocus > End > secondly: fake a textbox using a label by putting a plain border and changing background colour. You can set the label value but it won't accept focus. -- View this message in context: http://old.nabble.com/TAB-on-keyboard-tp33271575p33306008.html Sent from the gambas-user mailing list archive at Nabble.com. From willy at ...2734... Sat Feb 11 15:07:45 2012 From: willy at ...2734... (Willy Raets) Date: Sat, 11 Feb 2012 15:07:45 +0100 Subject: [Gambas-user] TAB on keyboard In-Reply-To: <33306008.post@...1379...> References: <1328535624.2409.36.camel@...2735...> <33306008.post@...1379...> Message-ID: <1328969265.2026.6.camel@...2735...> Hi Charles, On za, 2012-02-11 at 05:10 -0800, charlesg wrote: > > Willy Raets wrote: > > > > Is there a way in Gambas2 (or Gambas3), when using TAB-key on keyboard > > to have it skip (in my case all read only) controls and just go to those > > that matter for input? > > > > 2 workarounds: > > firstly: > > > > Public Sub TextBox3_GotFocus() > > TextBox1.SetFocus > > End Thanks for the workarrounds. The first one I came up with myself meanwhile, quite stupid of me not to think about that before (bit to focussed on how things work in VB, need to detox there :-) > > > secondly: > fake a textbox using a label by putting a plain border and changing > background colour. You can set the label value but it won't accept focus. This could work in some cases, but I have read only fields that under certain conditions are no longer read only but input. But for the forms where this is not the case this might even work better. Anyway, problem solved :-) Thanks, Willy From fabianfloresvadell at ...626... Sat Feb 11 15:29:49 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Sat, 11 Feb 2012 11:29:49 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: <4F36237C.5070005@...1...> References: <4F36237C.5070005@...1...> Message-ID: 2012/2/11 Beno?t Minisini > Le 11/02/2012 00:33, Fabi?n Flores Vadell a ?crit : > > > > That problem could be described as "How to add methods from a helper > object > > without have to rewrite a wrapper for each method (with just a call > within) > > in the host class?". > > > > Why don't you want to write wrappers? Is it just because it is boring? > Oh. Well, this is a very important reason. When I say "boring", I mean distracting. Yes, when you get bored, you get distracted. When is needed to do a task like this, what you are doing is get down the level of abstraction of your thoughts (when I do this, my brain is complaining). In fact this is one of the benefits of the OOP. The software is implemented in the same terms from the problema domain, and one outcome is the possibility to avoid jumping from an abstract level of reasoning (of the domain) to a minor level (of the solution). So keep an high level of abstraction when you write the code is a great advantage in productivity. But, there's other very important reason (very close related). The code is written one time, rewrited a few times, but is readed hundred times, perhaps. So, a code more concise (but not least expressive), and as consequence easily to understand, is more easily to test and to modify. So it helps a lot to increase the programmer productivity. So, I think that Gambas could have a feature to do this much more easily. A method, in gb maybe, to do something like this: 'MyClass $Collaborator1 AS HelperClass1 $Collaborator2 AS HelperClass2 'Then: AddToInterface($Collaborator1.AMethod, $Collaborator1.AProperty, $Collaborator2.AMethod, $Collaborator2.AProperty) and voil?, this methods are now accesible directly from MyClass instances. But, perhaps, could be easy enough to do this just using some existing features of Gambas, and convey it as a design pattern. I trying to intercept the calls to the methods, using the _unknown special method, because the calls would be simplified. If it works, The remaining issue would be how to simplify passing arguments. From fabianfloresvadell at ...626... Sat Feb 11 16:22:19 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Sat, 11 Feb 2012 12:22:19 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: <1328945763.24666.19.camel@...2688...> References: <1328945763.24666.19.camel@...2688...> Message-ID: 2012/2/11 Bruce Bruen > > Interesting, I have a similar problem, perhaps the same but maybe > slightly different. > > I have a base class that is CREATE PRIVATE, it cannot be instantiated > directly by a client application. It contains various methods that must > be available to it's child classes (which CAN be instantiated) and can > be called by the client application. For example, DBAdd is public in > the base class so that the child class can call it. > > What I have done, with some success is as follows: > > In the base class I inspect the System.Backtrace and compare the object > indicated by the second item (i.e. System.Backtrace[1]) to see that it > "IS" a Me. (is that clear, if not I'll have to go find the code?) > IOW I check that the caller object is an instance of Me, which can only > be the base class itself or a class that inherits the base class. If > not, I just raise an "Illegal Call" error. > I don't undertand what is the problem that you are intending to solve. You declare your class as PRIVATE, hence just instances from its subclasses can call the methods on the base class. So, allways the inmediate caller would be a method of an instance of a its subclass. > This works within reason, however it has the following drawbacks: > b) it does not prevent a client application from instantiating an object > that inherits directly from the base class. > Why you want to avoid that a client application can instantiate a subclass of the its private superclass? Anyway, don't you can do it making the subclass private too? > To expand this further. I also have examples where I need (read "want") > to have methods in the base class that MUST be overridden in the > specialised child classes. This is because these methods are templates > only. However, they must be present in the base class, as the base class > calls these methods! IOW the base class calls "SomeMethod", which my > design says "must be implemented in the child class". Gambas is > (almost) great at achieving this by its' use of virtual dispatch. If the > child class has correctly overridden the base class method, then that is > the one that is called. And in the base class, I can have a "stub" > method that simply raises an error. If the child class does not > override the method the the error is raised. > Seems to me that you don't need do this if you are programming alone or with your team, because you easily can convey the need to redefine some methods. I can see the need for do that only when you are writing an object library or a generic component, that will be used for unknown programmers (clients). > But hope this helps. Thanks, Bruce. In my case this don't help because the problem that I intend to solve, is present only when to use inheritance is not reasonable. -- Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From fabianfloresvadell at ...626... Sat Feb 11 17:09:20 2012 From: fabianfloresvadell at ...626... (=?ISO-8859-1?Q?Fabi=E1n_Flores_Vadell?=) Date: Sat, 11 Feb 2012 13:09:20 -0300 Subject: [Gambas-user] Gambas bug? In-Reply-To: <1328945763.24666.19.camel@...2688...> References: <1328945763.24666.19.camel@...2688...> Message-ID: 2012/2/11 Bruce Bruen > I have a base class that is CREATE PRIVATE, it cannot be instantiated > directly by a client application. It contains various methods that must > be available to it's child classes (which CAN be instantiated) and can > be called by the client application. For example, DBAdd is public in > the base class so that the child class can call it. > > What I have done, with some success is as follows: > > In the base class I inspect the System.Backtrace and compare the object > indicated by the second item (i.e. System.Backtrace[1]) to see that it > "IS" a Me. (is that clear, if not I'll have to go find the code?) > IOW I check that the caller object is an instance of Me, which can only > be the base class itself or a class that inherits the base class. If > not, I just raise an "Illegal Call" error. > > This works within reason, however it has the following drawbacks: > a) there is obviously an overhead involved in the check code > b) it does not prevent a client application from instantiating an object > that inherits directly from the base class. > So it goes. > > To expand this further. I also have examples where I need (read "want") > to have methods in the base class that MUST be overridden in the > specialised child classes. This is because these methods are templates > only. However, they must be present in the base class, as the base class > calls these methods! IOW the base class calls "SomeMethod", which my > design says "must be implemented in the child class". Gambas is > (almost) great at achieving this by its' use of virtual dispatch. If the > child class has correctly overridden the base class method, then that is > the one that is called. And in the base class, I can have a "stub" > method that simply raises an error. If the child class does not > override the method the the error is raised. > > I would love to be able to solve problem b) above. > I catch it now.(I think). You want something like Friendly in C++. Right? I dont like Friendly, in order to avoid the temptation of break the encapsulation. But that would be a good feature to add for the reflexive skills of Gambas. -- Fabi?n Flores Vadell www.comoprogramarcongambas.blogspot.com www.speedbooksargentina.blogspot.com From john.aaron.rose at ...626... Sun Feb 12 20:23:45 2012 From: john.aaron.rose at ...626... (John Rose) Date: Sun, 12 Feb 2012 19:23:45 +0000 Subject: [Gambas-user] iRecorder new version Message-ID: <1329074625.3375.9.camel@...2661...> New version of iRecorder is at http://dl.dropbox.com/u/3928731/irecorder_0.0.49-1_all.deb It fixes some bugs and allows playing of programme. From john.aaron.rose at ...626... Sun Feb 12 20:30:14 2012 From: john.aaron.rose at ...626... (John Rose) Date: Sun, 12 Feb 2012 19:30:14 +0000 Subject: [Gambas-user] Gambas3 Runtime Message-ID: <1329075014.3375.13.camel@...2661...> I've compiled & installed revision #4445 of Gambas3. However, I have no access to package gambas3-runtimesince I no longer access kendek's ppa for Gambas3 due to clashes of it & #4445. How can I get the gambas3-runtime package installed? From gambas at ...2524... Sun Feb 12 20:34:39 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sun, 12 Feb 2012 19:34:39 +0000 Subject: [Gambas-user] Issue 209 in gambas: Inheritance and translatable constant strings does not work In-Reply-To: <0-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> References: <0-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> Message-ID: <1-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> Updates: Status: Accepted Labels: -Version Version-TRUNK Comment #1 on issue 209 by benoit.m... at ...626...: Inheritance and translatable constant strings does not work http://code.google.com/p/gambas/issues/detail?id=209 (No comment was entered for this change.) From gambas at ...2524... Sun Feb 12 20:48:42 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sun, 12 Feb 2012 19:48:42 +0000 Subject: [Gambas-user] Issue 210 in gambas: For Each corrupts the stack Message-ID: <0-6813199134517018827-9037574029866743255-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 210 by emil.len... at ...626...: For Each corrupts the stack http://code.google.com/p/gambas/issues/detail?id=210 1) Describe the problem. When something stops an enumeration, the stack is very likely to get corrupted. 2) GIVE THE FOLLOWING INFORMATIONS (if they are appropriate): Version: TRUNK 3) Provide a little project that reproduces the bug or the crash. Public Sub Main() Dim i As Integer Dim j As Integer Dim e As New Collection For i = 1 To 2 e["hello"] = 1 For Each j In e e.Clear() Next Next End The interpreter crashes with a segmentation fault because the stack is popped when there isn't anything to pop off. I think it can be fixed by moving if (drop || cenum->stop) POP(); to the inside of the if-statement above in gbx_exec_enum.c. From gambas at ...2524... Sun Feb 12 20:54:44 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sun, 12 Feb 2012 19:54:44 +0000 Subject: [Gambas-user] Issue 209 in gambas: Inheritance and translatable constant strings does not work In-Reply-To: <1-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> References: <1-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> <0-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> Message-ID: <2-6813199134517018827-8470412964939676908-gambas=googlecode.com@...2524...> Updates: Status: Fixed Comment #2 on issue 209 by benoit.m... at ...626...: Inheritance and translatable constant strings does not work http://code.google.com/p/gambas/issues/detail?id=209 Fixed in revision #4473. From gambas at ...2524... Sun Feb 12 22:39:05 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sun, 12 Feb 2012 21:39:05 +0000 Subject: [Gambas-user] Issue 210 in gambas: For Each corrupts the stack In-Reply-To: <0-6813199134517018827-9037574029866743255-gambas=googlecode.com@...2524...> References: <0-6813199134517018827-9037574029866743255-gambas=googlecode.com@...2524...> Message-ID: <1-6813199134517018827-9037574029866743255-gambas=googlecode.com@...2524...> Updates: Status: Fixed Labels: -Version Version-TRUNK Comment #1 on issue 210 by benoit.m... at ...626...: For Each corrupts the stack http://code.google.com/p/gambas/issues/detail?id=210 OK. Fixed in revision #4474. From jussi.lahtinen at ...626... Sun Feb 12 22:40:30 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 12 Feb 2012 23:40:30 +0200 Subject: [Gambas-user] Gambas3 Runtime In-Reply-To: <1329075014.3375.13.camel@...2661...> References: <1329075014.3375.13.camel@...2661...> Message-ID: I've compiled & installed revision #4445 of Gambas3. So, you have installed whole Gambas3... However, I have no > access to package gambas3-runtimesince I no longer access kendek's ppa > for Gambas3 due to clashes of it & #4445. How can I get the > gambas3-runtime package installed? > ...and you want to install some components of Gambas3? Maybe I have missed something, but what is in that package you are missing? There shouldn't be any. Jussi From gambas at ...2524... Mon Feb 13 01:02:31 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Mon, 13 Feb 2012 00:02:31 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <5-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <5-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <6-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Updates: Status: Fixed Comment #6 on issue 123 by benoit.m... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 Here is a fix in revision #4475: Now project that will be used as libraries define their requirements exactly like components (the "project is a component or a library" option must be checked in the project property dialog). Then the IDE takes these requirements into account when adding a library in the project property dialog, exactly like components. Tell me if it fits your needs. From gambas at ...2524... Mon Feb 13 01:06:32 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Mon, 13 Feb 2012 00:06:32 +0000 Subject: [Gambas-user] Issue 32 in gambas: closing form raises signal 11 In-Reply-To: <4-6813199134517018827-11077518654295071856-gambas=googlecode.com@...2524...> References: <4-6813199134517018827-11077518654295071856-gambas=googlecode.com@...2524...> <0-6813199134517018827-11077518654295071856-gambas=googlecode.com@...2524...> Message-ID: <5-6813199134517018827-11077518654295071856-gambas=googlecode.com@...2524...> Updates: Status: WontFix Comment #5 on issue 32 by benoit.m... at ...626...: closing form raises signal 11 http://code.google.com/p/gambas/issues/detail?id=32 No news for a year, closing the issue. From nando_f at ...951... Mon Feb 13 05:53:39 2012 From: nando_f at ...951... (nando) Date: Sun, 12 Feb 2012 23:53:39 -0500 Subject: [Gambas-user] Class Constructor private var questions Message-ID: <20120213044636.M93973@...951...> I wanted to verify that.. example: I have a class called 'X' with a private variable PRIVATE my_int AS INTEGER = -14 PUBLIC SUB _NEW() '===constructor=== my_int = -15 END Questions: 1) The =-14 act as a constructor automatically for a _NEW instantiation? 2) The =-15 occur as a manual explicit contructor...and is unnecessary? 3) The _NEW() executes after the =-14 is assigned to the new private? From john.aaron.rose at ...626... Mon Feb 13 10:19:47 2012 From: john.aaron.rose at ...626... (John Rose) Date: Mon, 13 Feb 2012 09:19:47 +0000 Subject: [Gambas-user] Gambas3 Runtime Message-ID: I want to be able to run the gambas app on another machine. Even though I have installed gambas3-runtime (version 3.0.0~lucid1) package from kendek's ppa, the deb installer says 'Error: Dependency is not satisfiable: gambas3-runtime (>= 3.0.0)'. From gambas at ...2524... Mon Feb 13 14:54:25 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Mon, 13 Feb 2012 13:54:25 +0000 Subject: [Gambas-user] Issue 211 in gambas: Gridview multiselect Message-ID: <0-6813199134517018827-15707643296586879195-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 211 by albefo... at ...152...: Gridview multiselect http://code.google.com/p/gambas/issues/detail?id=211 1) Describe the problem. i cant deselect a row when multiple row are selected 2) GIVE THE FOLLOWING INFORMATIONS (if they are appropriate): Version: 3.0.90 Operating system: Linux Distribution: Debian Squeeze 2.6.39-bkp Architecture: amd64 GUI component: QT4 e GTK Desktop used: KDE 3) Provide a little project that reproduces the bug or the crash. it's no depend by the code, is the component gridview 5) Explain clearly how to reproduce the bug or the crash. click on a row with ctrl presser cause multiple row selection (thats good!) further click on already selected row should deselect it, but the row remain selected From ybadamasi at ...626... Mon Feb 13 16:28:45 2012 From: ybadamasi at ...626... (Yunusa Badamasi) Date: Mon, 13 Feb 2012 16:28:45 +0100 Subject: [Gambas-user] Issue 207 in gambas: Event Save get error at DataBrowser In-Reply-To: <0-6813199134517018827-3591540882422464748-gambas=googlecode.com@...2524...> References: <0-6813199134517018827-3591540882422464748-gambas=googlecode.com@...2524...> Message-ID: On Wed, Feb 8, 2012 at 10:36 AM, wrote: > Status: New > Owner: ---- > Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any > Desktop-Any GUI-Any > > New issue 207 by bespalov... at ...626...: Event Save get error at > DataBrowser > http://code.google.com/p/gambas/issues/detail?id=207 > > If i open table in DataBrowser and press Save, i get error box "Cannot > modify record: SQL error or missing database". > > I can add or delete item at DataBrowser no problem. > > I think it try save to database empty line in DataBrowser. > > [System] > OperatingSystem=Linux > Kernel=3.2.3-2.fc16.i686 > Architecture=i686 > Memory=2061988 kB > DistributionVendor=redhat > DistributionRelease=RFRemix release 16 (Verne) > Desktop=Gnome > > [Gambas 3] > Version=3.0.0 > Path=/usr/bin/gbx3 > > [Libraries] > Qt4=libQtCore.so.4.8.0 > GTK+=libgtk-x11-2.0.so.0.2400.8 > > > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From john.aaron.rose at ...626... Mon Feb 13 18:35:46 2012 From: john.aaron.rose at ...626... (John Rose) Date: Mon, 13 Feb 2012 17:35:46 +0000 Subject: [Gambas-user] Gambas3 Runtime Message-ID: <1329154546.4340.5.camel@...2661...> I thought I'd try my dev pc again to see if I could install my Gambas3 app there. Because I compiled Gambas3 (on Ubuntu Lucid), it installed to /usr/local/bin whereas installing packages results in install to /usr/bin. So I copied gbr3 & gbx3 from /usr/local/bin to /usr/bin. But I still got the same error message. From gambas at ...1... Mon Feb 13 19:25:28 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 13 Feb 2012 19:25:28 +0100 Subject: [Gambas-user] Gambas3 Runtime In-Reply-To: References: Message-ID: <4F395598.7030008@...1...> Le 13/02/2012 10:19, John Rose a ?crit : > I want to be able to run the gambas app on another machine. Even > though I have installed gambas3-runtime (version 3.0.0~lucid1) package > from kendek's ppa, the deb installer says 'Error: Dependency is not > satisfiable: gambas3-runtime (>= 3.0.0)'. > Can you send me the package you have created? -- Beno?t Minisini From john.aaron.rose at ...626... Mon Feb 13 19:34:33 2012 From: john.aaron.rose at ...626... (John Rose) Date: Mon, 13 Feb 2012 18:34:33 +0000 Subject: [Gambas-user] Gambas3 Runtime Message-ID: <1329158073.4340.8.camel@...2661...> Deb package for my app attached. Also, the app's source. -------------- next part -------------- A non-text attachment was scrubbed... Name: irecorder_0.0.49-1_all.deb Type: application/x-deb Size: 19626 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: iRecorder.tar.gz Type: application/x-compressed-tar Size: 26428 bytes Desc: not available URL: From emil.lenngren at ...626... Mon Feb 13 22:28:04 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Mon, 13 Feb 2012 22:28:04 +0100 Subject: [Gambas-user] Class Constructor private var questions In-Reply-To: <20120213044636.M93973@...951...> References: <20120213044636.M93973@...951...> Message-ID: 2) The _new method is optional. 3) All instance variable assignments written at the declarations are done before the _new method is executed. 1) These asignments are actually done in a special generated hidden method called $new (which is executed before _new). /Emil 2012/2/13 nando > I wanted to verify that.. > > > example: > I have a class called 'X' with a private variable > > > PRIVATE my_int AS INTEGER = -14 > > > PUBLIC SUB _NEW() '===constructor=== > > my_int = -15 > > END > > > Questions: > 1) The =-14 act as a constructor automatically for a _NEW instantiation? > 2) The =-15 occur as a manual explicit contructor...and is unnecessary? > 3) The _NEW() executes after the =-14 is assigned to the new private? > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From zachsmith022 at ...626... Tue Feb 14 01:21:04 2012 From: zachsmith022 at ...626... (Zach Smith) Date: Mon, 13 Feb 2012 18:21:04 -0600 Subject: [Gambas-user] gb.GeneralDate formatting is inconsistent In-Reply-To: <4F3628F6.7090800@...1...> References: <4F2E326C.8040201@...1...> <4F2E390E.1070408@...1...> <4F3628F6.7090800@...1...> Message-ID: It works as expected. Thanks Benoit. The comment at http://gambasdoc.org/help/cat/constant should be revised where it says: gb.GeneralDate Write a date only if the date and time value has a date part, and write a time only if it has a date part. From gambas at ...2524... Tue Feb 14 13:54:12 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 14 Feb 2012 12:54:12 +0000 Subject: [Gambas-user] Issue 212 in gambas: Gambas3 is generating packages with dependencies gambas2 Message-ID: <0-6813199134517018827-17266133497799151102-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 212 by flynetin... at ...626...: Gambas3 is generating packages with dependencies gambas2 http://code.google.com/p/gambas/issues/detail?id=212 1) When i create installation package, generates with dependencies gambas2. 2) Version: TRUNK 3.0 Revision: Operating system: Linux / FreeBSD Distribution: Ubuntu 11.10 Architecture: x86 GUI component: QT4 / GTK+ Desktop used: Gnome From gambas at ...2524... Tue Feb 14 14:03:16 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 14 Feb 2012 13:03:16 +0000 Subject: [Gambas-user] Issue 212 in gambas: Gambas3 is generating packages with dependencies gambas2 In-Reply-To: <0-6813199134517018827-17266133497799151102-gambas=googlecode.com@...2524...> References: <0-6813199134517018827-17266133497799151102-gambas=googlecode.com@...2524...> Message-ID: <1-6813199134517018827-17266133497799151102-gambas=googlecode.com@...2524...> Comment #1 on issue 212 by flynetin... at ...626...: Gambas3 is generating packages with dependencies gambas2 http://code.google.com/p/gambas/issues/detail?id=212 Sorry. Forget that installation packages are generated for debian or ubuntu. Then when trying to install the package can not satisfy dependencies From gambas at ...2524... Wed Feb 15 00:00:38 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 14 Feb 2012 23:00:38 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <6-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <6-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <7-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Comment #7 on issue 123 by adamn... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 Seemed OK for a few days but now I'm getting two problems with one project. It uses 4 libraries and 1 local component. When this project is first opened, the IDE displays an error "CComponent.Load.453 Not an object". This occurs with the line: All[sLig].Load where sLig="webaccess3.gambas,phApplication3.gambas,horseBO.gambas,phDB9a.gambas" being the only item in Require[] (i.e. hLibraryInfo.Require). Execution then falls straight to the Finally/Catch clauses. Clicking OK, brings up the project, but... If I try and open the project properties form, then at line 376 of FPropertyProject.RefreshComponents: $cComp[sDep].Check(sLib) where sLib="/share/projects/gambas3_proj/horse/datasources/racepages/racepages.gambas" and sDep="webaccess3.gambas,phApplication3.gambas,horseBO.gambas,phDB9a.gambas" Here, $cComp[sDep] is null and another "Not an object" error occurs. (By the way, when running the IDE normally, at this point it crashes with the "A fatal error...) Points to note: 1) using build 4477 2) most of these libraries are used in various combinations in other projects without a problem. 3) all the libraries other than "racepages" has declared dependencies that include other libraries. 4) if I remove ALL the required dependencies from the racepages Component properties then the error does not occur. Thoughts: 1) I think this is a bug as the IDE just reports the "Not an object" error that refers to it's own code (not the loaded project code) and crashes when the project properties form is opened. 2) Do you expect the hLibInfo.Require to be a comma delimited string? I don't know but it looks a bit weird to me. cheers Bruce p.s. If you need to see the project, it will take me some time to develop a demo. The real projects are very large. Here is some info about them phApplication3 : 500 LOC. Components: gb.gb.db,gb.form,gb.gui,gb.image,gb.settings Libraries: None Component-Requires:gb.db, gb.form,gb.gui,gb.imagegb.settings phDB9a : 1427 LOC. Components: gb,gb.db,gb.settings Libraries: phApplication3 Component-Requires: gb.db, gb.settings, phApplication3 horseBO : 3398 LOC. Components: gb,gb.db Libraries: phApplication3, phDB9a Component-Requires: phDB9a webaccess3: 172 LOC, Components: gb,gb.net,gb.net.curl Libraries: None Component-Requires: gb.net, gb.net.curl horsepages: 5364 LOC. Components: gb,gb.db,gb.db.form,gb.form,gb.gui,gb.image,gb.net,gb.net.curl,gb.settings Libraries: webaccess3,phApplication3,phDB9a,horseBO Component-Requires: Currently NONE (so the current application can work) From bespalov.av at ...626... Wed Feb 15 11:38:15 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Wed, 15 Feb 2012 16:38:15 +0600 Subject: [Gambas-user] What is measured by "Angle"? Message-ID: Hi! What is measured by "Angle"? in Image.Rotate(Angle) Thank you. From math.eber at ...221... Wed Feb 15 19:48:46 2012 From: math.eber at ...221... (Matti) Date: Wed, 15 Feb 2012 19:48:46 +0100 Subject: [Gambas-user] What is measured by "Angle"? In-Reply-To: References: Message-ID: <4F3BFE0E.8090105@...221...> The angle has to be given in radians. So, to rotate 90?, you have to do: hImg = hImg.Rotate(Rad(90)) Am 15.02.2012 11:38, schrieb ??????? ????????: > Hi! > What is measured by "Angle"? > in > Image.Rotate(Angle) > > Thank you. From vuott at ...325... Wed Feb 15 22:05:47 2012 From: vuott at ...325... (Ru Vuott) Date: Wed, 15 Feb 2012 21:05:47 +0000 (GMT) Subject: [Gambas-user] What is measured by "Angle"? In-Reply-To: <4F3BFE0E.8090105@...221...> Message-ID: <1329339947.55157.YahooMailClassic@...2758...> > So, to rotate 90?, you have to do: > hImg = hImg.Rotate(Rad(90)) ...I noticed that I can rotate an "image" by: hImg = hImg.Rotate(Pi(0.5)) and simply: hImg = hImg.Rotate(1.58) Example: Public Sub button2_Click() Dim i As Image Dim p As Picture i = Image.Load("/iter/mea_immago.gif") i = i.Rotate(1.58) '...or .Rotate(Pi(0.5)) p = i.picture PictureBox1.Picture = p End From math.eber at ...221... Wed Feb 15 22:21:06 2012 From: math.eber at ...221... (Matti) Date: Wed, 15 Feb 2012 22:21:06 +0100 Subject: [Gambas-user] What is measured by "Angle"? In-Reply-To: <1329339947.55157.YahooMailClassic@...2758...> References: <1329339947.55157.YahooMailClassic@...2758...> Message-ID: <4F3C21C2.5030604@...221...> Yes, of course, if you know the radians, it is easy, and you can just enter the Float. But if you have a user input that usually is in degrees, you have to convert it via Rad(). It is just a matter of what input you get. Am 15.02.2012 22:05, schrieb Ru Vuott: > >> So, to rotate 90?, you have to do: >> hImg = hImg.Rotate(Rad(90)) > > ...I noticed that I can rotate an "image" by: > hImg = hImg.Rotate(Pi(0.5)) > > and simply: > > hImg = hImg.Rotate(1.58) > > > > Example: > > Public Sub button2_Click() > > Dim i As Image > Dim p As Picture > > i = Image.Load("/iter/mea_immago.gif") > > i = i.Rotate(1.58) '...or .Rotate(Pi(0.5)) > > p = i.picture > > PictureBox1.Picture = p > > End > From sebikul at ...626... Thu Feb 16 20:04:24 2012 From: sebikul at ...626... (Sebastian Kulesz) Date: Thu, 16 Feb 2012 16:04:24 -0300 Subject: [Gambas-user] Archlinux package creation Message-ID: Hi. I'm having trouble creating an Archlinux installation package. It seems to create it successfully, but when i check the destination folder it's empty and there is no PKGBUILD file. Can somebody reproduce this? Thanks! From rmorgan62 at ...626... Thu Feb 16 21:46:10 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Thu, 16 Feb 2012 12:46:10 -0800 Subject: [Gambas-user] When to use GB.NewArray or GB.Array.New Message-ID: Hi, I am experimenting with arrays in C components. I have looked at the documentation on arrays and see that there are two types of arrays. It looks like GB.NewArray simply reserves memory and GB.Array.New creates a new GAMBAS array object. My question is: When is it appropriate to use each of these types. To me it seems that GB>NewArray would be used only for temporary memory allocation as in a function and therefore should be freed with GB.FreeArray before exiting the function. Also, that GB.ArrayNew would be used anytime you need a persistent array such as returning an array object or using the array as a class member/property. Is this correct? Thanks for the clarification! -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From bbruen at ...2308... Thu Feb 16 23:59:55 2012 From: bbruen at ...2308... (Bruce Bruen) Date: Fri, 17 Feb 2012 09:29:55 +1030 Subject: [Gambas-user] Expander control - two questions Message-ID: <1329433195.26010.14.camel@...2688...> Hi folks, 1) Is it possible to change the height of the header of the expander, i.e. the bit that remains visible when it is collapsed? At the moment, it is too high for one line and too short for two. 2) Is it possible to change the height of the expanded view depending on the size of its' contents, when the contents are a "view" control? I would like to use the expander as a fancy combo box, with a tableview inside it, listing selections in some detail and when a selection is made, then showing a summary of the selected row in the tableview. I have attached a mock-up of what I am trying to do. regards Bruce -------------- next part -------------- A non-text attachment was scrubbed... Name: formpagelayout-0.0.1.tar.gz Type: application/x-compressed-tar Size: 5874 bytes Desc: not available URL: From bespalov.av at ...626... Fri Feb 17 05:41:55 2012 From: bespalov.av at ...626... (=?KOI8-R?B?4czFy9PFyiDixdPQwczP1w==?=) Date: Fri, 17 Feb 2012 10:41:55 +0600 Subject: [Gambas-user] Archlinux package creation In-Reply-To: References: Message-ID: For Archlinux, I think it may simply take the source tar.gz file and write the most pkbuild. 2012/2/17 Sebastian Kulesz > Hi. I'm having trouble creating an Archlinux installation package. It > seems to create it successfully, but when i check the destination > folder it's empty and there is no PKGBUILD file. Can somebody > reproduce this? > > Thanks! > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- ____ ? ????????? ???????. From kevinfishburne at ...1887... Fri Feb 17 06:08:27 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Fri, 17 Feb 2012 00:08:27 -0500 Subject: [Gambas-user] angle interpolation algorithm troubles Message-ID: <4F3DE0CB.9060704@...1887...> Apparently I'm too much of a dummy to figure this out. I have two singles representing orientation in degrees, let's say Angle1 and Angle2. I need to continually increment one (let's say Angle1) until it's close to the value of the other (Angle2), but in the direction of the shortest distance between the two angles. So if Angle1 = 10 and Angle2 = 350, Angle1 should be repeatedly decremented, wrapping around the upper limit of 360 (10, 5, 0, 355, 350). If Angle1 was 350 and Angle2 was 20, Angle1 would be incremented like 350, 355, 0, 5, 10, 15, 20. I have a crude function to wrap a number which may be of use: Public Function Wrap_Single(Minimum As Single, Maximum As Single, Value As Single) As Single ' Constrain value to specified range. ' General declarations. Dim Spread As Single = Maximum - Minimum + 1 ' Range between minimum and maximum values. ' Wrap if value is too large. If Value > Maximum Then Do Value = Value - Spread Loop Until Value <= Maximum Endif ' Wrap if value is too small. If Value < Minimum Then Do Value = Value + Spread Loop Until Value >= Minimum Endif ' Return wrapped value. Return Value End This is my current code, which works except the Distance variable isn't doing its job: ' Check if camera orientation is locked to client player orientation. If Camera.Locked Then ' Check if difference in orientations exceeds interpolation threshold. Distance = Abs(Camera.Orientation - Client.Player[Client.Number].Orientation) If Distance >= 5.625 Then ' Move camera orientation closer to player orientation (interpolate). If Camera.Orientation - Client.Player[Client.Number].Orientation < Client.Player[Client.Number].Orientation - Camera.Orientation Then Camera.Orientation = Convert.Wrap_Single(0, 359, Camera.Orientation + 0.1 * Distance) Else Camera.Orientation = Convert.Wrap_Single(0, 359, Camera.Orientation - 0.1 * Distance) Endif Endif Endif My instinct tells me I'm almost there but am missing one critical thing. If someone smarter than myself instantly sees my mistake please let me know. :) -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From rmorgan62 at ...626... Fri Feb 17 07:11:25 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Thu, 16 Feb 2012 22:11:25 -0800 Subject: [Gambas-user] angle interpolation algorithm troubles In-Reply-To: <4F3DE0CB.9060704@...1887...> References: <4F3DE0CB.9060704@...1887...> Message-ID: Try a little conditional: if abs(a1 - a2) > 180 then rotate counter clockwise else rotate clockwise I think this will work try it and see... On Thu, Feb 16, 2012 at 9:08 PM, Kevin Fishburne < kevinfishburne at ...1887...> wrote: > Apparently I'm too much of a dummy to figure this out. I have two > singles representing orientation in degrees, let's say Angle1 and > Angle2. I need to continually increment one (let's say Angle1) until > it's close to the value of the other (Angle2), but in the direction of > the shortest distance between the two angles. > > So if Angle1 = 10 and Angle2 = 350, Angle1 should be repeatedly > decremented, wrapping around the upper limit of 360 (10, 5, 0, 355, > 350). If Angle1 was 350 and Angle2 was 20, Angle1 would be incremented > like 350, 355, 0, 5, 10, 15, 20. I have a crude function to wrap a > number which may be of use: > > Public Function Wrap_Single(Minimum As Single, Maximum As Single, Value > As Single) As Single > > ' Constrain value to specified range. > > ' General declarations. > Dim Spread As Single = Maximum - Minimum + 1 ' Range between minimum > and maximum values. > > ' Wrap if value is too large. > If Value > Maximum Then > Do > Value = Value - Spread > Loop Until Value <= Maximum > Endif > > ' Wrap if value is too small. > If Value < Minimum Then > Do > Value = Value + Spread > Loop Until Value >= Minimum > Endif > > ' Return wrapped value. > Return Value > > End > > This is my current code, which works except the Distance variable isn't > doing its job: > > ' Check if camera orientation is locked to client player orientation. > If Camera.Locked Then > ' Check if difference in orientations exceeds interpolation threshold. > Distance = Abs(Camera.Orientation - > Client.Player[Client.Number].Orientation) > If Distance >= 5.625 Then > ' Move camera orientation closer to player orientation (interpolate). > If Camera.Orientation - Client.Player[Client.Number].Orientation < > Client.Player[Client.Number].Orientation - Camera.Orientation Then > Camera.Orientation = Convert.Wrap_Single(0, 359, > Camera.Orientation + 0.1 * Distance) > Else > Camera.Orientation = Convert.Wrap_Single(0, 359, > Camera.Orientation - 0.1 * Distance) > Endif > Endif > Endif > > My instinct tells me I'm almost there but am missing one critical thing. > If someone smarter than myself instantly sees my mistake please let me > know. :) > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From kevinfishburne at ...1887... Fri Feb 17 07:52:12 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Fri, 17 Feb 2012 01:52:12 -0500 Subject: [Gambas-user] angle interpolation algorithm troubles In-Reply-To: References: <4F3DE0CB.9060704@...1887...> Message-ID: <4F3DF91C.7050800@...1887...> On 02/17/2012 01:11 AM, Randall Morgan wrote: > Try a little conditional: > > if abs(a1 - a2)> 180 then rotate counter clockwise > else rotate clockwise > > I think this will work try it and see... Thou art a genius. :) I used your suggestion along with this site: http://www.kirupa.com/forum/showthread.php?63633-shortest-distance-between-two-angles and came up with: ' Check if camera orientation is locked to client player orientation. If Camera.Locked Then ' Move camera orientation closer to player orientation (interpolate). Distance = Convert.Wrap_Single(0, 359, Abs(Camera.Orientation - Client.Player[Client.Number].Orientation)) If Distance > 180 Then Distance = 360 - Distance If Abs(Convert.Wrap_Single(0, 359, Camera.Orientation - Client.Player[Client.Number].Orientation)) > 180 Then Camera.Orientation = Convert.Wrap_Single(0, 359, Camera.Orientation + 0.1 * Distance) Else Camera.Orientation = Convert.Wrap_Single(0, 359, Camera.Orientation - 0.1 * Distance) Endif Endif It works brilliantly. Muchas gracias and domo arigato. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From rmorgan62 at ...626... Fri Feb 17 08:23:02 2012 From: rmorgan62 at ...626... (Randall Morgan) Date: Thu, 16 Feb 2012 23:23:02 -0800 Subject: [Gambas-user] angle interpolation algorithm troubles In-Reply-To: <4F3DF91C.7050800@...1887...> References: <4F3DE0CB.9060704@...1887...> <4F3DF91C.7050800@...1887...> Message-ID: My Game programming days go back to DOS and WinG and the last thing I worked on was using DirectX 6 and it was brand new then. Much has changed since then. Even C and C++ and the coding styles used now are completely different. So I am glad this old man could help! On Thu, Feb 16, 2012 at 10:52 PM, Kevin Fishburne < kevinfishburne at ...1887...> wrote: > On 02/17/2012 01:11 AM, Randall Morgan wrote: > > Try a little conditional: > > > > if abs(a1 - a2)> 180 then rotate counter clockwise > > else rotate clockwise > > > > I think this will work try it and see... > > Thou art a genius. :) I used your suggestion along with this site: > > > http://www.kirupa.com/forum/showthread.php?63633-shortest-distance-between-two-angles > > and came up with: > > ' Check if camera orientation is locked to client player orientation. > If Camera.Locked Then > ' Move camera orientation closer to player orientation (interpolate). > Distance = Convert.Wrap_Single(0, 359, Abs(Camera.Orientation - > Client.Player[Client.Number].Orientation)) > If Distance > 180 Then Distance = 360 - Distance > If Abs(Convert.Wrap_Single(0, 359, Camera.Orientation - > Client.Player[Client.Number].Orientation)) > 180 Then > Camera.Orientation = Convert.Wrap_Single(0, 359, Camera.Orientation > + 0.1 * Distance) > Else > Camera.Orientation = Convert.Wrap_Single(0, 359, Camera.Orientation > - 0.1 * Distance) > Endif > Endif > > It works brilliantly. Muchas gracias and domo arigato. > > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- If you ask me if it can be done. The answer is YES, it can always be done. The correct questions however are... What will it cost, and how long will it take? From kevinfishburne at ...1887... Fri Feb 17 08:45:01 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Fri, 17 Feb 2012 02:45:01 -0500 Subject: [Gambas-user] angle interpolation algorithm troubles In-Reply-To: References: <4F3DE0CB.9060704@...1887...> <4F3DF91C.7050800@...1887...> Message-ID: <4F3E057D.30100@...1887...> On 02/17/2012 02:23 AM, Randall Morgan wrote: > My Game programming days go back to DOS and WinG and the last thing I > worked on was using DirectX 6 and it was brand new then. Much has changed > since then. Even C and C++ and the coding styles used now are completely > different. So I am glad this old man could help! I place more faith in the experienced than college-trained greenhorns any day. Libraries and such may change with the ages, but math remains a constant and by extension useful algorithms. I don't care if you're programming Call of Duty 28 or Pong, some things never change. I got my start in a BASIC dialect for GEM on an Amstrad PC-1512 when I was 13 around 1988. I moved on to GW-BASIC, QBasic, QuickBASIC 4.5 (with Fastgraph Light), Visual Basic 6, and finally GAMBAS 2 and 3. What's really exciting to me is having that long perspective alongside more modern tools such as GAMBAS, as that is a huge advantage over the newly initiated. What I lack in mathematical prowess I make up for in creativity and drive (and helpful GAMBAS users!). -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From lordheavym at ...626... Fri Feb 17 14:47:05 2012 From: lordheavym at ...626... (Laurent Carlier) Date: Fri, 17 Feb 2012 14:47:05 +0100 Subject: [Gambas-user] Archlinux package creation In-Reply-To: References: Message-ID: <189927825.reLyd7f1Ne@...2592...> > Hi. I'm having trouble creating an Archlinux installation package. It > seems to create it successfully, but when i check the destination > folder it's empty and there is no PKGBUILD file. Can somebody > reproduce this? > > Thanks! > I will try to take a look at this soon ++ From john.aaron.rose at ...626... Fri Feb 17 19:03:40 2012 From: john.aaron.rose at ...626... (John Rose) Date: Fri, 17 Feb 2012 18:03:40 +0000 Subject: [Gambas-user] Not able to distribute app created by compiled Gambas3 Message-ID: <1329501820.3050.6.camel@...2661...> After extensive correspondence with kendek,he has agreed that there is an issue re distributing app created by compiled Gambas3. Quoting my last message to him: here is something fundamentally incompatible between the relationship of a compiled version of Gambas3 (from Trunk) and the Gambas3 packages on your ppa. This affects both my dev PC where that was done and another PC when it was not done. After installation of iRecorder.deb on my dev & another PC, neither runs the iRecorder app. The DEB Installer on both PCS causes the download & install of the following packages: gambas3-runtime gambas3 gb-form gambas3-gb-gui gambas3-gb-image gambas3-gb-gtk gambas3-gb-qt4 gambas3-settings I think those installs are correct. However when running the iRecorder app from Ubuntu's menu: the dev PC gives a window stating that "Could not launch 'iRecorder'" and "Failed to execute child process "usr/bin/iRecorder.gambas" (No such file or directory)"; the other PC seems to start the app (i.e. as shown on the task bar) but then stops with no message. His reply was: Indeed, when running the following error message will display: "ERROR: #2: Cannot load class 'FMain': Version too recent. Please upgrade Gambas." Those that are not backwards compatible with this version. You'll have to version 3.0.0 to create the package. But of course, as there will be another official version, I will update the current in a PPA packages. It would be good to know when 3.1 (i.e. next stable) version of Gambas3 will be produced. This would allow him to put it onto his ppa. From sebikul at ...626... Fri Feb 17 21:32:51 2012 From: sebikul at ...626... (Sebastian Kulesz) Date: Fri, 17 Feb 2012 17:32:51 -0300 Subject: [Gambas-user] Unknown symbol in module with variable set Message-ID: Hi. I'm getting an unusual error in a large project when trying to access a property of a module using an initializer to execute custom code in a large set of modules. The simplified code can be seen in the attached project. When executed, it complains about an unknown symbol, but in the stack it's listed. Is this a bug or an error in my code? Tanks! -------------- next part -------------- A non-text attachment was scrubbed... Name: test_project-0.0.1.tar.gz Type: application/x-gzip Size: 5651 bytes Desc: not available URL: From mohareve at ...626... Sat Feb 18 12:48:29 2012 From: mohareve at ...626... (M. Cs.) Date: Sat, 18 Feb 2012 12:48:29 +0100 Subject: [Gambas-user] Questions Message-ID: Hi, I have some questions: 1. Is it possible to set/change the text of panel button. I mean the K3b's panel button(of minimized window) shows the process of writing in %. Is this possible with Gambas? 2. How could I retrieve the result from the following query: MyConn.Exec("SELECT sum(myrow) FROM MyTable;) Csaba From afroehlke at ...784... Sat Feb 18 13:11:23 2012 From: afroehlke at ...784... (=?iso-8859-1?Q?Andreas_Fr=F6hlke?=) Date: Sat, 18 Feb 2012 13:11:23 +0100 Subject: [Gambas-user] Questions In-Reply-To: References: Message-ID: <8D42310D957CFB46AA11921A711D4D16057DB6C193@...1899...> 1. just set the text property of your form 2. DIM REStest as Result REStest = MyConn.Exec("SELECT sum(myrow) FROM MyTable;) FOR EACH REStest PRINT REStest["sum(myrow"] NEXT -----Urspr?ngliche Nachricht----- Von: M. Cs. [mailto:mohareve at ...626...] Gesendet: Samstag, 18. Februar 2012 12:48 An: mailing list for gambas users Betreff: [Gambas-user] Questions Hi, I have some questions: 1. Is it possible to set/change the text of panel button. I mean the K3b's panel button(of minimized window) shows the process of writing in %. Is this possible with Gambas? 2. How could I retrieve the result from the following query: MyConn.Exec("SELECT sum(myrow) FROM MyTable;) Csaba ------------------------------------------------------------------------------ Virtualization & Cloud Management Using Capacity Planning Cloud computing makes use of virtualization - but cloud computing also focuses on allowing computing to be delivered as a service. http://www.accelacomm.com/jaw/sfnl/114/51521223/ _______________________________________________ Gambas-user mailing list Gambas-user at lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user From mohareve at ...626... Sat Feb 18 13:39:11 2012 From: mohareve at ...626... (M. Cs.) Date: Sat, 18 Feb 2012 13:39:11 +0100 Subject: [Gambas-user] Questions In-Reply-To: <8D42310D957CFB46AA11921A711D4D16057DB6C193@...1899...> References: <8D42310D957CFB46AA11921A711D4D16057DB6C193@...1899...> Message-ID: Thanks! 2012/2/18, Andreas Fr?hlke : > 1. just set the text property of your form > > 2. > DIM REStest as Result > > REStest = MyConn.Exec("SELECT sum(myrow) FROM MyTable;) > FOR EACH REStest > PRINT REStest["sum(myrow"] > NEXT > > > > -----Urspr?ngliche Nachricht----- > Von: M. Cs. [mailto:mohareve at ...626...] > Gesendet: Samstag, 18. Februar 2012 12:48 > An: mailing list for gambas users > Betreff: [Gambas-user] Questions > > Hi, I have some questions: > 1. Is it possible to set/change the text of panel button. I mean the > K3b's panel button(of minimized window) shows the process of writing > in %. Is this possible with Gambas? > 2. How could I retrieve the result from the following query: > MyConn.Exec("SELECT sum(myrow) FROM MyTable;) > > Csaba > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From dr.diesel at ...626... Sat Feb 18 19:40:39 2012 From: dr.diesel at ...626... (Dr.Diesel) Date: Sat, 18 Feb 2012 10:40:39 -0800 (PST) Subject: [Gambas-user] Gambas future? Message-ID: <33349105.post@...1379...> Beno?t, please tease us with what the future will bring in 3.1, 3.5 or even 4.0? Thanks -- View this message in context: http://old.nabble.com/Gambas-future--tp33349105p33349105.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Sun Feb 19 02:14:44 2012 From: gambas at ...1... (=?UTF-8?B?QmVub8OudCBNaW5pc2luaQ==?=) Date: Sun, 19 Feb 2012 02:14:44 +0100 Subject: [Gambas-user] Gambas future? In-Reply-To: <33349105.post@...1379...> References: <33349105.post@...1379...> Message-ID: <4F404D04.4030705@...1...> Le 18/02/2012 19:40, Dr.Diesel a ?crit : > > Beno?t, please tease us with what the future will bring in 3.1, 3.5 or even > 4.0? > > Thanks > > There will be a 3.1 version. This 3.1 version will be able to run 3.0 program without recompilation (normally), but 3.1 programs will not run with the 3.0 interpreter. I want to fix the following in 3.1: the IDE packager (as much as possible), the components/libraries dependencies system. Regards, -- Beno?t Minisini From mohareve at ...626... Sun Feb 19 12:08:15 2012 From: mohareve at ...626... (M. Cs.) Date: Sun, 19 Feb 2012 12:08:15 +0100 Subject: [Gambas-user] Gambas future? In-Reply-To: <4F404D04.4030705@...1...> References: <33349105.post@...1379...> <4F404D04.4030705@...1...> Message-ID: Please Benoit, if you have some extra time, update the sdl and sdl-sound libraries as well! Csaba 2012/2/19, Beno?t Minisini : > Le 18/02/2012 19:40, Dr.Diesel a ?crit : >> >> Beno?t, please tease us with what the future will bring in 3.1, 3.5 or >> even >> 4.0? >> >> Thanks >> >> > > There will be a 3.1 version. This 3.1 version will be able to run 3.0 > program without recompilation (normally), but 3.1 programs will not run > with the 3.0 interpreter. I want to fix the following in 3.1: the IDE > packager (as much as possible), the components/libraries dependencies > system. > > Regards, > > -- > Beno?t Minisini > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From bill-lancaster at ...2231... Sun Feb 19 13:13:48 2012 From: bill-lancaster at ...2231... (Bill-Lancaster) Date: Sun, 19 Feb 2012 04:13:48 -0800 (PST) Subject: [Gambas-user] how to indicate progress Message-ID: <33351547.post@...1379...> Gambas 3 I want to run an Exec command when my programme starts. Using the Open or Activate event for the main means that the form doesn't appear until the exec process has finished. How can I indicate that the Exec process is still running? -- View this message in context: http://old.nabble.com/how-to-indicate-progress-tp33351547p33351547.html Sent from the gambas-user mailing list archive at Nabble.com. From linuxos at ...1896... Sun Feb 19 14:14:56 2012 From: linuxos at ...1896... (Olivier Cruilles) Date: Sun, 19 Feb 2012 14:14:56 +0100 Subject: [Gambas-user] how to indicate progress In-Reply-To: <33351547.post@...1379...> References: <33351547.post@...1379...> Message-ID: May be you ca use this one: Application.Busy = 1 and when the Process stops Application.Busy = 0 Olivier Cruilles Mail: linuxos at ...1896... Le 19 f?vr. 2012 ? 13:13, Bill-Lancaster a ?crit : > > Gambas 3 > > I want to run an Exec command when my programme starts. > > Using the Open or Activate event for the main means that the form doesn't > appear until the exec process has finished. > > How can I indicate that the Exec process is still running? > -- > View this message in context: http://old.nabble.com/how-to-indicate-progress-tp33351547p33351547.html > Sent from the gambas-user mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From jussi.lahtinen at ...626... Sun Feb 19 14:22:59 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 19 Feb 2012 15:22:59 +0200 Subject: [Gambas-user] how to indicate progress In-Reply-To: <33351547.post@...1379...> References: <33351547.post@...1379...> Message-ID: http://gambasdoc.org/help/lang/exec?v3 http://gambasdoc.org/help/comp/gb/process?v3 Dim hProcess As Process hProcess = Exec [ ... If hProcess.State = Process.Running Then ... Jussi On Sun, Feb 19, 2012 at 14:13, Bill-Lancaster wrote: > > Gambas 3 > > I want to run an Exec command when my programme starts. > > Using the Open or Activate event for the main means that the form doesn't > appear until the exec process has finished. > > How can I indicate that the Exec process is still running? > -- > View this message in context: > http://old.nabble.com/how-to-indicate-progress-tp33351547p33351547.html > Sent from the gambas-user mailing list archive at Nabble.com. > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From bill-lancaster at ...2231... Sun Feb 19 14:25:54 2012 From: bill-lancaster at ...2231... (Bill-Lancaster) Date: Sun, 19 Feb 2012 05:25:54 -0800 (PST) Subject: [Gambas-user] how to indicate progress In-Reply-To: References: <33351547.post@...1379...> Message-ID: <33351740.post@...1379...> Thanks for the idea.. The exec process runs until finished then the form appears at this point "application.busy = 0" is executed so "application.busy = 1" state is never seen! -- View this message in context: http://old.nabble.com/how-to-indicate-progress-tp33351547p33351740.html Sent from the gambas-user mailing list archive at Nabble.com. From jussi.lahtinen at ...626... Sun Feb 19 14:36:29 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 19 Feb 2012 15:36:29 +0200 Subject: [Gambas-user] how to indicate progress In-Reply-To: <33351740.post@...1379...> References: <33351547.post@...1379...> <33351740.post@...1379...> Message-ID: There is quite good documentation of Gambas. I strongly suggest to look at it. Application.Busy is not indicator of application doing something. It's not automatically adjusted. http://gambasdoc.org/help/comp/gb.qt4/application/busy?v3 Jussi On Sun, Feb 19, 2012 at 15:25, Bill-Lancaster wrote: > > Thanks for the idea.. > > The exec process runs until finished then the form appears at this point > "application.busy = 0" is executed so "application.busy = 1" state is never > seen! > -- > View this message in context: > http://old.nabble.com/how-to-indicate-progress-tp33351547p33351740.html > Sent from the gambas-user mailing list archive at Nabble.com. > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From linuxos at ...1896... Sun Feb 19 14:39:22 2012 From: linuxos at ...1896... (Olivier Cruilles) Date: Sun, 19 Feb 2012 14:39:22 +0100 Subject: [Gambas-user] how to indicate progress In-Reply-To: References: <33351547.post@...1379...> Message-ID: <06A17E62-DBAE-4031-9F00-BCFC21034404@...1896...> So in this case, try to start your application by a module that open your form next and in this module put the command Application.Busy = 1 Olivier Cruilles Mail: linuxos at ...1896... Le 19 f?vr. 2012 ? 14:14, Olivier Cruilles a ?crit : > May be you ca use this one: > > Application.Busy = 1 > > and when the Process stops > > Application.Busy = 0 > > > Olivier Cruilles > Mail: linuxos at ...1896... > > Le 19 f?vr. 2012 ? 13:13, Bill-Lancaster a ?crit : > >> >> Gambas 3 >> >> I want to run an Exec command when my programme starts. >> >> Using the Open or Activate event for the main means that the form doesn't >> appear until the exec process has finished. >> >> How can I indicate that the Exec process is still running? >> -- >> View this message in context: http://old.nabble.com/how-to-indicate-progress-tp33351547p33351547.html >> Sent from the gambas-user mailing list archive at Nabble.com. >> >> >> ------------------------------------------------------------------------------ >> Virtualization & Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user From demosthenesk at ...626... Sun Feb 19 15:27:13 2012 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Sun, 19 Feb 2012 16:27:13 +0200 Subject: [Gambas-user] compile Gambas3 and gb.gsl Message-ID: <4F4106C1.5030100@...626...> hello i try to compile gambas3 in a Linux Mint Debian Edition and i get || || THESE COMPONENTS ARE DISABLED: || - gb.gsl any ideas? Thanks! From linuxos at ...1896... Sun Feb 19 15:31:05 2012 From: linuxos at ...1896... (Olivier Cruilles) Date: Sun, 19 Feb 2012 15:31:05 +0100 Subject: [Gambas-user] compile Gambas3 and gb.gsl In-Reply-To: <4F4106C1.5030100@...626...> References: <4F4106C1.5030100@...626...> Message-ID: <38A96B3B-89DC-49ED-A6FE-C0FBD36A8072@...1896...> Hello, It's a recent component added to Gambas3. May be you need to install gsl libraries and devel packages. Olivier Cruilles Mail: linuxos at ...1896... Le 19 f?vr. 2012 ? 15:27, Demosthenes Koptsis a ?crit : > hello i try to compile gambas3 in a Linux Mint Debian Edition and i get > > || > || THESE COMPONENTS ARE DISABLED: > || - gb.gsl > > any ideas? > > Thanks! > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From wally at ...2037... Sun Feb 19 15:34:28 2012 From: wally at ...2037... (Wally) Date: Sun, 19 Feb 2012 15:34:28 +0100 Subject: [Gambas-user] compile Gambas3 and gb.gsl In-Reply-To: <4F4106C1.5030100@...626...> References: <4F4106C1.5030100@...626...> Message-ID: <2667174.PmbePNl1RN@...46...> try install gsl and gsl-devel packages (GNU Scientif Library) On Sunday, February 19, 2012 16:27:13 Demosthenes Koptsis wrote: > hello i try to compile gambas3 in a Linux Mint Debian Edition and i get > > || THESE COMPONENTS ARE DISABLED: > || - gb.gsl > > any ideas? > > Thanks! > > ---------------------------------------------------------------------------- > -- Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From demosthenesk at ...626... Sun Feb 19 15:55:56 2012 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Sun, 19 Feb 2012 16:55:56 +0200 Subject: [Gambas-user] compile Gambas3 and gb.gsl In-Reply-To: <2667174.PmbePNl1RN@...46...> References: <4F4106C1.5030100@...626...> <2667174.PmbePNl1RN@...46...> Message-ID: <4F410D7C.9040208@...626...> ok, i installed the gsl. All is ok now. On 02/19/2012 04:34 PM, Wally wrote: > try install gsl and gsl-devel packages (GNU Scientif Library) > > On Sunday, February 19, 2012 16:27:13 Demosthenes Koptsis wrote: >> hello i try to compile gambas3 in a Linux Mint Debian Edition and i get >> >> || THESE COMPONENTS ARE DISABLED: >> || - gb.gsl >> >> any ideas? >> >> Thanks! >> >> ---------------------------------------------------------------------------- >> -- Virtualization& Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > ------------------------------------------------------------------------------ > Virtualization& Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From gambas at ...1... Sun Feb 19 16:29:10 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 16:29:10 +0100 Subject: [Gambas-user] Gambas future? In-Reply-To: References: <33349105.post@...1379...> <4F404D04.4030705@...1...> Message-ID: <4F411546.4070604@...1...> Le 19/02/2012 12:08, M. Cs. a ?crit : > Please Benoit, if you have some extra time, update the sdl and > sdl-sound libraries as well! > > Csaba > What is missing in those libraries? -- Beno?t Minisini From mohareve at ...626... Sun Feb 19 16:50:04 2012 From: mohareve at ...626... (M. Cs.) Date: Sun, 19 Feb 2012 16:50:04 +0100 Subject: [Gambas-user] Gambas future? In-Reply-To: <4F411546.4070604@...1...> References: <33349105.post@...1379...> <4F404D04.4030705@...1...> <4F411546.4070604@...1...> Message-ID: Specially the supported file formats and the stability: "The music file format can be: WAV, OGG or MP3." What about flac? If there would be support for other sound formats and stability of playback that would be good. There are some mp3 files which are distorted upon playback (faster playback of shifted octaves). And it is also not possible by now to use a timeline for an mp3 song, if I used a Slider I simply cannot move the sound position without having program crashed. Thanks! Csaba 2012/2/19, Beno?t Minisini : > Le 19/02/2012 12:08, M. Cs. a ?crit : >> Please Benoit, if you have some extra time, update the sdl and >> sdl-sound libraries as well! >> >> Csaba >> > > What is missing in those libraries? > > -- > Beno?t Minisini > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Sun Feb 19 16:59:58 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 16:59:58 +0100 Subject: [Gambas-user] Gambas future? In-Reply-To: References: <33349105.post@...1379...> <4F404D04.4030705@...1...> <4F411546.4070604@...1...> Message-ID: <4F411C7E.4010909@...1...> Le 19/02/2012 16:50, M. Cs. a ?crit : > Specially the supported file formats and the stability: > "The music file format can be: WAV, OGG or MP3." > What about flac? > If there would be support for other sound formats and stability of > playback that would be good. There are some mp3 files which are > distorted upon playback (faster playback of shifted octaves). And it > is also not possible by now to use a timeline for an mp3 song, if I > used a Slider I simply cannot move the sound position without having > program crashed. All that depends on SDL, I cannot do anything (AFAIK). As for the crash, please provide more details. Regards, -- Beno?t Minisini From mohareve at ...626... Sun Feb 19 17:13:40 2012 From: mohareve at ...626... (M. Cs.) Date: Sun, 19 Feb 2012 17:13:40 +0100 Subject: [Gambas-user] Gambas future? In-Reply-To: <4F411C7E.4010909@...1...> References: <33349105.post@...1379...> <4F404D04.4030705@...1...> <4F411546.4070604@...1...> <4F411C7E.4010909@...1...> Message-ID: About the crash: just take the example shipped with Gambas IDE and play with different mp3 files, try to change the position of playing song and there you are. Csaba 2012/2/19, Beno?t Minisini : > Le 19/02/2012 16:50, M. Cs. a ?crit : >> Specially the supported file formats and the stability: >> "The music file format can be: WAV, OGG or MP3." >> What about flac? >> If there would be support for other sound formats and stability of >> playback that would be good. There are some mp3 files which are >> distorted upon playback (faster playback of shifted octaves). And it >> is also not possible by now to use a timeline for an mp3 song, if I >> used a Slider I simply cannot move the sound position without having >> program crashed. > > All that depends on SDL, I cannot do anything (AFAIK). As for the crash, > please provide more details. > > Regards, > > -- > Beno?t Minisini > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jussi.lahtinen at ...626... Sun Feb 19 19:12:11 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 19 Feb 2012 20:12:11 +0200 Subject: [Gambas-user] Memory problems with Gambas3 Message-ID: Hi! I was debugging huge project to find out why it's execution is slowed down to unusable, when suddenly screen went blank and I was logged out. Reason found from logs: Killed process 1264 (Xorg) total-vm:6406864kB, anon-rss:2751124kB, file-rss:784kB So I ran out of memory. This shouldn't happen, the project I'm working with doesn't need even nearly that much memory. I can prevent this happening when I comment out content of draw event from drawingarea. Right now there are only three lines, which shouldn't cause cumulative memory usage: Draw.Image(imgKoko, 0, 0) Draw.Image(imgKarVe, 0, 0) Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) As I said the project is huge, and so far I haven't be able to isolate what causes the problem. All I know is that in certain form, every time draw event is raised, it causes Xorg to take more memory. Valgrind log is attached. Any ideas? Jussi -------------- next part -------------- A non-text attachment was scrubbed... Name: valgrind-memcheck.log.tar.gz Type: application/x-gzip Size: 2902 bytes Desc: not available URL: From gambas at ...1... Sun Feb 19 19:30:31 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 19:30:31 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: Message-ID: <4F413FC7.4020707@...1...> Le 19/02/2012 19:12, Jussi Lahtinen a ?crit : > Hi! > I was debugging huge project to find out why it's execution is slowed down > to unusable, when suddenly screen went blank and I was logged out. > Reason found from logs: Killed process 1264 (Xorg) total-vm:6406864kB, > anon-rss:2751124kB, file-rss:784kB > So I ran out of memory. This shouldn't happen, the project I'm working with > doesn't need even nearly that much memory. > > I can prevent this happening when I comment out content of draw event from > drawingarea. > Right now there are only three lines, which shouldn't cause cumulative > memory usage: > Draw.Image(imgKoko, 0, 0) > Draw.Image(imgKarVe, 0, 0) > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) > > As I said the project is huge, and so far I haven't be able to isolate what > causes the problem. > All I know is that in certain form, every time draw event is raised, it > causes Xorg to take more memory. > > Valgrind log is attached. > > Any ideas? > > Jussi > Gambas will not prevent you from creating pictures into the X server until it eats all the memory, so I must see your code so that I can know if the leak is in Gambas or in your code. Regards, -- Beno?t Minisini From nando_f at ...951... Sun Feb 19 22:08:51 2012 From: nando_f at ...951... (nando) Date: Sun, 19 Feb 2012 16:08:51 -0500 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: <4F413FC7.4020707@...1...> References: <4F413FC7.4020707@...1...> Message-ID: <20120219210438.M10237@...951...> I had a similar huge problem with pictures. I found it to be this: When I made a new picture, even if using an existing control, the old picture still consumed the memory - it wasn't freed. I solved it by doing (recalling from memory so I may have syntax wrong) picture.clear which deallocated the memory then making the new picture. It chewed up all the memory keeping the old pictures and was a brain teaser. -Fernando ---------- Original Message ----------- From: Beno?t Minisini To: mailing list for gambas users Sent: Sun, 19 Feb 2012 19:30:31 +0100 Subject: Re: [Gambas-user] Memory problems with Gambas3 > Le 19/02/2012 19:12, Jussi Lahtinen a ?crit : > > Hi! > > I was debugging huge project to find out why it's execution is slowed down > > to unusable, when suddenly screen went blank and I was logged out. > > Reason found from logs: Killed process 1264 (Xorg) total-vm:6406864kB, > > anon-rss:2751124kB, file-rss:784kB > > So I ran out of memory. This shouldn't happen, the project I'm working with > > doesn't need even nearly that much memory. > > > > I can prevent this happening when I comment out content of draw event from > > drawingarea. > > Right now there are only three lines, which shouldn't cause cumulative > > memory usage: > > Draw.Image(imgKoko, 0, 0) > > Draw.Image(imgKarVe, 0, 0) > > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) > > > > As I said the project is huge, and so far I haven't be able to isolate what > > causes the problem. > > All I know is that in certain form, every time draw event is raised, it > > causes Xorg to take more memory. > > > > Valgrind log is attached. > > > > Any ideas? > > > > Jussi > > > > Gambas will not prevent you from creating pictures into the X server > until it eats all the memory, so I must see your code so that I can know > if the leak is in Gambas or in your code. > > Regards, > > -- > Beno?t Minisini > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From gambas at ...1... Sun Feb 19 22:14:14 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 22:14:14 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: <20120219210438.M10237@...951...> References: <4F413FC7.4020707@...1...> <20120219210438.M10237@...951...> Message-ID: <4F416626.6030500@...1...> Le 19/02/2012 22:08, nando a ?crit : > I had a similar huge problem with pictures. > I found it to be this: > When I made a new picture, even if using an existing control, > the old picture still consumed the memory - it wasn't freed. > I solved it by doing (recalling from memory so I may have syntax wrong) > picture.clear which deallocated the memory > then making the new picture. > It chewed up all the memory keeping the old pictures > and was a brain teaser. > -Fernando > I was not aware of that bug. Which GUI component do you use? -- Beno?t Minisini From gambas at ...1... Sun Feb 19 22:15:41 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 22:15:41 +0100 Subject: [Gambas-user] TAB on keyboard In-Reply-To: <1328535624.2409.36.camel@...2735...> References: <1328535624.2409.36.camel@...2735...> Message-ID: <4F41667D.9080202@...1...> Le 06/02/2012 14:40, Willy Raets a ?crit : > Hi All, >... > Is there a way in Gambas2 (or Gambas3), when using TAB-key on keyboard > to have it skip (in my case all read only) controls and just go to those > that matter for input? > > Thanks, > > Willy > In revision #4490, I added a Control.NoTabFocus boolean property. When you set this property to TRUE, the TAB key will ignore the control when moving the focus. I hope it will fit your needs. Regards, -- Beno?t Minisini From jussi.lahtinen at ...626... Sun Feb 19 22:52:00 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 19 Feb 2012 23:52:00 +0200 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: <4F413FC7.4020707@...1...> References: <4F413FC7.4020707@...1...> Message-ID: Unfortunately I can't send the project. But I keep on trying to isolate the problem. I'm pretty sure leak is from Gambas as it is fixed by commenting out the three lines. Jussi 2012/2/19 Beno?t Minisini > Le 19/02/2012 19:12, Jussi Lahtinen a ?crit : > > Hi! > > I was debugging huge project to find out why it's execution is slowed > down > > to unusable, when suddenly screen went blank and I was logged out. > > Reason found from logs: Killed process 1264 (Xorg) total-vm:6406864kB, > > anon-rss:2751124kB, file-rss:784kB > > So I ran out of memory. This shouldn't happen, the project I'm working > with > > doesn't need even nearly that much memory. > > > > I can prevent this happening when I comment out content of draw event > from > > drawingarea. > > Right now there are only three lines, which shouldn't cause cumulative > > memory usage: > > Draw.Image(imgKoko, 0, 0) > > Draw.Image(imgKarVe, 0, 0) > > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) > > > > As I said the project is huge, and so far I haven't be able to isolate > what > > causes the problem. > > All I know is that in certain form, every time draw event is raised, it > > causes Xorg to take more memory. > > > > Valgrind log is attached. > > > > Any ideas? > > > > Jussi > > > > Gambas will not prevent you from creating pictures into the X server > until it eats all the memory, so I must see your code so that I can know > if the leak is in Gambas or in your code. > > Regards, > > -- > Beno?t Minisini > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jussi.lahtinen at ...626... Sun Feb 19 22:56:10 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 19 Feb 2012 23:56:10 +0200 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: <20120219210438.M10237@...951...> References: <4F413FC7.4020707@...1...> <20120219210438.M10237@...951...> Message-ID: If I add imgKoko.Clear() and imgKarVe.Clear(), then the memory problem disappear, but this is not solution for me... Jussi On Sun, Feb 19, 2012 at 23:08, nando wrote: > I had a similar huge problem with pictures. > I found it to be this: > When I made a new picture, even if using an existing control, > the old picture still consumed the memory - it wasn't freed. > I solved it by doing (recalling from memory so I may have syntax wrong) > picture.clear which deallocated the memory > then making the new picture. > It chewed up all the memory keeping the old pictures > and was a brain teaser. > -Fernando > > > ---------- Original Message ----------- > From: Beno?t Minisini > To: mailing list for gambas users > Sent: Sun, 19 Feb 2012 19:30:31 +0100 > Subject: Re: [Gambas-user] Memory problems with Gambas3 > > > Le 19/02/2012 19:12, Jussi Lahtinen a ?crit : > > > Hi! > > > I was debugging huge project to find out why it's execution is slowed > down > > > to unusable, when suddenly screen went blank and I was logged out. > > > Reason found from logs: Killed process 1264 (Xorg) total-vm:6406864kB, > > > anon-rss:2751124kB, file-rss:784kB > > > So I ran out of memory. This shouldn't happen, the project I'm working > with > > > doesn't need even nearly that much memory. > > > > > > I can prevent this happening when I comment out content of draw event > from > > > drawingarea. > > > Right now there are only three lines, which shouldn't cause cumulative > > > memory usage: > > > Draw.Image(imgKoko, 0, 0) > > > Draw.Image(imgKarVe, 0, 0) > > > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) > > > > > > As I said the project is huge, and so far I haven't be able to isolate > what > > > causes the problem. > > > All I know is that in certain form, every time draw event is raised, it > > > causes Xorg to take more memory. > > > > > > Valgrind log is attached. > > > > > > Any ideas? > > > > > > Jussi > > > > > > > Gambas will not prevent you from creating pictures into the X server > > until it eats all the memory, so I must see your code so that I can know > > if the leak is in Gambas or in your code. > > > > Regards, > > > > -- > > Beno?t Minisini > > > > > ------------------------------------------------------------------------------ > > Virtualization & Cloud Management Using Capacity Planning > > Cloud computing makes use of virtualization - but cloud computing > > also focuses on allowing computing to be delivered as a service. > > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > ------- End of Original Message ------- > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From mohareve at ...626... Sun Feb 19 23:04:50 2012 From: mohareve at ...626... (M. Cs.) Date: Sun, 19 Feb 2012 23:04:50 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: <4F413FC7.4020707@...1...> Message-ID: I have similar issue: I have a module and private subs in it. I'm using string arrays declared inside that SUB. The SUB is invoked when I scan some folders/files. The memory consumption rises during this scan by around 30 MB, which is quite normal, since I'm feeding memory with huge amount of data. The problem is, when the SUB ends, the memory consumption won't fall back to the previous level, although it should, because the arrays are destroyed with closing of the SUB. Csaba 2012/2/19, Jussi Lahtinen : > Unfortunately I can't send the project. But I keep on trying to isolate the > problem. > I'm pretty sure leak is from Gambas as it is fixed by commenting out the > three lines. > > Jussi > > > > > 2012/2/19 Beno?t Minisini > >> Le 19/02/2012 19:12, Jussi Lahtinen a ?crit : >> > Hi! >> > I was debugging huge project to find out why it's execution is slowed >> down >> > to unusable, when suddenly screen went blank and I was logged out. >> > Reason found from logs: Killed process 1264 (Xorg) total-vm:6406864kB, >> > anon-rss:2751124kB, file-rss:784kB >> > So I ran out of memory. This shouldn't happen, the project I'm working >> with >> > doesn't need even nearly that much memory. >> > >> > I can prevent this happening when I comment out content of draw event >> from >> > drawingarea. >> > Right now there are only three lines, which shouldn't cause cumulative >> > memory usage: >> > Draw.Image(imgKoko, 0, 0) >> > Draw.Image(imgKarVe, 0, 0) >> > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) >> > >> > As I said the project is huge, and so far I haven't be able to isolate >> what >> > causes the problem. >> > All I know is that in certain form, every time draw event is raised, it >> > causes Xorg to take more memory. >> > >> > Valgrind log is attached. >> > >> > Any ideas? >> > >> > Jussi >> > >> >> Gambas will not prevent you from creating pictures into the X server >> until it eats all the memory, so I must see your code so that I can know >> if the leak is in Gambas or in your code. >> >> Regards, >> >> -- >> Beno?t Minisini >> >> >> ------------------------------------------------------------------------------ >> Virtualization & Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Sun Feb 19 23:14:46 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 23:14:46 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: <4F413FC7.4020707@...1...> Message-ID: <4F417456.6080403@...1...> Le 19/02/2012 23:04, M. Cs. a ?crit : > I have similar issue: > I have a module and private subs in it. I'm using string arrays > declared inside that SUB. The SUB is invoked when I scan some > folders/files. The memory consumption rises during this scan by around > 30 MB, which is quite normal, since I'm feeding memory with huge > amount of data. The problem is, when the SUB ends, the memory > consumption won't fall back to the previous level, although it should, > because the arrays are destroyed with closing of the SUB. > > Csaba > This is not related at all. We are talking about leaking memory with Picture objects. -- Beno?t Minisini From gambas at ...1... Sun Feb 19 23:15:31 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 23:15:31 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: <4F413FC7.4020707@...1...> Message-ID: <4F417483.5070208@...1...> Le 19/02/2012 22:52, Jussi Lahtinen a ?crit : > Unfortunately I can't send the project. But I keep on trying to isolate the > problem. > I'm pretty sure leak is from Gambas as it is fixed by commenting out the > three lines. > > Jussi > > I can't do anything without seeing the source of your project or any other project that reproduces the problem! -- Beno?t Minisini From gambas at ...1... Sun Feb 19 23:37:00 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 19 Feb 2012 23:37:00 +0100 Subject: [Gambas-user] Unknown symbol in module with variable set In-Reply-To: References: Message-ID: <4F41798C.6030903@...1...> Le 17/02/2012 21:32, Sebastian Kulesz a ?crit : > Hi. I'm getting an unusual error in a large project when trying to > access a property of a module using an initializer to execute custom > code in a large set of modules. > The simplified code can be seen in the attached project. When > executed, it complains about an unknown symbol, but in the stack it's > listed. > Is this a bug or an error in my code? > > Tanks! > An error in your code. If you use Me in a static method like asd.me(), you will get a special internal value that represents the asd class, and that is converted to a 'Class' object (as Class["asd"] would return) when being passed as an argument to the Main.Load() method. And an instance of the 'Class' class does not have the public symbols of the 'asd' class, as you expected. Regards, -- Beno?t Minisini From gambas at ...1... Mon Feb 20 01:02:19 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 20 Feb 2012 01:02:19 +0100 Subject: [Gambas-user] Naming/Renaming projects In-Reply-To: <4F30EFDA.5080103@...221...> References: <4F2FBB8A.1070508@...221...> <4F304A79.5010408@...221...> <4F30EFDA.5080103@...221...> Message-ID: <4F418D8B.6060800@...1...> Le 07/02/2012 10:33, Rolf-Werner Eilert a ?crit : > Hi Matti, > > Am 06.02.2012 22:47, schrieb Matti: >> Hi Rolf, >> >> to your 1st point: >> in gb3 there is a wizard, asking first for the directory (and you can create a >> new one), then asking for the name and the title of the project. >> This should be ok, don't you think so? > > Well, you are right. The wizard asks for the Type of project (maybe the > rest varies according to this choice?), then asks for the directory > UNDER WHICH the project shall be stored - but it doesn't tell you that, > you have to guess. Maybe this should be made somewhat clearer. > > Then I'm asked for a "name" and a "title". But what are these good for? > Is name the name of the project directory, and title a free string > stored within the project file (and what is it used for)? Or vice-versa? > Or something else? Who knows... :-) Again, this could be made clearer, > either by more self-explanatory titles for the input boxes or by some > tooltip or a description at the side or whatever. > > >> >> 2nd point: >> (also gb3) >> In the opening dialog you can see clearly if it is a folder or a gambas project. >> Just look at the icons. > > Errr - I didn't mean that small wizard popping up when you start Gambas. > I mean the open dialog. Yes, it actually doesn't ask for a file, but it > does provide a list of the files contained in the directories you click > on, and you can click on the files, and then the project loads. So a > beginner might be confused what to do or if it matters where the > double-click went. Wouldn't it be enough to show the directories only? > Or even better: the project titles as a default, and optionally the > directory structure (for the geeks)? > > For my own part, I know where to click on, but I was thinking of > beginners with Gambas and remembered how I was confused here when I > started with it. > > > Hope this makes it clearer... > > Rolf > Is it better (for all of you) with revision #4491? -- Beno?t Minisini From gambas at ...2524... Mon Feb 20 01:18:12 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Mon, 20 Feb 2012 00:18:12 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <7-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <7-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <8-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Updates: Status: Started Comment #8 on issue 123 by benoit.m... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 Is it better with revision #4492? From charles at ...1784... Mon Feb 20 08:09:53 2012 From: charles at ...1784... (charlesg) Date: Sun, 19 Feb 2012 23:09:53 -0800 (PST) Subject: [Gambas-user] Issue 211 in gambas: Gridview multiselect In-Reply-To: <0-6813199134517018827-15707643296586879195-gambas=googlecode.com@...2524...> References: <0-6813199134517018827-15707643296586879195-gambas=googlecode.com@...2524...> Message-ID: <33355052.post@...1379...> gambas-4 wrote: > > 1) Describe the problem. > i cant deselect a row when multiple row are selected > Hi I have an application with the same problem and have been trying to de-construct it to get to the essence. It first occured in Gambas2 and transferred to Gambas3 with the auto convert. If I start the project again in G3, put the same gridview on a form and load the same data it works fine with QT (GTK multiline does not seem to work). -- View this message in context: http://old.nabble.com/Issue-211-in-gambas%3A-Gridview-multiselect-tp33314986p33355052.html Sent from the gambas-user mailing list archive at Nabble.com. From eilert-sprachen at ...221... Mon Feb 20 08:39:01 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Mon, 20 Feb 2012 08:39:01 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: <4F417483.5070208@...1...> References: <4F413FC7.4020707@...1...> <4F417483.5070208@...1...> Message-ID: <4F41F895.9050803@...221...> Am 19.02.2012 23:15, schrieb Beno?t Minisini: > Le 19/02/2012 22:52, Jussi Lahtinen a ?crit : >> Unfortunately I can't send the project. But I keep on trying to isolate the >> problem. >> I'm pretty sure leak is from Gambas as it is fixed by commenting out the >> three lines. >> >> Jussi >> >> > > I can't do anything without seeing the source of your project or any > other project that reproduces the problem! > Maybe this is related to the problem I had the other day. When I read this thread, it reminds me to the problem I had with painting and nothing appearing until after some trials, the application will crash. This happened under KDE (qt4) and not under LXDE (gtk). Benoit, you asked me about the rendering type. Suse is organized somewhat different, your hints didn't match. After some searching I found a switch in KDE where I can choose the rendering type. But choosing another one didn't help. Of course, this doesn't need to be related, but I just wanted to mention there's something strange with the drawing area :-) Regards Rolf From eilert-sprachen at ...221... Mon Feb 20 08:42:36 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Mon, 20 Feb 2012 08:42:36 +0100 Subject: [Gambas-user] Naming/Renaming projects In-Reply-To: <4F418D8B.6060800@...1...> References: <4F2FBB8A.1070508@...221...> <4F304A79.5010408@...221...> <4F30EFDA.5080103@...221...> <4F418D8B.6060800@...1...> Message-ID: <4F41F96C.7070603@...221...> Am 20.02.2012 01:02, schrieb Beno?t Minisini: > Le 07/02/2012 10:33, Rolf-Werner Eilert a ?crit : >> Hi Matti, >> >> Am 06.02.2012 22:47, schrieb Matti: >>> Hi Rolf, >>> >>> to your 1st point: >>> in gb3 there is a wizard, asking first for the directory (and you can create a >>> new one), then asking for the name and the title of the project. >>> This should be ok, don't you think so? >> >> Well, you are right. The wizard asks for the Type of project (maybe the >> rest varies according to this choice?), then asks for the directory >> UNDER WHICH the project shall be stored - but it doesn't tell you that, >> you have to guess. Maybe this should be made somewhat clearer. >> >> Then I'm asked for a "name" and a "title". But what are these good for? >> Is name the name of the project directory, and title a free string >> stored within the project file (and what is it used for)? Or vice-versa? >> Or something else? Who knows... :-) Again, this could be made clearer, >> either by more self-explanatory titles for the input boxes or by some >> tooltip or a description at the side or whatever. >> >> >>> >>> 2nd point: >>> (also gb3) >>> In the opening dialog you can see clearly if it is a folder or a gambas project. >>> Just look at the icons. >> >> Errr - I didn't mean that small wizard popping up when you start Gambas. >> I mean the open dialog. Yes, it actually doesn't ask for a file, but it >> does provide a list of the files contained in the directories you click >> on, and you can click on the files, and then the project loads. So a >> beginner might be confused what to do or if it matters where the >> double-click went. Wouldn't it be enough to show the directories only? >> Or even better: the project titles as a default, and optionally the >> directory structure (for the geeks)? >> >> For my own part, I know where to click on, but I was thinking of >> beginners with Gambas and remembered how I was confused here when I >> started with it. >> >> >> Hope this makes it clearer... >> >> Rolf >> > > Is it better (for all of you) with revision #4491? > Ooops - I've got to download and install at home on my laptop first... Maybe I'll find the time when I come home for lunch later :-) Rolf From gambas at ...2524... Mon Feb 20 10:24:40 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Mon, 20 Feb 2012 09:24:40 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <8-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <8-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <9-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Comment #9 on issue 123 by adamn... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 Hi Benoit, I will try tonight but I am very tired after a big day. If not, I will get back to you in a couple of days. Too many things happening at once here. I would like to collaborate with you on this. I am beginning to see what you are trying to do, but also see some pitfalls. Perhaps because we are trying to use gambas libraries/components a bit ahead of their time (or a bit ahead of my understanding). On the other hand, the component/library structure seems to be a very powerful feature for gambas. The gb2 component approach had some maturity but also had some side effects (wrong expression ... I really am tired). I would appreciate that you could share a bit of your vision as to where the component/library structure could be going in the short term. Just so we are working on the same page. From gambas at ...2524... Mon Feb 20 10:33:43 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Mon, 20 Feb 2012 09:33:43 +0000 Subject: [Gambas-user] Issue 123 in gambas: GUI dependencies in library projects not exposing any gui dependency In-Reply-To: <9-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> References: <9-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> <0-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Message-ID: <10-6813199134517018827-4212819439130212327-gambas=googlecode.com@...2524...> Comment #10 on issue 123 by benoit.m... at ...626...: GUI dependencies in library projects not exposing any gui dependency http://code.google.com/p/gambas/issues/detail?id=123 Let's talk about that on the user mailing-list so... From gambas at ...2524... Tue Feb 21 01:33:22 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 21 Feb 2012 00:33:22 +0000 Subject: [Gambas-user] Issue 213 in gambas: The packager includes versioning systems hidden folders into results Message-ID: <0-6813199134517018827-1275285230299976890-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 213 by sebi... at ...626...: The packager includes versioning systems hidden folders into results http://code.google.com/p/gambas/issues/detail?id=213 When creating an installation package, hidden folders that belong to versioning systems are included in the results. Bazaar, the one that was used to report the bug(.bzr). Mercurial, CVS, SVN, etc where not tested, but are assumed to be affected. The root folder and subdirectories should be excluded. Version:3.0 From gambas at ...2524... Tue Feb 21 01:37:22 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 21 Feb 2012 00:37:22 +0000 Subject: [Gambas-user] Issue 214 in gambas: The packager includes versioning systems hidden folders into results Message-ID: <0-6813199134517018827-7481577664491124818-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 214 by sebi... at ...626...: The packager includes versioning systems hidden folders into results http://code.google.com/p/gambas/issues/detail?id=214 When creating an installation package, hidden folders that belong to versioning systems are included in the results. Bazaar, the one that was used to report the bug(.bzr). Mercurial, CVS, SVN, etc where not tested, but are assumed to be affected. The root folder and subdirectories should be excluded. Version:3.0 From gambas at ...2524... Tue Feb 21 01:41:23 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 21 Feb 2012 00:41:23 +0000 Subject: [Gambas-user] Issue 215 in gambas: The packager includes versioning systems hidden folders into results Message-ID: <0-6813199134517018827-4213544040924577156-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 215 by sebi... at ...626...: The packager includes versioning systems hidden folders into results http://code.google.com/p/gambas/issues/detail?id=215 When creating an installation package, hidden folders that belong to versioning systems are included in the results. Bazaar, the one that was used to report the bug(.bzr). Mercurial, CVS, SVN, etc where not tested, but are assumed to be affected. The root folder and subdirectories should be excluded. Version:3.0 From sebikul at ...626... Tue Feb 21 01:45:36 2012 From: sebikul at ...626... (Sebi) Date: Tue, 21 Feb 2012 00:45:36 +0000 Subject: [Gambas-user] Bug duplicate Message-ID: <1759193788-1329785137-cardhu_decombobulator_blackberry.rim.net-643127785-@...2753...> Hi! Due to an error on my side, bugs #214 and #215 where created as duplicates of #213. They can be removed. I'm really sorry for that. From eilert-sprachen at ...221... Tue Feb 21 08:48:09 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Tue, 21 Feb 2012 08:48:09 +0100 Subject: [Gambas-user] Naming/Renaming projects In-Reply-To: <4F418D8B.6060800@...1...> References: <4F2FBB8A.1070508@...221...> <4F304A79.5010408@...221...> <4F30EFDA.5080103@...221...> <4F418D8B.6060800@...1...> Message-ID: <4F434C39.6090406@...221...> Am 20.02.2012 01:02, schrieb Beno?t Minisini: > Le 07/02/2012 10:33, Rolf-Werner Eilert a ?crit : >> Hi Matti, >> >> Am 06.02.2012 22:47, schrieb Matti: >>> Hi Rolf, >>> >>> to your 1st point: >>> in gb3 there is a wizard, asking first for the directory (and you can create a >>> new one), then asking for the name and the title of the project. >>> This should be ok, don't you think so? >> >> Well, you are right. The wizard asks for the Type of project (maybe the >> rest varies according to this choice?), then asks for the directory >> UNDER WHICH the project shall be stored - but it doesn't tell you that, >> you have to guess. Maybe this should be made somewhat clearer. >> >> Then I'm asked for a "name" and a "title". But what are these good for? >> Is name the name of the project directory, and title a free string >> stored within the project file (and what is it used for)? Or vice-versa? >> Or something else? Who knows... :-) Again, this could be made clearer, >> either by more self-explanatory titles for the input boxes or by some >> tooltip or a description at the side or whatever. >> >> >>> >>> 2nd point: >>> (also gb3) >>> In the opening dialog you can see clearly if it is a folder or a gambas project. >>> Just look at the icons. >> >> Errr - I didn't mean that small wizard popping up when you start Gambas. >> I mean the open dialog. Yes, it actually doesn't ask for a file, but it >> does provide a list of the files contained in the directories you click >> on, and you can click on the files, and then the project loads. So a >> beginner might be confused what to do or if it matters where the >> double-click went. Wouldn't it be enough to show the directories only? >> Or even better: the project titles as a default, and optionally the >> directory structure (for the geeks)? >> >> For my own part, I know where to click on, but I was thinking of >> beginners with Gambas and remembered how I was confused here when I >> started with it. >> >> >> Hope this makes it clearer... >> >> Rolf >> > > Is it better (for all of you) with revision #4491? > Sorry, forgot to write last afternoon. Yes! It's great this way, thanks a lot for your work! Rolf From mohareve at ...626... Tue Feb 21 14:01:26 2012 From: mohareve at ...626... (M. Cs.) Date: Tue, 21 Feb 2012 14:01:26 +0100 Subject: [Gambas-user] How to regain the used memory after clearing the array? Message-ID: Hello! I have this problem with arrays. I have a class Keress given with this: ' Gambas class file Export ' Gambas module file Create Static Private nev As New String[] Private ut As New String[] Private nagy As New Float[] Private mikor As New String[] Private kotet As New String[] Public SConn As New Connection Public Sub Search(y As Integer, stext As String, detect As String, direction As String) As Integer '########################### Do the search for files/folders ########################## Dim dis As Integer = 0 Dim n, m, i, j As Integer Dim visszhang, subhang As Result Dim dubl, indexer As String[] Dim quert, point, mkb, xkl, fullsearch As String Dim nyogd As TextLabel Dim keep As PictureBox SConn.Name = "GamCat" SConn.Type = "sqlite" SConn.Host = User.Home & "/.GamCat" SConn.Open() If FMain.holder.value = False Then Trashing() Endif FMain.gV.Columns.Count = 5 Select Case y Case 1 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 AND FName=&2 AND (FSubs='0' OR FSubs='3') ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, stext) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName=&1 AND (FSubs='0' OR FSubs='3') ORDER BY " & detect & " " & direction & ";", stext) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 2 '!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 AND FName LIKE &2 AND (FSubs='0' OR FSubs='3') ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName LIKE &1 AND (FSubs='0' OR FSubs='3') ORDER BY " & detect & " " & direction & ";", "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 3 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 FName LIKE &2 AND (FSubs='0' OR FSubs='3') ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, "%." & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = FMain.DBconX.Exec("SELECT * FROM CENTRAL WHERE FName LIKE &1 AND (FSubs='0' OR FSubs='3') ORDER BY " & detect & " " & direction & ";", "%." & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 4 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 AND FName=&2 AND FSubs='1' ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, stext) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName=&1 AND FSubs='1' ORDER BY " & detect & " " & direction & ";", stext) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 5 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 AND FName LIKE &2 AND FSubs='1' ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName LIKE &1 AND FSubs='1' ORDER BY " & detect & " " & direction & ";", "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 6 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 AND FName LIKE &2 AND FSubs='1' ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, "%." & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName=&1 ORDER BY " & detect & " " & direction & ";", stext) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 7 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 FName=&2 ORDERBY " & detect & " " & direction & ";", FMain.SelcatBox.Text, stext) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName=&1 ORDER BY " & detect & " " & direction & ";", stext) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 8 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 FName LIKE &2 ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName LIKE &1 ORDER BY " & detect & " " & direction & ";", "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 9 If FMain.only.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 FName LIKE &2 ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text, "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE FName LIKE &1 ORDER BY " & detect & " " & direction & ";", "%" & stext & "%") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 10 If FMain.only.Value = True Then If FMain.nuvola > 0 visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE Category=&1 ORDER BY " & detect & " " & direction & ";", FMain.SelcatBox.Text) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Else If FMain.nuvola > 0 visszhang = SConn.Exec("SELECT * FROM CENTRAL ORDER BY " & detect & " " & direction & ";") For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Endif Case 11 xkl = FMain.list[FMain.list.Row, 0].Text If FMain.uptf.Value = True Then visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE VName=&1 AND FName LIKE &2 ORDER BY " & detect & " " & direction & ";", xkl, "%" & stext & "%") Else visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE VName=&1 ORDER BY " & detect & ";", xkl) Endif For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", xkl) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Case 12 If FMain.list.Rows.Count > 0 Then If FMain.uptf.Value = True And FMain.archTypeBox.Text = ("ALL") Then visszhang = SConn.Exec("SELECT * FROM ARCHIVES WHERE Name LIKE &1 ORDER BY NAME " & direction & ";", "%" & stext & "%") Endif If FMain.uptf.Value = True And FMain.archTypeBox.Text <> ("ALL") Then visszhang = SConn.Exec("SELECT * FROM ARCHIVES WHERE Name LIKE &1 AND Type=&2 ORDER BY NAME " & direction & ";", "%" & stext & "%", FMain.archTypeBox.Text) Endif If FMain.uptf.Value = False And FMain.archTypeBox.Text = ("ALL") Then visszhang = SConn.Exec("SELECT * FROM ARCHIVES ORDER BY NAME;") Endif If FMain.uptf.Value = False And FMain.archTypeBox.Text <> ("ALL") Then visszhang = SConn.Exec("SELECT * FROM ARCHIVES WHERE Type=&1 ORDER BY NAME;", FMain.archTypeBox.Text) Endif For Each visszhang dis = Insert(visszhang!"Name", visszhang!"Parent", 0, "-", visszhang!Volume) Next If FMain.uptf.Value = True Then visszhang = SConn.Exec("SELECT * FROM ISO WHERE Name LIKE &1 ORDER BY NAME " & direction & ";", "%" & stext & "%") Else visszhang = SConn.Exec("SELECT * FROM ISO ORDER BY NAME;") Endif For Each visszhang dis = Insert(visszhang!"Name", visszhang!"Holder", 0, "-", visszhang!Volume) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next Endif Case 13 ' Let's list the content of a folder dubl = Split(stext, "#") visszhang = SConn.Exec("SELECT * FROM CENTRAL WHERE VName=&1 AND FPath=&2 ORDER BY " & detect & " " & direction & ";", dubl[0], dubl[1]) For Each visszhang dis = Insert(visszhang!"FName", visszhang!"FPath", Round(visszhang!"FSize" / 1048576, -2), visszhang!"FChanged", visszhang!VName) Next FMain.gV.Rows.Count = dis For i = 0 To dis - 1 FMain.gv_Data(i, 0) FMain.gv_Data(i, 1) FMain.gv_Data(i, 2) FMain.gv_Data(i, 3) FMain.gv_Data(i, 4) Next End Select SConn.Close() Return nev.Count End Public Sub Trashing() nev.Clear() ut.Clear() nagy.Clear() mikor.Clear() kotet.Clear() End Public Sub Remove(mit As String) ut.Remove(mit) nev.Remove(mit) kotet.Remove(mit) mikor.Remove(mit) nagy.Remove(mit) End Public Sub Insert(v1 As String, v2 As String, v3 As Float, v4 As String, v5 As String) As Integer nev.Add(v1) ut.Add(v2) nagy.Add(v3) mikor.Add(v4) kotet.Add(v5) Return nev.Count End Public Sub Name(x As Integer) As String Return nev[x] End Public Sub Volm(x As Integer) As String Return kotet[x] End Public Sub Road(x As Integer) As String Return ut[x] End Public Sub Num() As Integer Return nev.Count End Public Sub Size(x As Integer) As String Return nagy[x] End Public Sub When(x As Integer) As String Return mikor[x] End Public Sub Mhet(szuro As String) Dim todie As New Integer[] Dim kotetx As New String[] Dim utol, m, n As Integer If (szuro <> Null And szuro <> "") Then 'Deleting after a splitted string pattern utol = nev.Length - 1 For m = 0 To utol If InStr(nev[m], szuro) = 0 Then todie.Add(m) Endif Next todie.Sort(16) If FMain.robocop = True Then FMain.roboBox.Add("#" & szuro) Endif For m = 0 To todie.Length - 1 Remove(todie[m]) Next FMain.gV.Rows.Count -= todie.Length FMain.gV.Refresh() todie.Clear() FMain.hany.Text = FMain.gV.Rows.Count FMain.combo.Clear() kotetx.Clear n = FMain.gV.Rows.Count - 1 For m = 0 To n kotetx.Add(FMain.gV[m, 1].Text) Next kotetx.Sort() If n > 0 Then FMain.combo.Add(kotetx[0]) For m = 1 To n If (kotetx[m - 1] <> kotetx[m]) Then FMain.combo.Add(kotetx[m]) Endif Next Endif Endif End The class Keress is used for search, and its private arrays are declared at the beginning of the file. This class has only one instance, and it is responsible for the search through the database. After the search it handles the results to a GridView called gV, situated on FMain form. The problem is: if these arrays are filled with search's hits, the memory consumption goes up to a certain level, which is O.K. After that, when I perform another search, with much lower number of found elements, the memory consumption won't fall although all the arrays are cleared before filling them with fresh values. Where am I wrong? I would like to see the memory consumption is in accord with the number of found elements. It looks like .Clear is clearing the array from elements, but keeping its size. Why? Thank you for the patience! Csaba From willy at ...2734... Wed Feb 22 01:03:35 2012 From: willy at ...2734... (Willy Raets) Date: Wed, 22 Feb 2012 01:03:35 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications Message-ID: <1329869015.2330.57.camel@...2735...> Hi all, I've been searching and reading my butt of on how to make a library with Gambas 2 for Gambas 2. It is a very simple and short library so I can get familiar with how it works and do a how to documentation so others can benefit of my learning curve as well and you will be bored less with questions like this on this list (hopefully). I have a simple Class called SysInfo (made it Start up Class) That is all the project contains, no forms or modules. ------ Code for Class SysInfo --- PUBLIC OS AS String PUBLIC Kernel AS String PUBLIC KernelRelease AS String PUBLIC KernelVersion AS String PUBLIC Architecture AS String PUBLIC SUB ReadInfo() DIM sLineOSYS, sLineKERN, sLineKERNR, sLineKERNV, sLineARCH AS String '--- Read system information --- EXEC ["uname", "-o"] TO sLineOSYS EXEC ["uname", "-s"] TO sLineKERN EXEC ["uname", "-r"] TO sLineKERNR EXEC ["uname", "-v"] TO sLineKERNV EXEC ["arch"] TO sLineARCH OS = Trim(sLineOSYS) Kernel = Trim(sLineKERN) KernelRelease = Trim(sLineKERNR) KernelVersion = Trim(sLineKERNV) Architecture = Trim(sLineARCH) END ----- End Code Class file ----- Now I read somewhere you need to make a gambas executable and place it in the project folder of the project you want to use it. So I made an executable named it SysInfo.gambas Placed it in the project folder of a project where I need the library and then I get stuck. How to I use the library in my code? Gambas documentation goes into C libraries but says nothing about gambas libraries. Does it work the same for Gambas libraries, because I have tried with using LIBRARY "SysInfo.gambas" and I am not getting there. And if I would do EXTERN ReadInfo() compiler gives no problem. But how to get the OS because EXTERN OS is not okay for the compiler. I was expecting, because of the library being Gambas for Gambas that it would be eazier. Like that the compiler would recognize SysInfo and that a simple SysInfo.ReadInfo would run the getting of the info and a simple SysInfo.OS would give me the OS info. But obviousily it ain't that simple. How do I get my application to recognize SysInfo? And next, how do I use SysInfo in my application I am missing some information there? Any links to some good example maybe that could get me on the road again or some hints? Thanks, Willy From jussi.lahtinen at ...626... Wed Feb 22 01:12:49 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 22 Feb 2012 02:12:49 +0200 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329869015.2330.57.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> Message-ID: First, use Export command in classes you want to expose as library. Then, open project which uses this as library. Open project properties, choose tab "libraries" and add library binary. Jussi On Wed, Feb 22, 2012 at 02:03, Willy Raets wrote: > Hi all, > > I've been searching and reading my butt of on how to make a library with > Gambas 2 for Gambas 2. > > It is a very simple and short library so I can get familiar with how it > works and do a how to documentation so others can benefit of my learning > curve as well and you will be bored less with questions like this on > this list (hopefully). > > I have a simple Class called SysInfo (made it Start up Class) > That is all the project contains, no forms or modules. > > ------ Code for Class SysInfo --- > > PUBLIC OS AS String > PUBLIC Kernel AS String > PUBLIC KernelRelease AS String > PUBLIC KernelVersion AS String > PUBLIC Architecture AS String > > PUBLIC SUB ReadInfo() > > DIM sLineOSYS, sLineKERN, sLineKERNR, sLineKERNV, sLineARCH AS String > '--- Read system information --- > EXEC ["uname", "-o"] TO sLineOSYS > EXEC ["uname", "-s"] TO sLineKERN > EXEC ["uname", "-r"] TO sLineKERNR > EXEC ["uname", "-v"] TO sLineKERNV > EXEC ["arch"] TO sLineARCH > OS = Trim(sLineOSYS) > Kernel = Trim(sLineKERN) > KernelRelease = Trim(sLineKERNR) > KernelVersion = Trim(sLineKERNV) > Architecture = Trim(sLineARCH) > > END > > ----- End Code Class file ----- > > Now I read somewhere you need to make a gambas executable and place it > in the project folder of the project you want to use it. > > So I made an executable named it SysInfo.gambas > Placed it in the project folder of a project where I need the library > and then I get stuck. > > How to I use the library in my code? > > Gambas documentation goes into C libraries but says nothing about gambas > libraries. > Does it work the same for Gambas libraries, because I have tried with > using LIBRARY "SysInfo.gambas" and I am not getting there. > And if I would do EXTERN ReadInfo() compiler gives no problem. > But how to get the OS because EXTERN OS is not okay for the compiler. > > I was expecting, because of the library being Gambas for Gambas that it > would be eazier. Like that the compiler would recognize SysInfo and that > a simple SysInfo.ReadInfo would run the getting of the info and a simple > SysInfo.OS would give me the OS info. > But obviousily it ain't that simple. > > How do I get my application to recognize SysInfo? > And next, how do I use SysInfo in my application > > I am missing some information there? > Any links to some good example maybe that could get me on the road again > or some hints? > > Thanks, > > Willy > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...2524... Wed Feb 22 02:07:04 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Wed, 22 Feb 2012 01:07:04 +0000 Subject: [Gambas-user] Issue 181 in gambas: Crash with certain menu caption. In-Reply-To: <6-6813199134517018827-9691118861731232159-gambas=googlecode.com@...2524...> References: <6-6813199134517018827-9691118861731232159-gambas=googlecode.com@...2524...> <0-6813199134517018827-9691118861731232159-gambas=googlecode.com@...2524...> Message-ID: <7-6813199134517018827-9691118861731232159-gambas=googlecode.com@...2524...> Comment #7 on issue 181 by jussi.la... at ...626...: Crash with certain menu caption. http://code.google.com/p/gambas/issues/detail?id=181 Problem still persist with r4493. Also I have no problems with other GTK+ programs, only those made with Gambas. I reverted back to r4255, and everything works as expected... And so I made tests, r4338 works and r4339 do not work. I think the significant difference is in file gcontrol.cpp, line 1462. It was: return COLOR_DEFAULT; Now it is: return gDesktop::bgColor(); Fits to the stack from gdb. From adamnt42 at ...626... Wed Feb 22 02:22:10 2012 From: adamnt42 at ...626... (GMail) Date: Wed, 22 Feb 2012 11:52:10 +1030 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329869015.2330.57.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> Message-ID: <1329873730.3474.30.camel@...2688...> On Wed, 2012-02-22 at 01:03 +0100, Willy Raets wrote: > Hi all, > > I've been searching and reading my butt of on how to make a library with > Gambas 2 for Gambas 2. > First, gambas 2 does not have "libraries", what you are creating is a "gambas component". A pedantic point perhaps, but gambas 3 libraries are quite a different kettle of fish. > It is a very simple and short library so I can get familiar with how it > works and do a how to documentation so others can benefit of my learning > curve as well and you will be bored less with questions like this on > this list (hopefully). > > I have a simple Class called SysInfo (made it Start up Class) > That is all the project contains, no forms or modules. > > ------ Code for Class SysInfo --- > (As Jussi says) EXPORT > PUBLIC OS AS String > PUBLIC Kernel AS String > PUBLIC KernelRelease AS String > PUBLIC KernelVersion AS String > PUBLIC Architecture AS String > > PUBLIC SUB ReadInfo() > > DIM sLineOSYS, sLineKERN, sLineKERNR, sLineKERNV, sLineARCH AS String > '--- Read system information --- > EXEC ["uname", "-o"] TO sLineOSYS > EXEC ["uname", "-s"] TO sLineKERN > EXEC ["uname", "-r"] TO sLineKERNR > EXEC ["uname", "-v"] TO sLineKERNV > EXEC ["arch"] TO sLineARCH > OS = Trim(sLineOSYS) > Kernel = Trim(sLineKERN) > KernelRelease = Trim(sLineKERNR) > KernelVersion = Trim(sLineKERNV) > Architecture = Trim(sLineARCH) > > END > > ----- End Code Class file ----- > > Now I read somewhere you need to make a gambas executable and place it > in the project folder of the project you want to use it. > > So I made an executable named it SysInfo.gambas > Placed it in the project folder of a project where I need the library > and then I get stuck. That is for gambas3. For gambas2 (from memory) you just need to: 1) in the Project Properties on the Options tab, set "This project is a component" to Yes and "Component Advancement" to whatever you like. 2) on the "Requires" tab, add any features and components that your component MUST have access to in order to run as a component in a client application. N.B. the Requires tab is different to the Components tab. 3)Make the executable.(Ctl+Alt+M) MAKE SURE THAT YOU CHECK THE "Install in the User Component Directory" in the Options expander on the Make Executable form. Then check that the project library contains some new files: .info, .list and .component (these are used to describe the component to clients/gb2 runtime. > > How to I use the library in my code? 4) in your client project, On the Project Properties "Comonents" tab you should see your component listed under the "User Components" section. (If it's not visible, try opening the project in a completely new instance of gambas2 IDE) > > Gambas documentation goes into C libraries but says nothing about gambas > libraries. > Does it work the same for Gambas libraries, because I have tried with > using LIBRARY "SysInfo.gambas" and I am not getting there. > And if I would do EXTERN ReadInfo() compiler gives no problem. > But how to get the OS because EXTERN OS is not okay for the compiler. > Wrong way go back. You are correct below. > I was expecting, because of the library being Gambas for Gambas that it > would be eazier. Like that the compiler would recognize SysInfo and that > a simple SysInfo.ReadInfo would run the getting of the info and a simple > SysInfo.OS would give me the OS info. > But obviousily it ain't that simple. Yes it is. > > How do I get my application to recognize SysInfo? > And next, how do I use SysInfo in my application > > I am missing some information there? > Any links to some good example maybe that could get me on the road again > or some hints? > > Thanks, > > Willy hth Bruce From sebikul at ...626... Wed Feb 22 04:34:53 2012 From: sebikul at ...626... (Sebastian Kulesz) Date: Wed, 22 Feb 2012 00:34:53 -0300 Subject: [Gambas-user] gb.option documentation Message-ID: Hi! Wanting to use the gb.option component I found out that the documentation was missing. I wrote most of it by testing with a sample project and using the Getopt [0] documentation. But the remaining 3 pages are out of my understanding. Would anybody with the knowledge be so keen to finish them so that this component can be completely documented? [0] http://www.gnu.org/software/libc/manual/html_node/Getopt.html From willy at ...2734... Wed Feb 22 14:12:28 2012 From: willy at ...2734... (Willy Raets) Date: Wed, 22 Feb 2012 14:12:28 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329873730.3474.30.camel@...2688...> References: <1329869015.2330.57.camel@...2735...> <1329873730.3474.30.camel@...2688...> Message-ID: <1329916348.2358.11.camel@...2735...> On wo, 2012-02-22 at 11:52 +1030, GMail wrote: > On Wed, 2012-02-22 at 01:03 +0100, Willy Raets wrote: > > Hi all, > > > > I've been searching and reading my butt of on how to make a library with > > Gambas 2 for Gambas 2. > > > First, gambas 2 does not have "libraries", what you are creating is a > "gambas component". A pedantic point perhaps, but gambas 3 libraries > are quite a different kettle of fish. > > > It is a very simple and short library so I can get familiar with how it > > works and do a how to documentation so others can benefit of my learning > > curve as well and you will be bored less with questions like this on > > this list (hopefully). > > > > I have a simple Class called SysInfo (made it Start up Class) > > That is all the project contains, no forms or modules. > > > > ------ Code for Class SysInfo --- > > > > (As Jussi says) > EXPORT > > > PUBLIC OS AS String > > PUBLIC Kernel AS String > > PUBLIC KernelRelease AS String > > PUBLIC KernelVersion AS String > > PUBLIC Architecture AS String > > > > PUBLIC SUB ReadInfo() > > > > DIM sLineOSYS, sLineKERN, sLineKERNR, sLineKERNV, sLineARCH AS String > > '--- Read system information --- > > EXEC ["uname", "-o"] TO sLineOSYS > > EXEC ["uname", "-s"] TO sLineKERN > > EXEC ["uname", "-r"] TO sLineKERNR > > EXEC ["uname", "-v"] TO sLineKERNV > > EXEC ["arch"] TO sLineARCH > > OS = Trim(sLineOSYS) > > Kernel = Trim(sLineKERN) > > KernelRelease = Trim(sLineKERNR) > > KernelVersion = Trim(sLineKERNV) > > Architecture = Trim(sLineARCH) > > > > END > > > > ----- End Code Class file ----- > > > > Now I read somewhere you need to make a gambas executable and place it > > in the project folder of the project you want to use it. > > > > So I made an executable named it SysInfo.gambas > > Placed it in the project folder of a project where I need the library > > and then I get stuck. > > That is for gambas3. For gambas2 (from memory) you just need to: > 1) in the Project Properties on the Options tab, set "This project is a > component" to Yes and "Component Advancement" to whatever you like. > 2) on the "Requires" tab, add any features and components that your > component MUST have access to in order to run as a component in a client > application. N.B. the Requires tab is different to the Components tab. > 3)Make the executable.(Ctl+Alt+M) MAKE SURE THAT YOU CHECK THE "Install > in the User Component Directory" in the Options expander on the Make > Executable form. Then check that the project library contains some new > files: .info, .list and .component (these are used to describe the > component to clients/gb2 runtime. > > > > > How to I use the library in my code? > 4) in your client project, On the Project Properties "Comonents" tab you > should see your component listed under the "User Components" section. > (If it's not visible, try opening the project in a completely new > instance of gambas2 IDE) > > > > > Gambas documentation goes into C libraries but says nothing about gambas > > libraries. > > Does it work the same for Gambas libraries, because I have tried with > > using LIBRARY "SysInfo.gambas" and I am not getting there. > > And if I would do EXTERN ReadInfo() compiler gives no problem. > > But how to get the OS because EXTERN OS is not okay for the compiler. > > > Wrong way go back. You are correct below. > > > I was expecting, because of the library being Gambas for Gambas that it > > would be eazier. Like that the compiler would recognize SysInfo and that > > a simple SysInfo.ReadInfo would run the getting of the info and a simple > > SysInfo.OS would give me the OS info. > > But obviousily it ain't that simple. > Yes it is. > > > > How do I get my application to recognize SysInfo? > > And next, how do I use SysInfo in my application > > > > I am missing some information there? > > Any links to some good example maybe that could get me on the road again > > or some hints? > > > > Thanks, > > > > Willy > > hth > Bruce > Bruce and Jussi both thank you very much. After Jussi answering I tried the whole thing in Gambas 3 and it became a lot easier there (way to go... Benoit, thanks). Made a short tutorial based on above example on the Gambas Forum for the Gambas 3 way of doing things, so others might benefit as well and get some insight in how library development works for Gambas 3. Now back to Gambas 2, see if what Bruce explained can be done in real life :-) Bit more work the Gambas 2 way, doing a component. And I see some distribution problems there as well. How to install such a library along with your app that needs the libary? Anyway, if I get it working the Gambas 2 way, I'll do a short tutorial as well, because there is a big lack of documentation on how to do stuff in Gambas. Thanks for the input. Willy P.S. If the short tutorials can be useful somewhere on the Gambas site let me know and I'll add them there. From eilert-sprachen at ...221... Wed Feb 22 17:41:53 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 22 Feb 2012 17:41:53 +0100 Subject: [Gambas-user] String array empty after SUB (Gambas 2) Message-ID: <4F451AD1.5070807@...221...> Now, this is a strange one :-) and I really have no idea what goes wrong here. I've got a dialog which loads a list of names. I'm keeping such SUBs that deal with files in a module called ldsv (brief for load-save). The dialog's part is simple, "ls" is the listbox: PRIVATE felder AS NEW String[] PUBLIC SUB ls_Click() Label1.Text = "Nr. " & schlyssel[ls.Index] & ": " & ls[ls.Index].Text 'here we jump into the SUB: ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) 'now we should see the number of fields loaded: lblTitel.Text = CStr(felder.Count) END Now the SUB in module ldsv: PUBLIC SUB ListeKundeFelder(schlysselnr AS String, felder AS String[]) DIM t$ AS String DIM feld AS NEW String[] felder.Clear t$ = File.Load(pfadKunden &/ schlysselnr & ".kunde") t$ = Tag2Str(t$) feld = Split(t$, Chr$(10)) IF feld[0] = "#!Stein3.1" THEN feld.Delete(0, 2) 'das #! und die ID k?nnen weg felder = feld.Copy() END IF END When I put a stop at the END IF and watch the values, felder will have 16 values from 0 - 15 containing strings just as expected. But when I return to the dialog, felder is empty! This is especially weird as there are other SUBs and FUNCTIONs en masse in my project that do it exactly the same way. I cannot detect any mistake I made - or do you? Regards Rolf From jussi.lahtinen at ...626... Wed Feb 22 18:49:29 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 22 Feb 2012 19:49:29 +0200 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: <4F451AD1.5070807@...221...> References: <4F451AD1.5070807@...221...> Message-ID: Just quick thought... maybe this "felder = feld.Copy()" gives new object reference feld to felder. And because feld is declared locally, the it is null after the sub and so is also felder. Perhaps you need to do "felder = feld.Copy()" manually with for each... Jussi On Wed, Feb 22, 2012 at 18:41, Rolf-Werner Eilert < eilert-sprachen at ...221...> wrote: > Now, this is a strange one :-) and I really have no idea what goes wrong > here. > > I've got a dialog which loads a list of names. I'm keeping such SUBs > that deal with files in a module called ldsv (brief for load-save). > > The dialog's part is simple, "ls" is the listbox: > > PRIVATE felder AS NEW String[] > > PUBLIC SUB ls_Click() > > > Label1.Text = "Nr. " & schlyssel[ls.Index] & ": " & ls[ls.Index].Text > 'here we jump into the SUB: > ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) > 'now we should see the number of fields loaded: > lblTitel.Text = CStr(felder.Count) > > END > > > Now the SUB in module ldsv: > > PUBLIC SUB ListeKundeFelder(schlysselnr AS String, felder AS String[]) > DIM t$ AS String > DIM feld AS NEW String[] > > felder.Clear > > t$ = File.Load(pfadKunden &/ schlysselnr & ".kunde") > t$ = Tag2Str(t$) > > feld = Split(t$, Chr$(10)) > > IF feld[0] = "#!Stein3.1" THEN > feld.Delete(0, 2) 'das #! und die ID k?nnen weg > felder = feld.Copy() > END IF > > END > > When I put a stop at the END IF and watch the values, felder will have > 16 values from 0 - 15 containing strings just as expected. But when I > return to the dialog, felder is empty! This is especially weird as there > are other SUBs and FUNCTIONs en masse in my project that do it exactly > the same way. > > I cannot detect any mistake I made - or do you? > > Regards > > Rolf > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From willy at ...2734... Wed Feb 22 19:34:48 2012 From: willy at ...2734... (Willy Raets) Date: Wed, 22 Feb 2012 19:34:48 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329916348.2358.11.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> <1329873730.3474.30.camel@...2688...> <1329916348.2358.11.camel@...2735...> Message-ID: <1329935688.2358.77.camel@...2735...> > Now back to Gambas 2, see if what Bruce explained can be done in real > life :-) Bit more work the Gambas 2 way, doing a component. And I see > some distribution problems there as well. How to install such a library > along with your app that needs the libary? > Well Bruce, I must say your memory on the matter is excellent. All is exactly as you described it for Gambas 2. Stupid, reading the documentation no way to ever figure it out when it turns out to be just a few simple steps.... Thabk you VERY MUCH.. > Anyway, if I get it working the Gambas 2 way, I'll do a short tutorial > as well, because there is a big lack of documentation on how to do stuff > in Gambas. As promised I did some tutorials with screenshots and source archives. Hope this will be very helpful to people new to the matter. They are both on the Whiteisland Gambas Forum. Make a component (Gambas 2): http://whiteislandsoftware.com/index.php?page=cedi&type=misc&id=1%2F2% 2F4%2F52%2F62&redirected=1&redirected=1 Make a library (Gambas 3): http://whiteislandsoftware.com/index.php?page=cedi&type=misc&id=1%2F2% 2F5%2F49%2F60 There is definatly a great need for good documentation. I am do my best to 'tutorialize' stuff I figure out myself and isn't well documented in the hope this will help others to get going with Gambas because it is a real great language. Willy From adamnt42 at ...626... Wed Feb 22 20:26:46 2012 From: adamnt42 at ...626... (GMail) Date: Thu, 23 Feb 2012 05:56:46 +1030 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: References: <4F451AD1.5070807@...221...> Message-ID: <1329938806.3474.33.camel@...2688...> On Wed, 2012-02-22 at 19:49 +0200, Jussi Lahtinen wrote: > Just quick thought... maybe this "felder = feld.Copy()" gives new object > reference feld to felder. > And because feld is declared locally, the it is null after the sub and so > is also felder. > > Perhaps you need to do "felder = feld.Copy()" manually with for each... > > Jussi > > > > > On Wed, Feb 22, 2012 at 18:41, Rolf-Werner Eilert < > eilert-sprachen at ...221...> wrote: > > > Now, this is a strange one :-) and I really have no idea what goes wrong > > here. > > > > I've got a dialog which loads a list of names. I'm keeping such SUBs > > that deal with files in a module called ldsv (brief for load-save). > > > > The dialog's part is simple, "ls" is the listbox: > > > > PRIVATE felder AS NEW String[] > > > > PUBLIC SUB ls_Click() > > > > > > Label1.Text = "Nr. " & schlyssel[ls.Index] & ": " & ls[ls.Index].Text > > 'here we jump into the SUB: > > ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) > > 'now we should see the number of fields loaded: > > lblTitel.Text = CStr(felder.Count) > > > > END > > > > > > Now the SUB in module ldsv: > > > > PUBLIC SUB ListeKundeFelder(schlysselnr AS String, felder AS String[]) > > DIM t$ AS String > > DIM feld AS NEW String[] > > > > felder.Clear > > > > t$ = File.Load(pfadKunden &/ schlysselnr & ".kunde") > > t$ = Tag2Str(t$) > > > > feld = Split(t$, Chr$(10)) > > > > IF feld[0] = "#!Stein3.1" THEN > > feld.Delete(0, 2) 'das #! und die ID k?nnen weg > > felder = feld.Copy() > > END IF > > > > END Perhaps ... If feld[0] <> "#!Stein3.1" then felder=feld.Copy is never executed! Try IF feld[0] = "#!Stein3.1" THEN feld.Delete(0, 2) 'das #! und die ID k?nnen weg END IF felder = feld.Copy() From willy at ...2734... Thu Feb 23 02:18:27 2012 From: willy at ...2734... (Willy Raets) Date: Thu, 23 Feb 2012 02:18:27 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329935688.2358.77.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> <1329873730.3474.30.camel@...2688...> <1329916348.2358.11.camel@...2735...> <1329935688.2358.77.camel@...2735...> Message-ID: <1329959907.2358.98.camel@...2735...> On wo, 2012-02-22 at 19:34 +0100, Willy Raets wrote: > > Now back to Gambas 2, see if what Bruce explained can be done in real > > life :-) Bit more work the Gambas 2 way, doing a component. And I see > > some distribution problems there as well. How to install such a library > > along with your app that needs the libary? Okay making my component in Gambas 2 worked. Have it at my use in all Gambas 2 projects, really nice. Here is the next problem I encounter. How to distribute the component together with the application that uses it. 1. Do I make a package for the component separate from the application and will the package installer recognise it as a component and do the right thing? (I guess not, but hey..you never know...)? 2. Do I simply make a package for the application and the component will be included and installed properly? 3. Or do I need to provide a source archive and do people need to install IDE to make the component local themselves (something not really handy when making applications for not programming audience)? 4. Or is there another way? I can see how Gambas 3 takes care of this with the library in the project folder, that just gets installed with the application. Way easier and I would love to port my application to Gambas 3. This application is still in Gambas 2 for easy Distribution reasons only. Gambas 3 missing in repos makes distributing Gambas 3 applications virtually impossible for the moment. Can't expect people to compile their own version just for the sake of running my application... As soon as the major distros have it available in their software repos I'm leaving Gambas 2. Can't wait... From willy at ...2734... Thu Feb 23 02:31:57 2012 From: willy at ...2734... (Willy Raets) Date: Thu, 23 Feb 2012 02:31:57 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329959907.2358.98.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> <1329873730.3474.30.camel@...2688...> <1329916348.2358.11.camel@...2735...> <1329935688.2358.77.camel@...2735...> <1329959907.2358.98.camel@...2735...> Message-ID: <1329960717.2358.102.camel@...2735...> On do, 2012-02-23 at 02:18 +0100, Willy Raets wrote: > On wo, 2012-02-22 at 19:34 +0100, Willy Raets wrote: > > > Now back to Gambas 2, see if what Bruce explained can be done in real > > > life :-) Bit more work the Gambas 2 way, doing a component. And I see > > > some distribution problems there as well. How to install such a library > > > along with your app that needs the libary? > > Okay making my component in Gambas 2 worked. > Have it at my use in all Gambas 2 projects, really nice. > > Here is the next problem I encounter. > How to distribute the component together with the application that uses > it. > Oeps, a bit to fast, forgot to check the documentation on that... Sorry..., but yet still a question. Documentation says (this is Gambas 2 documentation): If you want to distribute your component, you will have to name it by following a precise scheme, so that components packages do not conflict. The name of your component will have to be: gambas3-vendor-name naming it gambas3-vendor-name makes little sense. shouldn't that be gambas2-vendor-name? Is it a typo? Thanks, Willy From willy at ...2734... Thu Feb 23 03:14:01 2012 From: willy at ...2734... (Willy Raets) Date: Thu, 23 Feb 2012 03:14:01 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329960717.2358.102.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> <1329873730.3474.30.camel@...2688...> <1329916348.2358.11.camel@...2735...> <1329935688.2358.77.camel@...2735...> <1329959907.2358.98.camel@...2735...> <1329960717.2358.102.camel@...2735...> Message-ID: <1329963241.2358.106.camel@...2735...> > naming it gambas3-vendor-name makes little sense. > shouldn't that be gambas2-vendor-name? Is it a typo? > Gambas puts gambas2 there by itself when making the package. Reading the documentation gave me the idea I had to name it manually some where (instead of it being done automatic) Problem solved, component distributable. Thanks for reading...:-) From vuott at ...325... Thu Feb 23 03:56:12 2012 From: vuott at ...325... (Ru Vuott) Date: Thu, 23 Feb 2012 02:56:12 +0000 (GMT) Subject: [Gambas-user] Paint.arc does not proceed counter-clockwise during Length radians Message-ID: <1329965772.51899.YahooMailClassic@...2748...> Hello, in Gambas 3 by using positive values in Length parameter of "Paint.Arc" I noticed that it does not proceed counter-clockwise, but clockwise ! I obtain counter-clockwise, if I use "negative" values. ??? Vuott From kevinfishburne at ...1887... Thu Feb 23 06:16:36 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Thu, 23 Feb 2012 00:16:36 -0500 Subject: [Gambas-user] For...Next loop efficiency question Message-ID: <4F45CBB4.6000507@...1887...> If the ranges of a For...Next loop require calculations, are they slower than a loop which doesn't? In other words, is the first example below faster than the second? For Counter = 1 To 100 Next For Counter = 100 / 100 + 1 - 1 To 100 / 100 + 1 - 1 + 99 Next Does it make any difference if the calculations use variables versus explicit numbers like in my example? Modifier = 100 For Counter = 1 + Modifier To 100 + Modifier Next I guess what I'm getting at is, is the calculation performed once at the beginning of the loop, or is the calculation performed repeatedly, after every Next? -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From emil.lenngren at ...626... Thu Feb 23 09:04:33 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Thu, 23 Feb 2012 09:04:33 +0100 Subject: [Gambas-user] For...Next loop efficiency question In-Reply-To: <4F45CBB4.6000507@...1887...> References: <4F45CBB4.6000507@...1887...> Message-ID: The calculation is done only once in the beginning of the loop. /Emil 2012/2/23 Kevin Fishburne > If the ranges of a For...Next loop require calculations, are they slower > than a loop which doesn't? In other words, is the first example below > faster than the second? > > For Counter = 1 To 100 > Next > > For Counter = 100 / 100 + 1 - 1 To 100 / 100 + 1 - 1 + 99 > Next > > Does it make any difference if the calculations use variables versus > explicit numbers like in my example? > > Modifier = 100 > For Counter = 1 + Modifier To 100 + Modifier > Next > > I guess what I'm getting at is, is the calculation performed once at the > beginning of the loop, or is the calculation performed repeatedly, after > every Next? > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From eilert-sprachen at ...221... Thu Feb 23 09:09:53 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 23 Feb 2012 09:09:53 +0100 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: References: <4F451AD1.5070807@...221...> Message-ID: <4F45F451.5040007@...221...> That was it, Jussi, thanks a lot! Here we can see what it is good for to know about OOP :-) Regards Rolf Am 22.02.2012 18:49, schrieb Jussi Lahtinen: > Just quick thought... maybe this "felder = feld.Copy()" gives new object > reference feld to felder. > And because feld is declared locally, the it is null after the sub and so > is also felder. > > Perhaps you need to do "felder = feld.Copy()" manually with for each... > > Jussi > > > > > On Wed, Feb 22, 2012 at 18:41, Rolf-Werner Eilert< > eilert-sprachen at ...221...> wrote: > >> Now, this is a strange one :-) and I really have no idea what goes wrong >> here. >> >> I've got a dialog which loads a list of names. I'm keeping such SUBs >> that deal with files in a module called ldsv (brief for load-save). >> >> The dialog's part is simple, "ls" is the listbox: >> >> PRIVATE felder AS NEW String[] >> >> PUBLIC SUB ls_Click() >> >> >> Label1.Text = "Nr. "& schlyssel[ls.Index]& ": "& ls[ls.Index].Text >> 'here we jump into the SUB: >> ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) >> 'now we should see the number of fields loaded: >> lblTitel.Text = CStr(felder.Count) >> >> END >> >> >> Now the SUB in module ldsv: >> >> PUBLIC SUB ListeKundeFelder(schlysselnr AS String, felder AS String[]) >> DIM t$ AS String >> DIM feld AS NEW String[] >> >> felder.Clear >> >> t$ = File.Load(pfadKunden&/ schlysselnr& ".kunde") >> t$ = Tag2Str(t$) >> >> feld = Split(t$, Chr$(10)) >> >> IF feld[0] = "#!Stein3.1" THEN >> feld.Delete(0, 2) 'das #! und die ID k?nnen weg >> felder = feld.Copy() >> END IF >> >> END >> >> When I put a stop at the END IF and watch the values, felder will have >> 16 values from 0 - 15 containing strings just as expected. But when I >> return to the dialog, felder is empty! This is especially weird as there >> are other SUBs and FUNCTIONs en masse in my project that do it exactly >> the same way. >> >> I cannot detect any mistake I made - or do you? >> >> Regards >> >> Rolf >> >> >> >> ------------------------------------------------------------------------------ >> Virtualization& Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > ------------------------------------------------------------------------------ > Virtualization& Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From eilert-sprachen at ...221... Thu Feb 23 09:13:04 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 23 Feb 2012 09:13:04 +0100 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: <1329938806.3474.33.camel@...2688...> References: <4F451AD1.5070807@...221...> <1329938806.3474.33.camel@...2688...> Message-ID: <4F45F510.6020900@...221...> Am 22.02.2012 20:26, schrieb GMail: > On Wed, 2012-02-22 at 19:49 +0200, Jussi Lahtinen wrote: >> Just quick thought... maybe this "felder = feld.Copy()" gives new object >> reference feld to felder. >> And because feld is declared locally, the it is null after the sub and so >> is also felder. >> >> Perhaps you need to do "felder = feld.Copy()" manually with for each... >> >> Jussi >> >> >> >> >> On Wed, Feb 22, 2012 at 18:41, Rolf-Werner Eilert< >> eilert-sprachen at ...221...> wrote: >> >>> Now, this is a strange one :-) and I really have no idea what goes wrong >>> here. >>> >>> I've got a dialog which loads a list of names. I'm keeping such SUBs >>> that deal with files in a module called ldsv (brief for load-save). >>> >>> The dialog's part is simple, "ls" is the listbox: >>> >>> PRIVATE felder AS NEW String[] >>> >>> PUBLIC SUB ls_Click() >>> >>> >>> Label1.Text = "Nr. "& schlyssel[ls.Index]& ": "& ls[ls.Index].Text >>> 'here we jump into the SUB: >>> ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) >>> 'now we should see the number of fields loaded: >>> lblTitel.Text = CStr(felder.Count) >>> >>> END >>> >>> >>> Now the SUB in module ldsv: >>> >>> PUBLIC SUB ListeKundeFelder(schlysselnr AS String, felder AS String[]) >>> DIM t$ AS String >>> DIM feld AS NEW String[] >>> >>> felder.Clear >>> >>> t$ = File.Load(pfadKunden&/ schlysselnr& ".kunde") >>> t$ = Tag2Str(t$) >>> >>> feld = Split(t$, Chr$(10)) >>> >>> IF feld[0] = "#!Stein3.1" THEN >>> feld.Delete(0, 2) 'das #! und die ID k?nnen weg >>> felder = feld.Copy() >>> END IF >>> >>> END > Perhaps ... If feld[0]<> "#!Stein3.1" then felder=feld.Copy is never > executed! Try > > IF feld[0] = "#!Stein3.1" THEN > feld.Delete(0, 2) 'das #! und die ID k?nnen weg > END IF > felder = feld.Copy() > This was my first thought, too. But when I checked the values at the time of END IF, everything was as expected. Jussi had the right idea: the problem is the .Copy itself. Maybe we should mention this in the docs, within the text for .Copy for instance. Rolf From eilert-sprachen at ...221... Thu Feb 23 09:20:17 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Thu, 23 Feb 2012 09:20:17 +0100 Subject: [Gambas-user] For...Next loop efficiency question In-Reply-To: <4F45CBB4.6000507@...1887...> References: <4F45CBB4.6000507@...1887...> Message-ID: <4F45F6C1.8060605@...221...> Kevin, As far as I found out, it is done only once at the beginning. Just make a test: set a stop point before the loop, and than make single steps through the loop watching the local variables. I use this for getting clear about efficiency from time to time, and I found it a pretty eye-opener on how my programs actually are running. Rolf Am 23.02.2012 06:16, schrieb Kevin Fishburne: > If the ranges of a For...Next loop require calculations, are they slower > than a loop which doesn't? In other words, is the first example below > faster than the second? > > For Counter = 1 To 100 > Next > > For Counter = 100 / 100 + 1 - 1 To 100 / 100 + 1 - 1 + 99 > Next > > Does it make any difference if the calculations use variables versus > explicit numbers like in my example? > > Modifier = 100 > For Counter = 1 + Modifier To 100 + Modifier > Next > > I guess what I'm getting at is, is the calculation performed once at the > beginning of the loop, or is the calculation performed repeatedly, after > every Next? > From emil.lenngren at ...626... Thu Feb 23 09:33:47 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Thu, 23 Feb 2012 09:33:47 +0100 Subject: [Gambas-user] For...Next loop efficiency question In-Reply-To: <4F45F6C1.8060605@...221...> References: <4F45CBB4.6000507@...1887...> <4F45F6C1.8060605@...221...> Message-ID: Gambas is open source, so you can always look in the source code how everything is implemented. e.g. look in gbx_exec_loop.c and look for jump_next. /Emil 2012/2/23 Rolf-Werner Eilert > Kevin, > > As far as I found out, it is done only once at the beginning. Just make > a test: set a stop point before the loop, and than make single steps > through the loop watching the local variables. > > I use this for getting clear about efficiency from time to time, and I > found it a pretty eye-opener on how my programs actually are running. > > Rolf > > Am 23.02.2012 06:16, schrieb Kevin Fishburne: > > If the ranges of a For...Next loop require calculations, are they slower > > than a loop which doesn't? In other words, is the first example below > > faster than the second? > > > > For Counter = 1 To 100 > > Next > > > > For Counter = 100 / 100 + 1 - 1 To 100 / 100 + 1 - 1 + 99 > > Next > > > > Does it make any difference if the calculations use variables versus > > explicit numbers like in my example? > > > > Modifier = 100 > > For Counter = 1 + Modifier To 100 + Modifier > > Next > > > > I guess what I'm getting at is, is the calculation performed once at the > > beginning of the loop, or is the calculation performed repeatedly, after > > every Next? > > > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From bbruen at ...2308... Thu Feb 23 09:48:10 2012 From: bbruen at ...2308... (Bruce Bruen) Date: Thu, 23 Feb 2012 19:18:10 +1030 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: <4F45F451.5040007@...221...> References: <4F451AD1.5070807@...221...> <4F45F451.5040007@...221...> Message-ID: <1329986890.3474.42.camel@...2688...> On Thu, 2012-02-23 at 09:09 +0100, Rolf-Werner Eilert wrote: > That was it, Jussi, thanks a lot! > > Here we can see what it is good for to know about OOP :-) > > Regards > > Rolf > > Am 22.02.2012 18:49, schrieb Jussi Lahtinen: > > Just quick thought... maybe this "felder = feld.Copy()" gives new object > > reference feld to felder. > > And because feld is declared locally, the it is null after the sub and so > > is also felder. > > > > Perhaps you need to do "felder = feld.Copy()" manually with for each... > > > > Jussi > > > > Interesting! I must admit that I have never used String[].Copy but I would have expected that a "deep" copy meant that every string in the array was copied to the target array, not just that a reference was created. So what is the difference between felder=feld and felder=feld.Copy ? In the former case I would expect a reference but in the latter I would have assumed a full transfer of the whole array replacing whatever was in felder. Further, within the example quoted by Rolf, if I explicitly copy every string in feld to felder, viz Dim wkStr as String felder.Clear (or felder = New String[] **) for each wkstr in feld felder.Add(wkstr) next will it work? ** the latter would be interesting, re-initialising a String[] array in a called routine??? Bruce From kevinfishburne at ...1887... Thu Feb 23 11:31:04 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Thu, 23 Feb 2012 05:31:04 -0500 Subject: [Gambas-user] For...Next loop efficiency question In-Reply-To: References: <4F45CBB4.6000507@...1887...> <4F45F6C1.8060605@...221...> Message-ID: <4F461568.2030906@...1887...> Thank you everyone, that information is extremely useful. You can also time several repetitions of the code and compare the results. It seems declaration and pre computation of variables involved in a For...Next loop isn't necessary other than for legibility, which is awesome. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From emil.lenngren at ...626... Thu Feb 23 13:21:37 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Thu, 23 Feb 2012 13:21:37 +0100 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: <1329986890.3474.42.camel@...2688...> References: <4F451AD1.5070807@...221...> <4F45F451.5040007@...221...> <1329986890.3474.42.camel@...2688...> Message-ID: The problem is not that feld.copy does not copy the array or something like that, it really returns a NEW deep copy of the array, i.e. a new object. When you call the function by executing ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) you pass the reference to a String[] you want to populate with data. But, if you run felder = feld.copy() in the ListeKundeFelder, you don't populate the passed array with data, but instead throw away the reference and create a new array that is assigned to the local variable felder (which gets removed when the function exits). You can use the Insert method on the String[], which does the job: felder.Insert(feld) Another option would be to pass the felder String[] by reference. That should actually be more optimized in this case since all you want is to replace the instance variable felder array (in the caller) by another array that is generated by ListeKundeFelder. Then no array copy has to be done. (Why copy an array if you want to remove the source array right after?) Or even better, let the ListeKundeFelder return a new array that you can assign to the felder instance variable ;) /Emil 2012/2/23 Bruce Bruen > On Thu, 2012-02-23 at 09:09 +0100, Rolf-Werner Eilert wrote: > > That was it, Jussi, thanks a lot! > > > > Here we can see what it is good for to know about OOP :-) > > > > Regards > > > > Rolf > > > > Am 22.02.2012 18:49, schrieb Jussi Lahtinen: > > > Just quick thought... maybe this "felder = feld.Copy()" gives new > object > > > reference feld to felder. > > > And because feld is declared locally, the it is null after the sub and > so > > > is also felder. > > > > > > Perhaps you need to do "felder = feld.Copy()" manually with for each... > > > > > > Jussi > > > > > > > Interesting! I must admit that I have never used String[].Copy but I > would have expected that a "deep" copy meant that every string in the > array was copied to the target array, not just that a reference was > created. > > So what is the difference between > felder=feld > and > felder=feld.Copy > ? > > In the former case I would expect a reference but in the latter I would > have assumed a full transfer of the whole array replacing whatever was > in felder. > > Further, within the example quoted by Rolf, if I explicitly copy every > string in feld to felder, viz > Dim wkStr as String > felder.Clear (or felder = New String[] **) > for each wkstr in feld > felder.Add(wkstr) > next > will it work? > > ** the latter would be interesting, re-initialising a String[] array in > a called routine??? > > Bruce > > > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jussi.lahtinen at ...626... Thu Feb 23 17:21:42 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Thu, 23 Feb 2012 18:21:42 +0200 Subject: [Gambas-user] For...Next loop efficiency question In-Reply-To: <4F461568.2030906@...1887...> References: <4F45CBB4.6000507@...1887...> <4F45F6C1.8060605@...221...> <4F461568.2030906@...1887...> Message-ID: Nested loops are of course different thing... Jussi On Thu, Feb 23, 2012 at 12:31, Kevin Fishburne < kevinfishburne at ...1887...> wrote: > Thank you everyone, that information is extremely useful. You can also > time several repetitions of the code and compare the results. It seems > declaration and pre computation of variables involved in a For...Next > loop isn't necessary other than for legibility, which is awesome. > > -- > Kevin Fishburne > Eight Virtues > www: http://sales.eightvirtues.com > e-mail: sales at ...1887... > phone: (770) 853-6271 > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From nando_f at ...951... Thu Feb 23 21:51:32 2012 From: nando_f at ...951... (nando) Date: Thu, 23 Feb 2012 15:51:32 -0500 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: <4F451AD1.5070807@...221...> References: <4F451AD1.5070807@...221...> Message-ID: <20120223204922.M33657@...951...> felder as STRING[] is a parameter passed into sub It is no good outside of SUB What you should do is make your sub PUBLIC FUNCTION ListeKundeFelder(schlysselnr AS String, felder AS String[]) AS STRING[] and return the string[], assigning it to the original felder[] -Fernando ---------- Original Message ----------- From: Rolf-Werner Eilert To: mailing list for gambas users Sent: Wed, 22 Feb 2012 17:41:53 +0100 Subject: [Gambas-user] String array empty after SUB (Gambas 2) > Now, this is a strange one :-) and I really have no idea what goes wrong > here. > > I've got a dialog which loads a list of names. I'm keeping such SUBs > that deal with files in a module called ldsv (brief for load-save). > > The dialog's part is simple, "ls" is the listbox: > > PRIVATE felder AS NEW String[] > > PUBLIC SUB ls_Click() > > Label1.Text = "Nr. " & schlyssel[ls.Index] & ": " & ls[ls.Index].Text > 'here we jump into the SUB: > ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) > 'now we should see the number of fields loaded: > lblTitel.Text = CStr(felder.Count) > > END > > Now the SUB in module ldsv: > > PUBLIC SUB ListeKundeFelder(schlysselnr AS String, felder AS String[]) > DIM t$ AS String > DIM feld AS NEW String[] > > felder.Clear > > t$ = File.Load(pfadKunden &/ schlysselnr & ".kunde") > t$ = Tag2Str(t$) > > feld = Split(t$, Chr$(10)) > > IF feld[0] = "#!Stein3.1" THEN > feld.Delete(0, 2) 'das #! und die ID k?nnen weg > felder = feld.Copy() > END IF > > END > > When I put a stop at the END IF and watch the values, felder will have > 16 values from 0 - 15 containing strings just as expected. But when I > return to the dialog, felder is empty! This is especially weird as there > are other SUBs and FUNCTIONs en masse in my project that do it exactly > the same way. > > I cannot detect any mistake I made - or do you? > > Regards > > Rolf > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From mohareve at ...626... Thu Feb 23 23:58:36 2012 From: mohareve at ...626... (M. Cs.) Date: Thu, 23 Feb 2012 23:58:36 +0100 Subject: [Gambas-user] I need your help, please! Message-ID: I have few simple questions: what is happening practically with the memory when I open a file and start to read it in into a local variable called myvar? It would be logical for myvar to grow until it reads in the entire file. My question is: - does Gambas clear the memory allocations after the myvar is cleared? - or there will be always a bloated memory usage which is freed only after the main program is closed? - Gambas uses only few % of CPU for reading in the file (.csv). Is this possible to increase the percentage in order to speed up the process? I need your answers please! Csaba From emil.lenngren at ...626... Fri Feb 24 00:00:54 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Fri, 24 Feb 2012 00:00:54 +0100 Subject: [Gambas-user] I need your help, please! In-Reply-To: References: Message-ID: How large is your csv-file? If it is large then probably much time is spent when transfering the data from your hard drive into memory. /Emil 2012/2/23 M. Cs. > I have few simple questions: > what is happening practically with the memory when I open a file and > start to read it in into a local variable called myvar? > It would be logical for myvar to grow until it reads in the entire file. > My question is: > - does Gambas clear the memory allocations after the myvar is cleared? > - or there will be always a bloated memory usage which is freed only > after the main program is closed? > - Gambas uses only few % of CPU for reading in the file (.csv). Is > this possible to increase the percentage in order to speed up the > process? > > I need your answers please! > > Csaba > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From kevinfishburne at ...1887... Fri Feb 24 07:52:21 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Fri, 24 Feb 2012 01:52:21 -0500 Subject: [Gambas-user] For...Next loop efficiency question In-Reply-To: References: <4F45CBB4.6000507@...1887...> <4F45F6C1.8060605@...221...> <4F461568.2030906@...1887...> Message-ID: <4F4733A5.9050200@...1887...> On 02/23/2012 11:21 AM, Jussi Lahtinen wrote: > Nested loops are of course different thing... > > Jussi I was about to ask in what way, then I realized that the "inner" loop would have to be recalculated every time the "outer" loop executed. Good call there. :) -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From mohareve at ...626... Fri Feb 24 09:51:44 2012 From: mohareve at ...626... (M. Cs.) Date: Fri, 24 Feb 2012 09:51:44 +0100 Subject: [Gambas-user] I need your help, please! In-Reply-To: References: Message-ID: It is about 3MB and I use to read it with While not Eof() Line Input .... Wend My biggest problem is, that, regardless to the approach, (using a module for a task, or using a class instance for the same task) I cannot regain the idling memory: I've red in the file, and I have been placing the data into a database, and I can even clear the array, or use a local variable, but the amount of used memory remains the same just as when I would still use the variable. This is either my fault (I am doing something wrong), or Gambas' error, because it does not handles back the currently not used memory to the system. I don't know what's wrong. 2012/2/24, Emil Lenngren : > How large is your csv-file? If it is large then probably much time is spent > when transfering the data from your hard drive into memory. > > /Emil > > 2012/2/23 M. Cs. > >> I have few simple questions: >> what is happening practically with the memory when I open a file and >> start to read it in into a local variable called myvar? >> It would be logical for myvar to grow until it reads in the entire file. >> My question is: >> - does Gambas clear the memory allocations after the myvar is cleared? >> - or there will be always a bloated memory usage which is freed only >> after the main program is closed? >> - Gambas uses only few % of CPU for reading in the file (.csv). Is >> this possible to increase the percentage in order to speed up the >> process? >> >> I need your answers please! >> >> Csaba >> >> >> ------------------------------------------------------------------------------ >> Virtualization & Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Fri Feb 24 12:12:02 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Fri, 24 Feb 2012 12:12:02 +0100 Subject: [Gambas-user] I need your help, please! In-Reply-To: References: Message-ID: <4F477082.8050402@...1...> Le 24/02/2012 09:51, M. Cs. a ?crit : > It is about 3MB and I use to read it with > While not Eof() > Line Input .... > Wend > > My biggest problem is, that, regardless to the approach, (using a > module for a task, or using a class instance for the same task) I > cannot regain the idling memory: > I've red in the file, and I have been placing the data into a > database, and I can even clear the array, or use a local variable, but > the amount of used memory remains the same just as when I would still > use the variable. This is either my fault (I am doing something > wrong), or Gambas' error, because it does not handles back the > currently not used memory to the system. I don't know what's wrong. > It's hard to guess without seeing the full source code! -- Beno?t Minisini From peter.scholtz at ...2778... Fri Feb 24 14:44:47 2012 From: peter.scholtz at ...2778... (Peter Scholtz - Isenzo) Date: Fri, 24 Feb 2012 15:44:47 +0200 Subject: [Gambas-user] How to compile the Gambas3 runtime Message-ID: <7A083A97D08648EFA36E1FBF745A91F6@...2779...> Hi all, I'm new to Linux and Gambas. I've written an application and managed to distribute it to a newly installed Ubuntu 11.04 using the runtime available here: https://launchpad.net/~ihaywood3/+archive/gambas3 These are not the latest runtime, 2.99 vs 3 and there is none for the latest Ubuntu 11.10 Could you please explain to a n00b how I can compile the runtime for the latest Ubuntu 11.10 and how to place it into a repository? Thank you in advance. From matteo.pasotti at ...626... Fri Feb 24 15:21:33 2012 From: matteo.pasotti at ...626... (Matteo Pasotti) Date: Fri, 24 Feb 2012 15:21:33 +0100 Subject: [Gambas-user] How to compile the Gambas3 runtime In-Reply-To: <7A083A97D08648EFA36E1FBF745A91F6@...2779...> References: <7A083A97D08648EFA36E1FBF745A91F6@...2779...> Message-ID: <4F479CED.4030505@...626...> -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Il 24/02/2012 14:44, Peter Scholtz - Isenzo ha scritto: > Hi all, > > I'm new to Linux and Gambas. > > I've written an application and managed to distribute it to a newly > installed Ubuntu 11.04 using the runtime available here: > https://launchpad.net/~ihaywood3/+archive/gambas3 > > These are not the latest runtime, 2.99 vs 3 and there is none for the latest > Ubuntu 11.10 > > Could you please explain to a n00b how I can compile the runtime for the > latest Ubuntu 11.10 and how to place it into a repository? > > Thank you in advance. > Hi Peter, have you tried http://gambasdoc.org/help/install?v3 ? Then before duplicating repositories maybe you can talk to ihaywood3 and ask him to upgrade his repo. Regards, - -- Matteo -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mageia - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJPR5zpAAoJED3LowjDDWbNcS4H/jxeRJVGmuPBR5hVCorml6gt SajHIQEd1QmnHmxEKm03lb4b5FhaKrau9PoHp9nobHTpGnJYiXE1e+/3wadqruhZ ONgYfKTfjQWabffHV4uxAhmcIhHv98XD403OtWt0hBm2H92GsE3jhi0dsugP3QnY jogJl61HnlEYRs4WHWh2c3VD/LNdkTM1ZO2PRbBy86ryCiB6GG540kGFvHP8IkzU vicu1kLfAK5dIA/jaDvKsct8fGOOYLtlmKv8GQz6wEQ7lzDYiatWm9o1Oitn1Dw5 wAy1IFs8sViI5UP/HeQEGTlPxzhpvmGkm29F2r0ssjUSfnIPHFTJhr5BIvk0BlQ= =3/IG -----END PGP SIGNATURE----- From mohareve at ...626... Fri Feb 24 15:44:16 2012 From: mohareve at ...626... (M. Cs.) Date: Fri, 24 Feb 2012 15:44:16 +0100 Subject: [Gambas-user] How to compile the Gambas3 runtime In-Reply-To: <4F479CED.4030505@...626...> References: <7A083A97D08648EFA36E1FBF745A91F6@...2779...> <4F479CED.4030505@...626...> Message-ID: Add this to your sources: deb http://ppa.launchpad.net/nemh/gambas3/ubuntu oneiric main It is Kendek's repository and works fully. Csaba 2012/2/24, Matteo Pasotti : > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Il 24/02/2012 14:44, Peter Scholtz - Isenzo ha scritto: >> Hi all, >> >> I'm new to Linux and Gambas. >> >> I've written an application and managed to distribute it to a newly >> installed Ubuntu 11.04 using the runtime available here: >> https://launchpad.net/~ihaywood3/+archive/gambas3 >> >> These are not the latest runtime, 2.99 vs 3 and there is none for the >> latest >> Ubuntu 11.10 >> >> Could you please explain to a n00b how I can compile the runtime for the >> latest Ubuntu 11.10 and how to place it into a repository? >> >> Thank you in advance. >> > > Hi Peter, > have you tried http://gambasdoc.org/help/install?v3 ? > Then before duplicating repositories maybe you can talk to ihaywood3 and > ask him to upgrade his repo. > Regards, > - -- > Matteo > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.11 (GNU/Linux) > Comment: Using GnuPG with Mageia - http://enigmail.mozdev.org/ > > iQEcBAEBAgAGBQJPR5zpAAoJED3LowjDDWbNcS4H/jxeRJVGmuPBR5hVCorml6gt > SajHIQEd1QmnHmxEKm03lb4b5FhaKrau9PoHp9nobHTpGnJYiXE1e+/3wadqruhZ > ONgYfKTfjQWabffHV4uxAhmcIhHv98XD403OtWt0hBm2H92GsE3jhi0dsugP3QnY > jogJl61HnlEYRs4WHWh2c3VD/LNdkTM1ZO2PRbBy86ryCiB6GG540kGFvHP8IkzU > vicu1kLfAK5dIA/jaDvKsct8fGOOYLtlmKv8GQz6wEQ7lzDYiatWm9o1Oitn1Dw5 > wAy1IFs8sViI5UP/HeQEGTlPxzhpvmGkm29F2r0ssjUSfnIPHFTJhr5BIvk0BlQ= > =3/IG > -----END PGP SIGNATURE----- > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From willy at ...2734... Fri Feb 24 23:25:33 2012 From: willy at ...2734... (Willy Raets) Date: Fri, 24 Feb 2012 23:25:33 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1329963241.2358.106.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> <1329873730.3474.30.camel@...2688...> <1329916348.2358.11.camel@...2735...> <1329935688.2358.77.camel@...2735...> <1329959907.2358.98.camel@...2735...> <1329960717.2358.102.camel@...2735...> <1329963241.2358.106.camel@...2735...> Message-ID: <1330122333.2884.29.camel@...2735...> > Gambas puts gambas2 there by itself when making the package. > Reading the documentation gave me the idea I had to name it manually > some where (instead of it being done automatic) > > Problem solved, component distributable. > Thanks for reading...:-) I installed the component and use it in one of my Gambas 2 projects now. When testing in IDE all works great. Next I make an installation package of the application. When installing it on my system it complains that a dependency is missing (my own component which is installed on my system!!!). "Dependency is not satisfiable: gambas2-SysInfo (>= -1.90.1)" But how can the dependency be missing when I installed the component prior to the application? What I noticed with the name of the component during packaging is this Name: gambas2-esb-SysInfo-0.0.1 In Project/Properties - Tab components is shows as SysInfo In dependencies it asks for gambas2-SysInfo Where did the esb go too? Might that be causing the problem? And where does this strange version dependency come from (>= -1.90.1)??? Both component and application are an Ubuntu package made with Gambas 2.22 on Ubuntu 10.10. Any ideas? From willy at ...2734... Fri Feb 24 23:33:58 2012 From: willy at ...2734... (Willy Raets) Date: Fri, 24 Feb 2012 23:33:58 +0100 Subject: [Gambas-user] How to make Class file to Library for use in other Gambas applications In-Reply-To: <1330122333.2884.29.camel@...2735...> References: <1329869015.2330.57.camel@...2735...> <1329873730.3474.30.camel@...2688...> <1329916348.2358.11.camel@...2735...> <1329935688.2358.77.camel@...2735...> <1329959907.2358.98.camel@...2735...> <1329960717.2358.102.camel@...2735...> <1329963241.2358.106.camel@...2735...> <1330122333.2884.29.camel@...2735...> Message-ID: <1330122838.2884.32.camel@...2735...> > I installed the component and use it in one of my Gambas 2 projects now. > When testing in IDE all works great. > Next I make an installation package of the application. > > When installing it on my system it complains that a dependency is > missing (my own component which is installed on my system!!!). > "Dependency is not satisfiable: gambas2-SysInfo (>= -1.90.1)" > > But how can the dependency be missing when I installed the component > prior to the application? > > What I noticed with the name of the component during packaging is this > Name: gambas2-esb-SysInfo-0.0.1 > In Project/Properties - Tab components is shows as SysInfo > In dependencies it asks for gambas2-SysInfo > > Where did the esb go too? Might that be causing the problem? > And where does this strange version dependency come from (>= -1.90.1)??? > > Both component and application are an Ubuntu package made with Gambas > 2.22 on Ubuntu 10.10. > > Any ideas? And I just noticed that in the Ubuntu software center the component is amongst the gambas2 components but named esb-sysinfo while dependency asks for gambas2-SysInfo (two quite different names!!) Really hope someone can help on this one.. Thanks, Willy From gambas at ...2524... Sat Feb 25 11:18:44 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sat, 25 Feb 2012 10:18:44 +0000 Subject: [Gambas-user] Issue 216 in gambas: Gambas3 reports CReportBrush version too recent. Please upgrade upon make install of 4506 Message-ID: <0-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 216 by imperiou... at ...2360...: Gambas3 reports CReportBrush version too recent. Please upgrade upon make install of 4506 http://code.google.com/p/gambas/issues/detail?id=216 Upon compiling and make, make install I see Compiling Database/PictureDatabase/... FormPictureDatabase.class:100011: error: Unknown identifier: Gridview Then when trying to execute the gambas3 executable I get: Error: #2: Cannot load class 'CReportBrush': Version too recent. Please upgrade Gambas. 2) GIVE THE FOLLOWING INFORMATIONS (if they are appropriate): Version: TRUNK Revision: r4506 Operating system: Linux Distribution: Fedora 16 (and also 15) Architecture: x86_64 GUI component: QT3 / QT4 / GTK+ Desktop used: KDE ... 3) Simply compiling and running to run svn trunk version 4506. From gambas at ...1... Sat Feb 25 14:56:26 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 25 Feb 2012 14:56:26 +0100 Subject: [Gambas-user] DataSource & DataBrowser problem In-Reply-To: <1328628354.4661.14.camel@...2661...> References: <1328628354.4661.14.camel@...2661...> Message-ID: <4F48E88A.1000305@...1...> Le 07/02/2012 16:25, John Rose a ?crit : > Thanks, Benoit, for your explanation. Now that I've deleted the > DataBrowserCountry control& created it again inside the > DataSourceCountry control, I now see the countries (i.e. France& Great > Britain) in the DataBrowserCountry control. > Hi, I have completely rewrote the GridView control since revision #4505. The GridView is the base of the TableView, DataView and DataBrowser control. Moreover, I have fixed some bugs in DataView and DataBrowser. Can you check that and tell me if it fixed some of your problems? Regards, -- Beno?t Minisini From gambas at ...1... Sat Feb 25 15:02:33 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 25 Feb 2012 15:02:33 +0100 Subject: [Gambas-user] GridView rewrote Message-ID: <4F48E9F9.8030101@...1...> Hi folks, I have rewritten the GridView control entirely in Gambas since revision #4505. Normally, it is completely compatible with the old GridView. If you have problems with it, just tell me. I did this rewrite because the gb.qt4 and gb.gtk GridView were not able to handle millions of lines without eating all the memory. And displaying millions of lines is needed with huge database tables. So now GridView can handle many lines, but DataView has to memorize the keys of each table record, so a request that returns millions of records uses a lot of memory yet. But far less than before. Regards, -- Beno?t Minisini From gambas at ...1... Sat Feb 25 15:06:49 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 25 Feb 2012 15:06:49 +0100 Subject: [Gambas-user] Paint.arc does not proceed counter-clockwise during Length radians In-Reply-To: <1329965772.51899.YahooMailClassic@...2748...> References: <1329965772.51899.YahooMailClassic@...2748...> Message-ID: <4F48EAF9.6030304@...1...> Le 23/02/2012 03:56, Ru Vuott a ?crit : > Hello, > > in Gambas 3 by using positive values in Length parameter of "Paint.Arc" I noticed that it does not proceed counter-clockwise, but clockwise ! > I obtain counter-clockwise, if I use "negative" values. > > ??? > > Vuott > I may be wrong, but it follows the mathematical standard, i.e. positive angles process counter-clockwise with X axis going from left to right and Y axis going from bottom to top. As the Y axis goes from top to bottom by default with computer, positive angles proceed clockwise! Regards, -- Beno?t Minisini From gambas at ...1... Sat Feb 25 15:17:55 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sat, 25 Feb 2012 15:17:55 +0100 Subject: [Gambas-user] Expander control - two questions In-Reply-To: <1329433195.26010.14.camel@...2688...> References: <1329433195.26010.14.camel@...2688...> Message-ID: <4F48ED93.9010304@...1...> Le 16/02/2012 23:59, Bruce Bruen a ?crit : > Hi folks, > > 1) Is it possible to change the height of the header of the expander, > i.e. the bit that remains visible when it is collapsed? > At the moment, it is too high for one line and too short for two. No. The height is a multiple of Desktop.Scale, high enough for the included text title. > > 2) Is it possible to change the height of the expanded view depending on > the size of its' contents, when the contents are a "view" control? You must do that by hand. > > I would like to use the expander as a fancy combo box, with a tableview > inside it, listing selections in some detail and when a selection is > made, then showing a summary of the selected row in the tableview. > I think you have to write your own control! :-) I suggest that you take the Expander source code in gb.form as a base. Regards, -- Beno?t Minisini From nando_f at ...951... Sat Feb 25 19:18:03 2012 From: nando_f at ...951... (nando) Date: Sat, 25 Feb 2012 13:18:03 -0500 Subject: [Gambas-user] Possible suggestion/question Message-ID: <20120225181102.M28648@...951...> Benoit, I came across the need to call many different common small pieces of code multiple times. Naturally, we tend to make a SUB just for all of them. I wondered if you'd consider resurrecting GOSUB {label} which is in the same sub. It would be in the same scope, no parameters allowed and acts just like a leaf subroutine with only return on the stack and no formal stack frame. It's also part compromise to embedded SUBs Would overal execution run faster ? ?? -Fernando From gambas at ...2524... Sat Feb 25 22:10:06 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sat, 25 Feb 2012 21:10:06 +0000 Subject: [Gambas-user] Issue 216 in gambas: Gambas3 reports CReportBrush version too recent. Please upgrade upon make install of 4506 In-Reply-To: <0-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> References: <0-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> Message-ID: <1-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> Comment #1 on issue 216 by imperiou... at ...2360...: Gambas3 reports CReportBrush version too recent. Please upgrade upon make install of 4506 http://code.google.com/p/gambas/issues/detail?id=216 Also applies to 4507. Failure to launch gambas3 executable with the error about CReportBrush version being too recent as above. From jussi.lahtinen at ...626... Sat Feb 25 23:06:57 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 26 Feb 2012 00:06:57 +0200 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: Message-ID: I can't manage to isolate the problem and I can't send the source. Right now I'm using following workaround; Draw.Begin(tmpPic) Draw.Image(imgKoko, 0, 0) Draw.Image(imgKarVe, 0, 0) Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) Draw.End() Draw.Picture(tmpPic, 0, 0) So, using temporary picture the problem disappears. But the situation is not very satisfying. So any debugging tips? How to gather information about what happen? Is there something I can do with gdb, etc? Or is there some debugging dispatch for gbx3? Jussi On Sun, Feb 19, 2012 at 20:12, Jussi Lahtinen wrote: > Hi! > I was debugging huge project to find out why it's execution is slowed down > to unusable, when suddenly screen went blank and I was logged out. > Reason found from logs: Killed process 1264 (Xorg) total-vm:6406864kB, > anon-rss:2751124kB, file-rss:784kB > So I ran out of memory. This shouldn't happen, the project I'm working > with doesn't need even nearly that much memory. > > I can prevent this happening when I comment out content of draw event from > drawingarea. > Right now there are only three lines, which shouldn't cause cumulative > memory usage: > Draw.Image(imgKoko, 0, 0) > Draw.Image(imgKarVe, 0, 0) > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) > > As I said the project is huge, and so far I haven't be able to isolate > what causes the problem. > All I know is that in certain form, every time draw event is raised, it > causes Xorg to take more memory. > > Valgrind log is attached. > > Any ideas? > > Jussi > From sebikul at ...626... Sun Feb 26 01:52:45 2012 From: sebikul at ...626... (Sebi) Date: Sun, 26 Feb 2012 00:52:45 +0000 Subject: [Gambas-user] Architecture of gambas binary files Message-ID: <734797047-1330217566-cardhu_decombobulator_blackberry.rim.net-1157168900-@...2753...> Hi, I would like to know if the gambas binaries created from the IDE, debian, packages or any other type of compilation are architecture dependent or not. i.e. Can a gambas binary compiled on a i386 be executed on amd64? Thanks! From rterry at ...1823... Sun Feb 26 01:56:39 2012 From: rterry at ...1823... (richard terry) Date: Sun, 26 Feb 2012 11:56:39 +1100 Subject: [Gambas-user] Null object bug in design mode of IDE Message-ID: <201202261156.39742.rterry@...1823...> Version 4492 Hi Benoit, I the mouse-down event of apparently random controls (eg I've noted with toolbutton, picturesbox), clicking on the control gives error shown in picture. If I go to the heirachy tree first, select the control, then back to the IDE it dosn't seem to happen. regards Richard -------------- next part -------------- A non-text attachment was scrubbed... Name: benoit_IDE_null_object_bug.png Type: image/png Size: 22765 bytes Desc: not available URL: From gambas at ...2524... Sun Feb 26 05:32:30 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Sun, 26 Feb 2012 04:32:30 +0000 Subject: [Gambas-user] Issue 216 in gambas: Gambas3 reports CReportBrush version too recent. Please upgrade upon make install of 4506 In-Reply-To: <1-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> References: <1-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> <0-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> Message-ID: <2-6813199134517018827-17369749896521670975-gambas=googlecode.com@...2524...> Comment #2 on issue 216 by imperiou... at ...2360...: Gambas3 reports CReportBrush version too recent. Please upgrade upon make install of 4506 http://code.google.com/p/gambas/issues/detail?id=216 I think this might have originated as an incompatibility with the gambas3 rpm (via yum)... please delete this report and I will play more. The installed RPM version (3.0) is running well once I did some extensive system cleaning. Will stay with that for now. From gambas.fr at ...626... Sun Feb 26 15:24:04 2012 From: gambas.fr at ...626... (Fabien Bodard) Date: Sun, 26 Feb 2012 15:24:04 +0100 Subject: [Gambas-user] Memory Message-ID: Why in these example the memory seem to be not freed ? -- Fabien Bodard -------------- next part -------------- A non-text attachment was scrubbed... Name: Leak-0.0.1.tar.gz Type: application/x-gzip Size: 8751 bytes Desc: not available URL: From nando_f at ...951... Sun Feb 26 15:53:51 2012 From: nando_f at ...951... (nando) Date: Sun, 26 Feb 2012 09:53:51 -0500 Subject: [Gambas-user] Dim Keyword..I noticed something Message-ID: <20120226144916.M81320@...951...> I am using some keywords as Integer vars DIM {event} AS INTEGER DIM {timer} AS INTEGER In the IDE, the second line automatically capitalized and highlighted as a keyword with keyword color. In Gambas2. Maybe it propagated forwards into Gambas 3 -Fernando From gambas at ...1... Sun Feb 26 19:35:31 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 26 Feb 2012 19:35:31 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: Message-ID: <4F4A7B73.1020100@...1...> Le 25/02/2012 23:06, Jussi Lahtinen a ?crit : > I can't manage to isolate the problem and I can't send the source. > > Right now I'm using following workaround; > > Draw.Begin(tmpPic) > Draw.Image(imgKoko, 0, 0) > Draw.Image(imgKarVe, 0, 0) > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) > Draw.End() > > Draw.Picture(tmpPic, 0, 0) > > So, using temporary picture the problem disappears. So you seem to have isolated the problem. Tell me (again?): do you use gb.qt4 or gb.gtk? -- Beno?t Minisini From jussi.lahtinen at ...626... Sun Feb 26 20:39:50 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 26 Feb 2012 21:39:50 +0200 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: <4F4A7B73.1020100@...1...> References: <4F4A7B73.1020100@...1...> Message-ID: Qt4, but I think it happened also with GTK+. I tried to repeat the bug with GTK+ to make sure, but when I removed the workaround, nothing happened. And now nothing happens also with Qt4!?!? I don't know what has changed. System update... something with new Gambas revision...? No idea. Right now I'm out of time, I will look into this later. Jussi 2012/2/26 Beno?t Minisini > Le 25/02/2012 23:06, Jussi Lahtinen a ?crit : > > I can't manage to isolate the problem and I can't send the source. > > > > Right now I'm using following workaround; > > > > Draw.Begin(tmpPic) > > Draw.Image(imgKoko, 0, 0) > > Draw.Image(imgKarVe, 0, 0) > > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) > > Draw.End() > > > > Draw.Picture(tmpPic, 0, 0) > > > > So, using temporary picture the problem disappears. > > So you seem to have isolated the problem. Tell me (again?): do you use > gb.qt4 or gb.gtk? > > -- > Beno?t Minisini > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Sun Feb 26 20:43:27 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 26 Feb 2012 20:43:27 +0100 Subject: [Gambas-user] Architecture of gambas binary files In-Reply-To: <734797047-1330217566-cardhu_decombobulator_blackberry.rim.net-1157168900-@...2753...> References: <734797047-1330217566-cardhu_decombobulator_blackberry.rim.net-1157168900-@...2753...> Message-ID: <4F4A8B5F.9050105@...1...> Le 26/02/2012 01:52, Sebi a ?crit : > Hi, I would like to know if the gambas binaries created from the IDE, debian, packages or any other type of compilation are architecture dependent or not. > i.e. Can a gambas binary compiled on a i386 be executed on amd64? > > Thanks! > Gambas bytecode is architecture independant (the same on x86/x86_64/ARM...). The only way of circumventing that is using the preprocessor (#If ... #Endif) to make your program compile differently according to the architecture. Regards, -- Beno?t Minisini From gambas at ...1... Sun Feb 26 21:14:09 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 26 Feb 2012 21:14:09 +0100 Subject: [Gambas-user] Memory In-Reply-To: References: Message-ID: <4F4A9291.8080907@...1...> Le 26/02/2012 15:24, Fabien Bodard a ?crit : > Why in these example the memory seem to be not freed ? > I have looked that for two hours, and my conclusion is that Gambas frees the memory by telling the glibc to do so, but the glibc actually does not free it! So the leak does not come from Gambas. It comes from the glibc that does not give the memory back to the system even if Gambas has explicitely freed it! For example, with this project, when the message "Can you see?" appears, Gambas has freed everything except 1Mb of memory (I have counted). The KDE task manager says that the program takes 131Mb of memory! Could it be a fragmentation problem? I don't know how the glibc malloc() works behind the scene. I will "google the program", but if anybody has any clue... -- Beno?t Minisini From gambas.fr at ...626... Sun Feb 26 21:19:57 2012 From: gambas.fr at ...626... (Fabien Bodard) Date: Sun, 26 Feb 2012 21:19:57 +0100 Subject: [Gambas-user] Memory In-Reply-To: <4F4A9291.8080907@...1...> References: <4F4A9291.8080907@...1...> Message-ID: Le 26 f?vrier 2012 21:14, Beno?t Minisini a ?crit : > Le 26/02/2012 15:24, Fabien Bodard a ?crit : >> Why in these example the memory seem to be not freed ? >> > > I have looked that for two hours, and my conclusion is that Gambas frees > the memory by telling the glibc to do so, but the glibc actually does > not free it! > > So the leak does not come from Gambas. It comes from the glibc that does > not give the memory back to the system even if Gambas has explicitely > freed it! > > For example, with this project, when the message "Can you see?" appears, > Gambas has freed everything except 1Mb of memory (I have counted). The > KDE task manager says that the program takes 131Mb of memory! > > Could it be a fragmentation problem? I don't know how the glibc malloc() > works behind the scene. I will "google the program", but if anybody has > any clue... thank you for taking a look :) > > -- > Beno?t Minisini > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -- Fabien Bodard From gambas at ...1... Sun Feb 26 21:28:57 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 26 Feb 2012 21:28:57 +0100 Subject: [Gambas-user] Memory In-Reply-To: <4F4A9291.8080907@...1...> References: <4F4A9291.8080907@...1...> Message-ID: <4F4A9609.2080002@...1...> Le 26/02/2012 21:14, Beno?t Minisini a ?crit : > Le 26/02/2012 15:24, Fabien Bodard a ?crit : >> Why in these example the memory seem to be not freed ? >> > > I have looked that for two hours, and my conclusion is that Gambas frees > the memory by telling the glibc to do so, but the glibc actually does > not free it! > > So the leak does not come from Gambas. It comes from the glibc that does > not give the memory back to the system even if Gambas has explicitely > freed it! > > For example, with this project, when the message "Can you see?" appears, > Gambas has freed everything except 1Mb of memory (I have counted). The > KDE task manager says that the program takes 131Mb of memory! > > Could it be a fragmentation problem? I don't know how the glibc malloc() > works behind the scene. I will "google the program", but if anybody has > any clue... > We are not alone... http://pushingtheweb.com/2010/06/python-and-tcmalloc/ -- Beno?t Minisini From gambas.fr at ...626... Sun Feb 26 21:39:57 2012 From: gambas.fr at ...626... (Fabien Bodard) Date: Sun, 26 Feb 2012 21:39:57 +0100 Subject: [Gambas-user] Memory In-Reply-To: <4F4A9609.2080002@...1...> References: <4F4A9291.8080907@...1...> <4F4A9609.2080002@...1...> Message-ID: Le 26 f?vrier 2012 21:28, Beno?t Minisini a ?crit : > Le 26/02/2012 21:14, Beno?t Minisini a ?crit : >> Le 26/02/2012 15:24, Fabien Bodard a ?crit : >>> Why in these example the memory seem to be not freed ? >>> >> >> I have looked that for two hours, and my conclusion is that Gambas frees >> the memory by telling the glibc to do so, but the glibc actually does >> not free it! >> >> So the leak does not come from Gambas. It comes from the glibc that does >> not give the memory back to the system even if Gambas has explicitely >> freed it! >> >> For example, with this project, when the message "Can you see?" appears, >> Gambas has freed everything except 1Mb of memory (I have counted). The >> KDE task manager says that the program takes 131Mb of memory! >> >> Could it be a fragmentation problem? I don't know how the glibc malloc() >> works behind the scene. I will "google the program", but if anybody has >> any clue... >> > > We are not alone... > > http://pushingtheweb.com/2010/06/python-and-tcmalloc/ Is there a way to use theire soluce ? > -- > Beno?t Minisini > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user -- Fabien Bodard From rterry at ...1823... Sun Feb 26 22:23:18 2012 From: rterry at ...1823... (richard terry) Date: Mon, 27 Feb 2012 08:23:18 +1100 Subject: [Gambas-user] Listcontainer/grid changes Message-ID: <201202270823.18263.rterry@...1823...> Hi Benoit. Came to work today having updated the latest svn and found I can't select any patients from my multiple pick list - which uses the list container - I have a cPatientRow into which I put the patient's photograph and their demographic details in a textlabel. These are then placed in the listcontainer. Now, when clicking of a row - the whole of the list container is selected and not the individual rows. Bit of a problem for me because with two patients with same name I now can't load their records to do my work.... Also the grid has changed (I use this in my appointment module) This code used to set the appointment time in the vertically set header column: gridview1.rows[i].text = sDisplayTime Now it dosn't fit and there seems no way to widen it. Any help appreciated. Wish I'd kept a record of the version I was at so I could roll back. Mmm......... 15 mins to go before I start work. Bumma. Regards Richard From jussi.lahtinen at ...626... Sun Feb 26 22:49:30 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Sun, 26 Feb 2012 23:49:30 +0200 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: <4F4A7B73.1020100@...1...> Message-ID: I reverted week back in revision, but I cannot reproduce the bug anymore. Maybe this has something to do with nvidia drivers, they don't seem to be very stable. Jussi On Sun, Feb 26, 2012 at 21:39, Jussi Lahtinen wrote: > Qt4, but I think it happened also with GTK+. > > I tried to repeat the bug with GTK+ to make sure, but when I removed the > workaround, nothing happened. > And now nothing happens also with Qt4!?!? > > I don't know what has changed. System update... something with new Gambas > revision...? No idea. > > Right now I'm out of time, I will look into this later. > > Jussi > > > > > > > > > 2012/2/26 Beno?t Minisini > >> Le 25/02/2012 23:06, Jussi Lahtinen a ?crit : >> > I can't manage to isolate the problem and I can't send the source. >> > >> > Right now I'm using following workaround; >> > >> > Draw.Begin(tmpPic) >> > Draw.Image(imgKoko, 0, 0) >> > Draw.Image(imgKarVe, 0, 0) >> > Draw.Picture(picKohdistin, I.KarX - 12, I.KarY - 12) >> > Draw.End() >> > >> > Draw.Picture(tmpPic, 0, 0) >> > >> > So, using temporary picture the problem disappears. >> >> So you seem to have isolated the problem. Tell me (again?): do you use >> gb.qt4 or gb.gtk? >> >> -- >> Beno?t Minisini >> >> >> ------------------------------------------------------------------------------ >> Virtualization & Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > From gambas at ...1... Sun Feb 26 23:05:44 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 26 Feb 2012 23:05:44 +0100 Subject: [Gambas-user] Listcontainer/grid changes In-Reply-To: <201202270823.18263.rterry@...1823...> References: <201202270823.18263.rterry@...1823...> Message-ID: <4F4AACB8.2010407@...1...> Le 26/02/2012 22:23, richard terry a ?crit : > Hi Benoit. > > Came to work today having updated the latest svn and found I can't select any > patients from my multiple pick list - which uses the list container - I have a > cPatientRow into which I put the patient's photograph and their demographic > details in a textlabel. These are then placed in the listcontainer. > > Now, when clicking of a row - the whole of the list container is selected and > not the individual rows. Bit of a problem for me because with two patients > with same name I now can't load their records to do my work.... Please provide a screenshot so that I understand what you are talking about. > > Also the grid has changed (I use this in my appointment module) > > This code used to set the appointment time in the vertically set header > column: > > gridview1.rows[i].text = sDisplayTime > > Now it dosn't fit and there seems no way to widen it. > > Any help appreciated. Indeed. I will see if I can do something to implement a behaviour similar to the old GridView. > > Wish I'd kept a record of the version I was at so I could roll back. You can always go to any revision with 'svn update -r ' or 'svn checkout -r '. Regards, -- Beno?t Minisini From gambas at ...1... Sun Feb 26 23:07:57 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Sun, 26 Feb 2012 23:07:57 +0100 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: References: <4F4A7B73.1020100@...1...> Message-ID: <4F4AAD3D.9070802@...1...> Le 26/02/2012 22:49, Jussi Lahtinen a ?crit : > I reverted week back in revision, but I cannot reproduce the bug anymore. > Maybe this has something to do with nvidia drivers, they don't seem to be > very stable. > > Jussi > If you see the gbx3 process memory becoming huge (in the KDE task manager for example), then the problem is in Gambas. If the problem is in the nvidia driver, you should see the xorg process becoming huge. Note that there is a memory fragmentation problem in Gambas. It does not leak memory, but glibc cannot give it back to the system. There is the same problem in python. See: http://pushingtheweb.com/2010/06/python-and-tcmalloc/ Regards, -- Beno?t Minisini From rterry at ...1823... Sun Feb 26 23:48:58 2012 From: rterry at ...1823... (richard terry) Date: Mon, 27 Feb 2012 09:48:58 +1100 Subject: [Gambas-user] Listcontainer/grid changes In-Reply-To: <4F4AACB8.2010407@...1...> References: <201202270823.18263.rterry@...1823...> <4F4AACB8.2010407@...1...> Message-ID: <201202270948.58680.rterry@...1823...> On Monday 27 February 2012 09:05:44 Beno?t Minisini wrote: > Le 26/02/2012 22:23, richard terry a ?crit : > > Hi Benoit. > > > > Came to work today having updated the latest svn and found I can't select > > any patients from my multiple pick list - which uses the list container - > > I have a cPatientRow into which I put the patient's photograph and their > > demographic details in a textlabel. These are then placed in the > > listcontainer. > > > > Now, when clicking of a row - the whole of the list container is selected > > and not the individual rows. Bit of a problem for me because with two > > patients with same name I now can't load their records to do my work.... > > Please provide a screenshot so that I understand what you are talking > about. I'll send direct to you > > > Also the grid has changed (I use this in my appointment module) > > > > This code used to set the appointment time in the vertically set header > > column: > > > > gridview1.rows[i].text = sDisplayTime > > > > Now it dosn't fit and there seems no way to widen it. > > > > Any help appreciated. > > Indeed. I will see if I can do something to implement a behaviour > similar to the old GridView. > > > Wish I'd kept a record of the version I was at so I could roll back. > > You can always go to any revision with 'svn update -r ' or > 'svn checkout -r '. This I did, just guessed and went back to 4472 and works ok. > > Regards, > From vuott at ...325... Mon Feb 27 00:25:38 2012 From: vuott at ...325... (Ru Vuott) Date: Sun, 26 Feb 2012 23:25:38 +0000 (GMT) Subject: [Gambas-user] rev. 4508 Gambas 3 - now it's impossible to choose project type... ! In-Reply-To: <4F4AAD3D.9070802@...1...> Message-ID: <1330298738.10648.YahooMailClassic@...2780...> Hello, I updated my Gambas 3 via SVN (rev. 4508). I noticed now I am NOT able to choose by mouse the "project type" (graphical application, QT graphical application, and so on), at first step when I want to write a new project. Now I can use only down-arrow and up-arrow of my keyboard to select the project type Bye Vuott From vuott at ...325... Mon Feb 27 03:56:23 2012 From: vuott at ...325... (Ru Vuott) Date: Mon, 27 Feb 2012 02:56:23 +0000 (GMT) Subject: [Gambas-user] R: rev. 4508 Gambas 3 - now it's impossible to choose project type... ! In-Reply-To: <1330298738.10648.YahooMailClassic@...2780...> Message-ID: <1330311383.62580.YahooMailClassic@...2691...> Hello Benoit, I updated with rev. 4511: the problem now is solved ! OK Bye Vuott --- Lun 27/2/12, Ru Vuott ha scritto: > Da: Ru Vuott > Oggetto: [Gambas-user] rev. 4508 Gambas 3 - now it's impossible to choose project type... ! > A: "mailing list for gambas users" > Cc: gambas at ...1... > Data: Luned? 27 febbraio 2012, 00:25 > Hello, > > I updated my Gambas 3 via SVN (rev. 4508). I noticed now I > am NOT able to choose by mouse the "project type" (graphical > application, QT graphical application, and so on), at first > step when I want to write a new project. > Now I can use only down-arrow and up-arrow of my keyboard to > select the project type > > Bye > Vuott > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity > Planning > Cloud computing makes use of virtualization - but cloud > computing > also focuses on allowing computing to be delivered as a > service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From eilert-sprachen at ...221... Mon Feb 27 08:23:56 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Mon, 27 Feb 2012 08:23:56 +0100 Subject: [Gambas-user] String array empty after SUB (Gambas 2) In-Reply-To: <20120223204922.M33657@...951...> References: <4F451AD1.5070807@...221...> <20120223204922.M33657@...951...> Message-ID: <4F4B2F8C.9070406@...221...> Sometimes you're used to doing things this way or that way without thinking about what could be a better solution... :-) Never realized that functions can return whole arrays! Thanks for that hint. Rolf Am 23.02.2012 21:51, schrieb nando: > felder as STRING[] is a parameter passed into sub > It is no good outside of SUB > > What you should do is make your sub > > PUBLIC FUNCTION ListeKundeFelder(schlysselnr AS String, felder AS String[]) AS STRING[] > > and return the string[], assigning it to the original felder[] > > -Fernando > > > > ---------- Original Message ----------- > From: Rolf-Werner Eilert > To: mailing list for gambas users > Sent: Wed, 22 Feb 2012 17:41:53 +0100 > Subject: [Gambas-user] String array empty after SUB (Gambas 2) > >> Now, this is a strange one :-) and I really have no idea what goes wrong >> here. >> >> I've got a dialog which loads a list of names. I'm keeping such SUBs >> that deal with files in a module called ldsv (brief for load-save). >> >> The dialog's part is simple, "ls" is the listbox: >> >> PRIVATE felder AS NEW String[] >> >> PUBLIC SUB ls_Click() >> >> Label1.Text = "Nr. "& schlyssel[ls.Index]& ": "& ls[ls.Index].Text >> 'here we jump into the SUB: >> ldsv.ListeKundeFelder(schlyssel[ls.Index], felder) >> 'now we should see the number of fields loaded: >> lblTitel.Text = CStr(felder.Count) >> >> END >> >> Now the SUB in module ldsv: >> >> PUBLIC SUB ListeKundeFelder(schlysselnr AS String, felder AS String[]) >> DIM t$ AS String >> DIM feld AS NEW String[] >> >> felder.Clear >> >> t$ = File.Load(pfadKunden&/ schlysselnr& ".kunde") >> t$ = Tag2Str(t$) >> >> feld = Split(t$, Chr$(10)) >> >> IF feld[0] = "#!Stein3.1" THEN >> feld.Delete(0, 2) 'das #! und die ID k?nnen weg >> felder = feld.Copy() >> END IF >> >> END >> >> When I put a stop at the END IF and watch the values, felder will have >> 16 values from 0 - 15 containing strings just as expected. But when I >> return to the dialog, felder is empty! This is especially weird as there >> are other SUBs and FUNCTIONs en masse in my project that do it exactly >> the same way. >> >> I cannot detect any mistake I made - or do you? >> >> Regards >> >> Rolf >> >> ------------------------------------------------------------------------------ >> Virtualization& Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > Virtualization& Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From vignolacity at ...1176... Mon Feb 27 16:35:53 2012 From: vignolacity at ...1176... (vignolacity at ...1176...) Date: Mon, 27 Feb 2012 16:35:53 +0100 (CET) Subject: [Gambas-user] New GridView Message-ID: <135bf7421a1.vignolacity@...1176...> Bonjour ? tous... Je m'appelle Paolo, je suis italien et j'habite en Vall?e d'Aoste. Je suis un utilisateur enregistr? sur le forum italien Gambas-it.org et je d?veloppe un composant nomm? GridBox utilisant GridView. J'ai vu qu'il a ?t? enti?rement reconstruit le contr?le GridView, mais la m?thode GridView.Rows.Insert() n'a pas ?t? r?int?gr?Et je ne comprends pas pourquoi il a ?t? donn? un valeur minimale de 1 ? la propriet? GridView.Columns.W Ciao... Ciao... From eilert-sprachen at ...221... Mon Feb 27 16:59:00 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Mon, 27 Feb 2012 16:59:00 +0100 Subject: [Gambas-user] New GridView In-Reply-To: <135bf7421a1.vignolacity@...1176...> References: <135bf7421a1.vignolacity@...1176...> Message-ID: <4F4BA844.7090408@...221...> > Bonjour ? tous... > Je m'appelle Paolo, je suis italien et j'habite en Vall?e d'Aoste. > Je suis un utilisateur enregistr? sur le forum italien Gambas-it.org et je d?veloppe un composant nomm? GridBox utilisant GridView. > J'ai vu qu'il a ?t? enti?rement reconstruit le contr?le GridView, mais la m?thode GridView.Rows.Insert() n'a pas ?t? r?int?gr?Et je ne comprends pas pourquoi il a ?t? donn? un valeur minimale de 1 ? la propriet? GridView.Columns.W > Ciao... Ciao... > Bonjour Paolo, Je croix il serait de tr?s grande aide si tu parlerais en anglais avec nous. Ici m?me Beno?t parle anglais :-) et la majorit? des mecs ne parle qu'anglais (au moins dans ca liste...). But I'm curious about your new GridView - what can it do over the GridView capabilities? Regards Rolf From john.aaron.rose at ...626... Mon Feb 27 17:18:03 2012 From: john.aaron.rose at ...626... (John Rose) Date: Mon, 27 Feb 2012 16:18:03 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1330359483.5448.9.camel@...2661...> Benoit, I'm now using kendek's launchpad ppa for Gambas pre-release: he created latest version on 25 February 2012. I don't know the version number of Gambas3 that he used and I don't know how to find out (apart from asking him). I'm reluctant to install Gambas3 using subversion & compiling it as I then have incompatibility between compiled version of an app & installing it (from a .deb) on same or another PC. I have not found any way round this incompatibility. I'm still having a problem when I try to add a new row to a SQLite3 database table. I am able to key in the data for the new row after clicking the 'New' icon. However, when I try to save the new row by clicking the 'Save' icon, I now get "Cannot modify record: SQL error or missing database" displayed in a popup. Please let me know if you want me to send the app. -- Regards, John +44 1902 331266 +44 7894 211434 From jussi.lahtinen at ...626... Mon Feb 27 17:23:13 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Mon, 27 Feb 2012 18:23:13 +0200 Subject: [Gambas-user] Memory problems with Gambas3 In-Reply-To: <4F4AAD3D.9070802@...1...> References: <4F4A7B73.1020100@...1...> <4F4AAD3D.9070802@...1...> Message-ID: > If you see the gbx3 process memory becoming huge (in the KDE task > manager for example), then the problem is in Gambas. > > If the problem is in the nvidia driver, you should see the xorg process > becoming huge. > Yeah, logs shows that Xorg was closed due it hogging over 6 GB of memory. Jussi From mailinglist at ...2465... Mon Feb 27 17:23:34 2012 From: mailinglist at ...2465... (Florent THOMAS) Date: Mon, 27 Feb 2012 17:23:34 +0100 Subject: [Gambas-user] Gambas3 make install issue Message-ID: <4F4BAE06.4050100@...2465...> Hy all of you, Here is the make install log of my attept to install gambas3 on opensuse 11. I didn't succeed in finding the proper solution to this failure in compilation. regards -------------- next part -------------- A non-text attachment was scrubbed... Name: output.txt.zip Type: application/zip Size: 33413 bytes Desc: not available URL: From jussi.lahtinen at ...626... Mon Feb 27 17:36:27 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Mon, 27 Feb 2012 18:36:27 +0200 Subject: [Gambas-user] Gambas3 make install issue In-Reply-To: <4F4BAE06.4050100@...2465...> References: <4F4BAE06.4050100@...2465...> Message-ID: Is "make install" ran as root (sudo make install)? You may need to send output of whole compilation. ( ./reconf-all && ./configure -C && make && sudo make install ) > ~/Desktop/compile.log 2>&1 What "make --version" says? Jussi On Mon, Feb 27, 2012 at 18:23, Florent THOMAS wrote: > Hy all of you, > > Here is the make install log of my attept to install gambas3 on opensuse > 11. > > I didn't succeed in finding the proper solution to this failure in > compilation. > > regards > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > From vga.nantes at ...626... Mon Feb 27 19:24:34 2012 From: vga.nantes at ...626... (vicolachips chips) Date: Mon, 27 Feb 2012 19:24:34 +0100 Subject: [Gambas-user] New GridView In-Reply-To: <4F4BA844.7090408@...221...> References: <135bf7421a1.vignolacity@...1176...> <4F4BA844.7090408@...221...> Message-ID: Pour l'histoire de la m?thode Insert, je ne sais pas. En revanche la valeur minimale ? 1 permet de verrouiller le redimensionnement de la colonne. Si on met 0 ?a ne marche pas. Je dis ?a car je travail moi m?me sur un ExDataGrid permettant d'afficher n'importe quel type d'?diteur pour l'?dition des cellules. J'imagine que la colonne avec le Width ? 1 doit permettre de conserver le ROWID ou alors le Row State... Cdt, Le 27 f?vrier 2012 16:59, Rolf-Werner Eilert a ?crit : > > > Bonjour ? tous... > > Je m'appelle Paolo, je suis italien et j'habite en Vall?e d'Aoste. > > Je suis un utilisateur enregistr? sur le forum italien Gambas-it.org et > je d?veloppe un composant nomm? GridBox utilisant GridView. > > J'ai vu qu'il a ?t? enti?rement reconstruit le contr?le GridView, mais > la m?thode GridView.Rows.Insert() n'a pas ?t? r?int?gr?Et je ne comprends > pas pourquoi il a ?t? donn? un valeur minimale de 1 ? la propriet? > GridView.Columns.W > > Ciao... Ciao... > > > > Bonjour Paolo, > > Je croix il serait de tr?s grande aide si tu parlerais en anglais avec > nous. Ici m?me Beno?t parle anglais :-) et la majorit? des mecs ne parle > qu'anglais (au moins dans ca liste...). > > But I'm curious about your new GridView - what can it do over the > GridView capabilities? > > Regards > > Rolf > > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Mon Feb 27 19:54:44 2012 From: gambas at ...1... (=?UTF-8?B?QmVub8OudCBNaW5pc2luaQ==?=) Date: Mon, 27 Feb 2012 19:54:44 +0100 Subject: [Gambas-user] New GridView In-Reply-To: <135bf7421a1.vignolacity@...1176...> References: <135bf7421a1.vignolacity@...1176...> Message-ID: <4F4BD174.2090702@...1...> Le 27/02/2012 16:35, vignolacity at ...1176... a ?crit : > > > > > Bonjour ? tous... > Je m'appelle Paolo, je suis italien et j'habite en Vall?e d'Aoste. > Je suis un utilisateur enregistr? sur le forum italien Gambas-it.org et je d?veloppe un composant nomm? GridBox utilisant GridView. > J'ai vu qu'il a ?t? enti?rement reconstruit le contr?le GridView, mais la m?thode GridView.Rows.Insert() n'a pas ?t? r?int?gr?Et je ne comprends pas pourquoi il a ?t? donn? un valeur minimale de 1 ? la propriet? GridView.Columns.W > Ciao... Ciao... > > Tu as raison, j'ai simplement oubli? d'impl?menter les m?thodes Insert() et Remove() dans le nouveau GridView. Je le ferai. Cordialement, You are right, I just forgot to implement the Insert() and Remove() methods in the new GridView. I will do it. Regards, -- Beno?t Minisini From mailinglist at ...2465... Mon Feb 27 21:22:54 2012 From: mailinglist at ...2465... (Florent THOMAS) Date: Mon, 27 Feb 2012 21:22:54 +0100 Subject: [Gambas-user] Gambas3 make install issue In-Reply-To: References: <4F4BAE06.4050100@...2465...> Message-ID: <4F4BE61E.30402@...2465...> Hy, Thanks for your answer make -v GNU Make 3.82 I also compiled another time. Please find attached the entire log. regards Le 27/02/2012 17:36, Jussi Lahtinen a ?crit : > ( ./reconf-all && ./configure -C && make && sudo make install ) -------------- next part -------------- A non-text attachment was scrubbed... Name: output.tar.gz Type: application/x-gzip Size: 16729 bytes Desc: not available URL: From gambas at ...1... Mon Feb 27 22:19:03 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 27 Feb 2012 22:19:03 +0100 Subject: [Gambas-user] Dim Keyword..I noticed something In-Reply-To: <20120226144916.M81320@...951...> References: <20120226144916.M81320@...951...> Message-ID: <4F4BF347.9010107@...1...> Le 26/02/2012 15:53, nando a ?crit : > I am using some keywords as Integer vars > > DIM {event} AS INTEGER > DIM {timer} AS INTEGER > > > In the IDE, > the second line automatically capitalized and highlighted as a keyword > with keyword color. > > In Gambas2. Maybe it propagated forwards into Gambas 3 > -Fernando > Yep, this is a bug that was fixed in Gambas 3. Regards, -- Beno?t Minisini From gambas at ...1... Mon Feb 27 23:19:15 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Mon, 27 Feb 2012 23:19:15 +0100 Subject: [Gambas-user] DataSource & DataBrowser problem In-Reply-To: <1330359483.5448.9.camel@...2661...> References: <1330359483.5448.9.camel@...2661...> Message-ID: <4F4C0163.1040104@...1...> Le 27/02/2012 17:18, John Rose a ?crit : > Benoit, > > I'm now using kendek's launchpad ppa for Gambas pre-release: he created > latest version on 25 February 2012. I don't know the version number of > Gambas3 that he used and I don't know how to find out (apart from asking > him). I'm reluctant to install Gambas3 using subversion& compiling it > as I then have incompatibility between compiled version of an app& > installing it (from a .deb) on same or another PC. I have not found any > way round this incompatibility. > > I'm still having a problem when I try to add a new row to a SQLite3 > database table. I am able to key in the data for the new row after > clicking the 'New' icon. However, when I try to save the new row by > clicking the 'Save' icon, I now get "Cannot modify record: SQL error or > missing database" displayed in a popup. > > Please let me know if you want me to send the app. > It works there. I'm afraid that the bug has been fixed February, 26th, in revision #4508! Sorry for the inconvenience. Regards, -- Beno?t Minisini From gambas at ...2524... Tue Feb 28 05:10:34 2012 From: gambas at ...2524... (gambas at ...2524...) Date: Tue, 28 Feb 2012 04:10:34 +0000 Subject: [Gambas-user] Issue 217 in gambas: Reducing the number of panels in a toolpanel crashes the IDE Message-ID: <0-6813199134517018827-8106490441900654920-gambas=googlecode.com@...2524...> Status: New Owner: ---- Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any Desktop-Any GUI-Any New issue 217 by adamn... at ...626...: Reducing the number of panels in a toolpanel crashes the IDE http://code.google.com/p/gambas/issues/detail?id=217 1) Describe the problem. IDE crashes silently: If the Count property of a toolpanel is reduced when the last panel is expanded, clicking on the label for the new last panel results in the IDE crashing silently. 2) GIVE THE FOLLOWING INFORMATIONS (if they are appropriate): Version: TRUNK Revision: recent from a few days ago Operating system: Linux Distribution: other Architecture: x86 GUI component: QT4 (IDE) Desktop used: LXDE 3) Provide a little project that reproduces the bug or the crash. Attached 4) If your project needs a database, try to provide it, or part of it. NA 5) Explain clearly how to reproduce the bug or the crash. Open the project and edit the FMain form. Make sure Toolbar 2 is expanded Drop the Count back to 2 Click on ToolBar 1 Label ===> IDE just crashes Attachments: toolpanelcrash-0.0.1.tar.gz 4.6 KB From demosthenesk at ...626... Tue Feb 28 11:16:20 2012 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Tue, 28 Feb 2012 12:16:20 +0200 Subject: [Gambas-user] Toolbar height is wrong Message-ID: <4F4CA974.5020307@...626...> Hello, i reopen an issue about Toolbar. In attached Project142 there is a form with a toolbar (red bg) and a hbox (green bg). In hbox toolbuttons appears correctly but not in Toolbar. Toolbar in run mode gets a small height and hides the toolbuttons. I attach the project and a screenshot. Can anyone confirm if there is a bug? Thank you! -------------- next part -------------- A non-text attachment was scrubbed... Name: Project142.tar.gz Type: application/x-gzip Size: 11319 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image_001.png Type: image/png Size: 12854 bytes Desc: not available URL: From kaiser.chris.eft at ...221... Tue Feb 28 11:25:59 2012 From: kaiser.chris.eft at ...221... (flynopi) Date: Tue, 28 Feb 2012 02:25:59 -0800 (PST) Subject: [Gambas-user] Embed a VM -> Keyboard communication Message-ID: <33396575.post@...1379...> Hi, I executed a Virtual Box machine by EXEC ["vboxmanage", "startvm", "nameOfVM"] FOR READ WRITE and embedded it with help of the embedder class. But I cannot do any keyboard input to the vm. mouse clicking is no problem. what's wrong here? Cheers, F -- View this message in context: http://old.nabble.com/Embed-a-VM--%3E-Keyboard-communication-tp33396575p33396575.html Sent from the gambas-user mailing list archive at Nabble.com. From gambas at ...1... Tue Feb 28 11:28:00 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Tue, 28 Feb 2012 11:28:00 +0100 Subject: [Gambas-user] Toolbar height is wrong In-Reply-To: <4F4CA974.5020307@...626...> References: <4F4CA974.5020307@...626...> Message-ID: <4F4CAC30.1080908@...1...> Le 28/02/2012 11:16, Demosthenes Koptsis a ?crit : > Hello, > > i reopen an issue about Toolbar. > In attached Project142 there is a form with a toolbar (red bg) and a > hbox (green bg). > > In hbox toolbuttons appears correctly but not in Toolbar. > > Toolbar in run mode gets a small height and hides the toolbuttons. > > I attach the project and a screenshot. > > Can anyone confirm if there is a bug? > > Thank you! > At the moment the toolbar height can only take three differents values (Desktop.Scale * 4, * 5 and * 7). If you use custom icons, they must have a small size. Regards, -- Beno?t Minisini From gambas at ...1... Tue Feb 28 11:34:38 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Tue, 28 Feb 2012 11:34:38 +0100 Subject: [Gambas-user] Embed a VM -> Keyboard communication In-Reply-To: <33396575.post@...1379...> References: <33396575.post@...1379...> Message-ID: <4F4CADBE.9030303@...1...> Le 28/02/2012 11:25, flynopi a ?crit : > > Hi, > > I executed a Virtual Box machine by > > EXEC ["vboxmanage", "startvm", "nameOfVM"] FOR READ WRITE > > and embedded it with help of the embedder class. > But I cannot do any keyboard input to the vm. mouse clicking is no problem. > what's wrong here? > > > Cheers, > F Maybe vboxmanage requires a virtual terminal? -- Beno?t Minisini From demosthenesk at ...626... Tue Feb 28 11:52:13 2012 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Tue, 28 Feb 2012 12:52:13 +0200 Subject: [Gambas-user] Toolbar height is wrong In-Reply-To: <4F4CAC30.1080908@...1...> References: <4F4CA974.5020307@...626...> <4F4CAC30.1080908@...1...> Message-ID: <4F4CB1DD.9060901@...626...> should i set any other property to work? Because tlbrMain.Height = Desktop.Scale * 7 does not work. See attached project i changed it. Thanks! On 02/28/2012 12:28 PM, Beno?t Minisini wrote: > Le 28/02/2012 11:16, Demosthenes Koptsis a ?crit : >> Hello, >> >> i reopen an issue about Toolbar. >> In attached Project142 there is a form with a toolbar (red bg) and a >> hbox (green bg). >> >> In hbox toolbuttons appears correctly but not in Toolbar. >> >> Toolbar in run mode gets a small height and hides the toolbuttons. >> >> I attach the project and a screenshot. >> >> Can anyone confirm if there is a bug? >> >> Thank you! >> > At the moment the toolbar height can only take three differents values > (Desktop.Scale * 4, * 5 and * 7). > > If you use custom icons, they must have a small size. > > Regards, > -------------- next part -------------- A non-text attachment was scrubbed... Name: Project142.tar.gz Type: application/x-gzip Size: 12152 bytes Desc: not available URL: From gambas at ...1... Tue Feb 28 11:56:46 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Tue, 28 Feb 2012 11:56:46 +0100 Subject: [Gambas-user] Toolbar height is wrong In-Reply-To: <4F4CB1DD.9060901@...626...> References: <4F4CA974.5020307@...626...> <4F4CAC30.1080908@...1...> <4F4CB1DD.9060901@...626...> Message-ID: <4F4CB2EE.40002@...1...> Le 28/02/2012 11:52, Demosthenes Koptsis a ?crit : > should i set any other property to work? > > Because > > tlbrMain.Height = Desktop.Scale * 7 > > does not work. > > See attached project i changed it. > > Thanks! > No, you have no control on the toolbar height. This won't change. But I was wrong in the previous mail. You can use any icon inside a toolbar button, it will be stretched automatically, provided that you use only ToolButton or MenuButton in the toolbar. Regards, -- Beno?t Minisini From demosthenesk at ...626... Tue Feb 28 12:16:36 2012 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Tue, 28 Feb 2012 13:16:36 +0200 Subject: [Gambas-user] Toolbar height is wrong In-Reply-To: <4F4CB2EE.40002@...1...> References: <4F4CA974.5020307@...626...> <4F4CAC30.1080908@...1...> <4F4CB1DD.9060901@...626...> <4F4CB2EE.40002@...1...> Message-ID: <4F4CB794.5090400@...626...> On 02/28/2012 12:56 PM, Beno?t Minisini wrote: > Le 28/02/2012 11:52, Demosthenes Koptsis a ?crit : >> should i set any other property to work? >> >> Because >> >> tlbrMain.Height = Desktop.Scale * 7 >> >> does not work. >> >> See attached project i changed it. >> >> Thanks! >> > No, you have no control on the toolbar height. This won't change. > > But I was wrong in the previous mail. You can use any icon inside a > toolbar button, it will be stretched automatically, provided that you > use only ToolButton or MenuButton in the toolbar. > > Regards, > ok, i changed again the project. i have three toolbuttons in a toolbar but toolbar does not stretches automatically and Autoresize is set to True. -------------- next part -------------- A non-text attachment was scrubbed... Name: Project142.tar.gz Type: application/x-gzip Size: 11569 bytes Desc: not available URL: From eilert-sprachen at ...221... Tue Feb 28 13:06:49 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Tue, 28 Feb 2012 13:06:49 +0100 Subject: [Gambas-user] Was there a masked edit box? Message-ID: <4F4CC359.2070808@...221...> I faintly remember there was some masked edit box in Gambas2, or am I wrong? I mean something where you could set some control chars to define your own way of editing (e. g. "hh:mm" or "$$$$,## ?" or so). Thanks for your hints... Rolf From skylineds at ...2755... Tue Feb 28 16:17:53 2012 From: skylineds at ...2755... (Dick) Date: Tue, 28 Feb 2012 09:17:53 -0600 Subject: [Gambas-user] Gambas3 rpm Message-ID: <2007643.yHxQmVk0x3@...2756...> Hello, Installed the Gambas3 version RPMs from: download.opensuse.org/repositories/Education/openSUSE_12.1/ The package "deb" needed to be installed as a dependency. Entered "gambas3" from the command line and received the following error message: gbx3: no project file in current directory. RPM Gambas version is 3.0.0-8.1 This system has openSUSE 12.1 running and Gambas2. The manually compiled/installed version of Gambas3 did not produce this error. Is this my error, or is this in the RPM? Thanks, Dick Davis From member at ...2579... Tue Feb 28 17:05:57 2012 From: member at ...2579... (ivan williams via LinkedIn) Date: Tue, 28 Feb 2012 16:05:57 +0000 (UTC) Subject: [Gambas-user] =?utf-8?q?Rejoindre_mon_r=C3=A9seau_sur_LinkedIn?= Message-ID: <1839247557.12877583.1330445157830.JavaMail.app@...2781...> LinkedIn ------------ ivan williams souhaite se connecter ? vous sur LinkedIn?: ------------------------------------------ Je vous invite ? faire partie de mon r?seau professionnel en ligne sur le site LinkedIn. Accepter l'invitation de ivan williams http://www.linkedin.com/e/hggat5-gz74p1vf-1b/uKC-86hQN3QmxE2auJ6zQ6pkPe-4UnCG632_CXVQxQl4RrKxeh/blk/I45030143_45/pmpxnSRJrSdvj4R5fnhv9ClRsDgZp6lQs6lzoQ5AomZIpn8_djhvcPgNc3cMdjh9bSV1rmJQjkURbPwQdjsVcP0McjoLrCBxbOYWrSlI/EML_comm_afe/?hs=false&tok=2kCaE5pAi5ml81 Voir l'invitation de ivan williams http://www.linkedin.com/e/hggat5-gz74p1vf-1b/uKC-86hQN3QmxE2auJ6zQ6pkPe-4UnCG632_CXVQxQl4RrKxeh/blk/I45030143_45/0Rd5YPd34McP0Rd4ALqnpPbOYWrSlI/svi/?hs=false&tok=0Q7SX2-A-5ml81 ------------------------------------------ Quel est l'int?r?t de faire partie du r?seau de ivan williams?? Le r?seau de ivan williams d?veloppera votre propre r?seau?: Si vous acceptez l'invitation de ivan williams, vous pourrez voir qui vous connaissez dans son r?seau et demander ? ivan williams de vous pr?senter. Appartenir ? un r?seau est toujours un plus pour votre carri?re. -- (c) 2012, LinkedIn Corporation From demosthenesk at ...626... Tue Feb 28 18:13:00 2012 From: demosthenesk at ...626... (Demosthenes Koptsis) Date: Tue, 28 Feb 2012 19:13:00 +0200 Subject: [Gambas-user] Toolbar issues In-Reply-To: <4F4CB2EE.40002@...1...> References: <4F4CA974.5020307@...626...> <4F4CAC30.1080908@...1...> <4F4CB1DD.9060901@...626...> <4F4CB2EE.40002@...1...> Message-ID: <4F4D0B1C.3030306@...626...> On 02/28/2012 12:56 PM, Beno?t Minisini wrote: > Le 28/02/2012 11:52, Demosthenes Koptsis a ?crit : >> should i set any other property to work? >> >> Because >> >> tlbrMain.Height = Desktop.Scale * 7 >> >> does not work. >> >> See attached project i changed it. >> >> Thanks! >> > No, you have no control on the toolbar height. This won't change. > > But I was wrong in the previous mail. You can use any icon inside a > toolbar button, it will be stretched automatically, provided that you > use only ToolButton or MenuButton in the toolbar. > > Regards, > i made more tests with Toolbar and Toolbuttons and i think there are some issues. 1) the icons on toolbuttons on a toolbar do not auto-stretched. i had to set a very small size 15x15 pixels to be able to be shown. i tried this with Autoresize property to True and False both on Toolbar+Toolbuttons and there is no difference. can anyone confirm this? I attache the project with the issue. 2) The menu from Toolbar with right click do not follow gnome2 theme values and i get this weird screen shot -------------- next part -------------- A non-text attachment was scrubbed... Name: image_001.png Type: image/png Size: 135281 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Project142.tar.gz Type: application/x-gzip Size: 10969 bytes Desc: not available URL: From eilert-sprachen at ...221... Tue Feb 28 18:18:18 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Tue, 28 Feb 2012 18:18:18 +0100 Subject: [Gambas-user] How to organize dependent lists Message-ID: <4F4D0C5A.5020904@...221...> Hi folks, I would be interested in your opinions. In a project I've got two lists of data and further data which are mutually dependent, such as item 1: item 1 a data 1 aa data 1 ab item 1 b data 1 ba data 1 bb and so on, which could be seen like a tree or directory structure. Now my question is, how would YOU organize this internally? I mean, what kind of data structure would you prefer to be able to easily find your way through it? In the GUI, it looks like two ListBoxes and two TextBoxes: List1 List2 TextBox1 TextBox2 If you choose item1 in List1, List2 will show item1a and item1b. When you choose item1a, the Textboxes show data1aa and data1ab. If you choose item1b, the Textboxes show data1ba and data1bb. Of course, I could make a matrix of item1 item1a data1aa item1 item1a data1ab item1 item1b data1ba item1 item1b data1bb but how would my program EASILY find which data to show if the user clicks item1a for instance? Another idea was to leave out repetitions: item1 item1a data1aa data1ab item1b data1ba data1bb This shows the tree-like structure better, but is it a professional approach? Thanks for your ideas. Rolf From mailinglist at ...2465... Tue Feb 28 18:20:37 2012 From: mailinglist at ...2465... (Florent THOMAS) Date: Tue, 28 Feb 2012 18:20:37 +0100 Subject: [Gambas-user] Gambas3 make install issue In-Reply-To: <4F4BE61E.30402@...2465...> References: <4F4BAE06.4050100@...2465...> <4F4BE61E.30402@...2465...> Message-ID: <4F4D0CE5.4080609@...2465...> Correct. Thanks to Jussi : /Compiling gambas3... gbc: error: Component not found: gb.qt4.webkit/ So, seems like gb.qt4.webkit is mandatory component. And for some reason not all missing dependencies (= not compiled components) are reported in end of configure. Benoit, is this correct? See needed requirements for gb.qt4.webkit from here: http://gambasdoc.org/help/install?en&view Jussi Le 27/02/2012 21:22, Florent THOMAS a ?crit : > Hy, > > Thanks for your answer > make -v > GNU Make 3.82 > > I also compiled another time. Please find attached the entire log. > > regards > > Le 27/02/2012 17:36, Jussi Lahtinen a ?crit : >> ( ./reconf-all && ./configure -C && make && sudo make install ) > > > ------------------------------------------------------------------------------ > Try before you buy = See our experts in action! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-dev2 > > > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user From tobiasboege01 at ...1601... Tue Feb 28 18:33:26 2012 From: tobiasboege01 at ...1601... (tobi) Date: Tue, 28 Feb 2012 18:33:26 +0100 Subject: [Gambas-user] How to organize dependent lists In-Reply-To: <4F4D0C5A.5020904@...221...> References: <4F4D0C5A.5020904@...221...> Message-ID: <20120228173326.GC622@...2774...> hi, On Tue, 28 Feb 2012, Rolf-Werner Eilert wrote: > Hi folks, > > I would be interested in your opinions. In a project I've got two lists > of data and further data which are mutually dependent, such as > > item 1: > item 1 a > data 1 aa > data 1 ab > item 1 b > data 1 ba > data 1 bb > > and so on, which could be seen like a tree or directory structure. > > Now my question is, how would YOU organize this internally? I mean, what > kind of data structure would you prefer to be able to easily find your > way through it? In the GUI, it looks like two ListBoxes and two TextBoxes: > > List1 List2 TextBox1 > TextBox2 > > If you choose item1 in List1, List2 will show item1a and item1b. When > you choose item1a, the Textboxes show data1aa and data1ab. If you choose > item1b, the Textboxes show data1ba and data1bb. > > Of course, I could make a matrix of > > item1 item1a data1aa > item1 item1a data1ab > item1 item1b data1ba > item1 item1b data1bb > > but how would my program EASILY find which data to show if the user > clicks item1a for instance? Another idea was to leave out repetitions: > > item1 item1a data1aa > data1ab > item1b data1ba > data1bb > > This shows the tree-like structure better, but is it a professional > approach? > > Thanks for your ideas. > > Rolf > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user well, my approach would be using a class that has an array of instances of the same class (reminds me of linked lists). i don't know if it is possible in gambas, haven't tried or read about it but it may look like: --- CNode.class: Public Children As CNode[] --- or, which may be more intuitive in later usage: --- CNode.class: Inherits Array Public Children As CNode[] Public Function _get(iInd As Integer) As CNode Return Me.Children[iInd] End --- in fact, i haven't programmed in Gambas for about a month and have no possibility to check my suggestions but i think you see the point. regards, tobi From nando_f at ...951... Tue Feb 28 18:48:38 2012 From: nando_f at ...951... (nando) Date: Tue, 28 Feb 2012 12:48:38 -0500 Subject: [Gambas-user] How to organize dependent lists In-Reply-To: <4F4D0C5A.5020904@...221...> References: <4F4D0C5A.5020904@...221...> Message-ID: <20120228172911.M96984@...951...> I would do it this way 1) I would make a class for data 1. If contains whatever PRIVATEs you wish 2) I would make an OBJECT[] which hold as many of the above class instances you need 3) I would make an OBJECT[] which hold as many of the above OBJECT[] as you need item 1: OBJECT[] has two OBJECT[]s in it item 1 a OBJECT[] has the next two items in it data 1 aa <--class instance data 1 ab <--class instance item 1 b OBJECT[] has the next two items in it data 1 ba <--class instance data 1 bb <--class instance ..something like this...in your main startup PUBLIC first AS NEW OBJECT[] 'This defines and creates the main OBJECT[] PUBLIC second AS OBJECT[] 'This only defines the inner OBJECTs[] ... DIM myData as Class_with_whatever_data_you_need DIM second AS NEW OBJECT[] 'Create an instance of OBJECT[] for use as a second first.add(second) 'This makes first[0].OBJECT[] DIM second AS NEW OBJECT[] 'Create an another instance of OBJECT[] for use as another second first.add(second) 'This makes first[1].OBJECT[] myData AS NEW Class_with_whatever_data_you_need 'create new instance of data first[0][0].add(myData) myData AS NEW Class_with_whatever_data_you_need 'create new instance of data first[0][1].add(myData) second = NEW OBJECT[] first.add(second) 'this makes first[1] 'first.count=2 myData AS NEW Class_with_whatever_data_you_need 'create new instance of data first[1][0].add(myData) first[0] has OBJECT[] in it. OBJECT[0] has a class instance OBJECT[1] has a class instance first[1] has OBJECT[] in it. OBJECT[0] has a class instance So, first[1][0].whatever your class vars are. -Fernando ---------- Original Message ----------- From: Rolf-Werner Eilert To: gambas-user at lists.sourceforge.net Sent: Tue, 28 Feb 2012 18:18:18 +0100 Subject: [Gambas-user] How to organize dependent lists > Hi folks, > > I would be interested in your opinions. In a project I've got two lists > of data and further data which are mutually dependent, such as > > item 1: > item 1 a > data 1 aa > data 1 ab > item 1 b > data 1 ba > data 1 bb > > and so on, which could be seen like a tree or directory structure. > > Now my question is, how would YOU organize this internally? I mean, what > kind of data structure would you prefer to be able to easily find your > way through it? In the GUI, it looks like two ListBoxes and two TextBoxes: > > List1 List2 TextBox1 > TextBox2 > > If you choose item1 in List1, List2 will show item1a and item1b. When > you choose item1a, the Textboxes show data1aa and data1ab. If you choose > item1b, the Textboxes show data1ba and data1bb. > > Of course, I could make a matrix of > > item1 item1a data1aa > item1 item1a data1ab > item1 item1b data1ba > item1 item1b data1bb > > but how would my program EASILY find which data to show if the user > clicks item1a for instance? Another idea was to leave out repetitions: > > item1 item1a data1aa > data1ab > item1b data1ba > data1bb > > This shows the tree-like structure better, but is it a professional > approach? > > Thanks for your ideas. > > Rolf > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From nando_f at ...951... Tue Feb 28 21:17:27 2012 From: nando_f at ...951... (nando) Date: Tue, 28 Feb 2012 15:17:27 -0500 Subject: [Gambas-user] How to organize dependent lists In-Reply-To: <20120228173326.GC622@...2774...> References: <4F4D0C5A.5020904@...221...> <20120228173326.GC622@...2774...> Message-ID: <20120228201328.M46026@...951...> The second level OBJECT[] actually turns out to be an array of Classes. My experience is people understand the OBJECT[] way because of the container within a container concept. It is the same thing :) ---------- Original Message ----------- From: tobi To: info at ...394..., mailing list for gambas users Sent: Tue, 28 Feb 2012 18:33:26 +0100 Subject: Re: [Gambas-user] How to organize dependent lists > hi, > > On Tue, 28 Feb 2012, Rolf-Werner Eilert wrote: > > > Hi folks, > > > > I would be interested in your opinions. In a project I've got two lists > > of data and further data which are mutually dependent, such as > > > > item 1: > > item 1 a > > data 1 aa > > data 1 ab > > item 1 b > > data 1 ba > > data 1 bb > > > > and so on, which could be seen like a tree or directory structure. > > > > Now my question is, how would YOU organize this internally? I mean, what > > kind of data structure would you prefer to be able to easily find your > > way through it? In the GUI, it looks like two ListBoxes and two TextBoxes: > > > > List1 List2 TextBox1 > > TextBox2 > > > > If you choose item1 in List1, List2 will show item1a and item1b. When > > you choose item1a, the Textboxes show data1aa and data1ab. If you choose > > item1b, the Textboxes show data1ba and data1bb. > > > > Of course, I could make a matrix of > > > > item1 item1a data1aa > > item1 item1a data1ab > > item1 item1b data1ba > > item1 item1b data1bb > > > > but how would my program EASILY find which data to show if the user > > clicks item1a for instance? Another idea was to leave out repetitions: > > > > item1 item1a data1aa > > data1ab > > item1b data1ba > > data1bb > > > > This shows the tree-like structure better, but is it a professional > > approach? > > > > Thanks for your ideas. > > > > Rolf > > > > ------------------------------------------------------------------------------ > > Keep Your Developer Skills Current with LearnDevNow! > > The most comprehensive online learning library for Microsoft developers > > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > > Metro Style Apps, more. Free future releases when you subscribe now! > > http://p.sf.net/sfu/learndevnow-d2d > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > well, my approach would be using a class that has an array of instances of the > same class (reminds me of linked lists). i don't know if it is possible in > gambas, haven't tried or read about it but it may look like: > > --- > CNode.class: > > Public Children As CNode[] > --- > > or, which may be more intuitive in later usage: > > --- > CNode.class: > > Inherits Array > > Public Children As CNode[] > > Public Function _get(iInd As Integer) As CNode > Return Me.Children[iInd] > End > --- > > in fact, i haven't programmed in Gambas for about a month and have no > possibility to check my suggestions but i think you see the point. > > regards, > tobi > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user ------- End of Original Message ------- From math.eber at ...221... Tue Feb 28 21:40:18 2012 From: math.eber at ...221... (Matti) Date: Tue, 28 Feb 2012 21:40:18 +0100 Subject: [Gambas-user] Was there a masked edit box? In-Reply-To: <4F4CC359.2070808@...221...> References: <4F4CC359.2070808@...221...> Message-ID: <4F4D3BB2.2010308@...221...> Hi Rolf, What is your question? :) Really: "Was there..."? - I don't remember. From the docs, I don't think so. Or: "Is there... in gambas3"? - Yes: http://gambasdoc.org/help/comp/gb.form/maskbox?v3 Am 28.02.2012 13:06, schrieb Rolf-Werner Eilert: > I faintly remember there was some masked edit box in Gambas2, or am I > wrong? I mean something where you could set some control chars to define > your own way of editing (e. g. "hh:mm" or "$$$$,## ?" or so). > > Thanks for your hints... > > Rolf From rterry at ...1823... Tue Feb 28 23:47:27 2012 From: rterry at ...1823... (richard terry) Date: Wed, 29 Feb 2012 09:47:27 +1100 Subject: [Gambas-user] ?gambas bug dateadd with leap years??? Message-ID: <201202290947.27685.rterry@...1823...> Hi List, Benoit My program crashed today when using dateadd: DateAdd(Now, gb.Year, iNumberOfYears) has worked for eons in my recall system dateAdd using gb.month still works. I reverted back from the latest svn to an older one > no difference. Could this be a leap year bug? richard From Gambas at ...1950... Wed Feb 29 00:08:25 2012 From: Gambas at ...1950... (Caveat) Date: Wed, 29 Feb 2012 00:08:25 +0100 Subject: [Gambas-user] ?gambas bug dateadd with leap years??? In-Reply-To: <201202290947.27685.rterry@...1823...> References: <201202290947.27685.rterry@...1823...> Message-ID: <1330470505.2873.278.camel@...2150...> Yeah, strange... you can add 12 months (temporary workaround?) but adding a year results in an invalid date error... Print DateAdd(Now, gb.Month, 12) 'OK Print DateAdd(Now, gb.Year, 1) ' Gives invalid date Kind regards, Caveat On Wed, 2012-02-29 at 09:47 +1100, richard terry wrote: > Hi List, Benoit > > My program crashed today when using dateadd: > > > DateAdd(Now, gb.Year, iNumberOfYears) has worked for eons in my recall system > > dateAdd using gb.month still works. > > I reverted back from the latest svn to an older one > no difference. > > Could this be a leap year bug? > > richard From gambas at ...1... Wed Feb 29 00:34:20 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Wed, 29 Feb 2012 00:34:20 +0100 Subject: [Gambas-user] ?gambas bug dateadd with leap years??? In-Reply-To: <1330470505.2873.278.camel@...2150...> References: <201202290947.27685.rterry@...1823...> <1330470505.2873.278.camel@...2150...> Message-ID: <4F4D647C.4090300@...1...> Le 29/02/2012 00:08, Caveat a ?crit : > Yeah, strange... you can add 12 months (temporary workaround?) but > adding a year results in an invalid date error... > > Print DateAdd(Now, gb.Month, 12) 'OK > Print DateAdd(Now, gb.Year, 1) ' Gives invalid date > > Kind regards, > Caveat > Because adding months automatically round the day down if it exceeds the number of days in the month. But not adding year (and so you get 29/2/2013, an invalid date). I will fix that. Regards, -- Beno?t Minisini From gambas at ...1... Wed Feb 29 00:39:49 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Wed, 29 Feb 2012 00:39:49 +0100 Subject: [Gambas-user] ?gambas bug dateadd with leap years??? In-Reply-To: <4F4D647C.4090300@...1...> References: <201202290947.27685.rterry@...1823...> <1330470505.2873.278.camel@...2150...> <4F4D647C.4090300@...1...> Message-ID: <4F4D65C5.5090803@...1...> Le 29/02/2012 00:34, Beno?t Minisini a ?crit : > Le 29/02/2012 00:08, Caveat a ?crit : >> Yeah, strange... you can add 12 months (temporary workaround?) but >> adding a year results in an invalid date error... >> >> Print DateAdd(Now, gb.Month, 12) 'OK >> Print DateAdd(Now, gb.Year, 1) ' Gives invalid date >> >> Kind regards, >> Caveat >> > > Because adding months automatically round the day down if it exceeds the > number of days in the month. But not adding year (and so you get > 29/2/2013, an invalid date). > > I will fix that. > > Regards, > Fixed in revision #4515. Regards, -- Beno?t Minisini From rterry at ...1823... Wed Feb 29 01:41:45 2012 From: rterry at ...1823... (richard terry) Date: Wed, 29 Feb 2012 11:41:45 +1100 Subject: [Gambas-user] ?gambas bug dateadd with leap years??? In-Reply-To: <4F4D65C5.5090803@...1...> References: <201202290947.27685.rterry@...1823...> <4F4D647C.4090300@...1...> <4F4D65C5.5090803@...1...> Message-ID: <201202291141.45497.rterry@...1823...> On Wednesday 29 February 2012 10:39:49 Beno?t Minisini wrote: > Le 29/02/2012 00:34, Beno?t Minisini a ?crit : > > Le 29/02/2012 00:08, Caveat a ?crit : > >> Yeah, strange... you can add 12 months (temporary workaround?) but > >> adding a year results in an invalid date error... > >> > >> Print DateAdd(Now, gb.Month, 12) 'OK > >> Print DateAdd(Now, gb.Year, 1) ' Gives invalid date > >> > >> Kind regards, > >> Caveat > > > > Because adding months automatically round the day down if it exceeds the > > number of days in the month. But not adding year (and so you get > > 29/2/2013, an invalid date). > > > > I will fix that. > > > > Regards, > > Fixed in revision #4515. > > Regards, > confirm fixed - I can now add my patient recalls again when years involved on leap year. Cool.... Thanks for the unbeleivably quick response. Richard From kevinfishburne at ...1887... Wed Feb 29 06:45:37 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Wed, 29 Feb 2012 00:45:37 -0500 Subject: [Gambas-user] gb3: multiple errors Message-ID: <4F4DBB81.2070501@...1887...> I'm using the build from a few days ago (recompiling now) and get this error when trying to create a module in a new or existing project: This application has raised an unexpected error and must abort. [11] Unknown symbol 'Margin' in class 'FileChooser'. FCreateFile.FCreateFile.0 I also get a crash trying to run this code: ' Server Module Public Struct Server_QueueOut Acknowledged As Boolean ' Whether or not transaction has been acknowledged by recipient. Player As Short ' Number of player transaction was sent to. Timestamp As Float ' Time transaction was sent. Type As Byte ' Transaction type. Data As String ' Transaction payload. End Struct Public QueueOut[2000, 32768] As Struct Server_QueueOut ' Network module Public QueueSize As Short = 1023 ' Maximum number of incoming and outgoing transaction queue elements. ' Set outgoing transaction queue acknowledgments to true. For Counter2 = 0 To 1999 For Counter1 = 0 To QueueSize Server.QueueOut[Counter2, Counter1].Acknowledged = True Next Next It crashes the first time it tries to execute the "Server.QueueOut[Counter2, Counter1].Acknowledged = True" line. I'll let you know if the latest revision fixes it. -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From kevinfishburne at ...1887... Wed Feb 29 07:13:30 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Wed, 29 Feb 2012 01:13:30 -0500 Subject: [Gambas-user] gb3: multiple errors In-Reply-To: <4F4DBB81.2070501@...1887...> References: <4F4DBB81.2070501@...1887...> Message-ID: <4F4DC20A.7070701@...1887...> On 02/29/2012 12:45 AM, Kevin Fishburne wrote: > I'm using the build from a few days ago (recompiling now) and get this > error when trying to create a module in a new or existing project: > > This application has raised an unexpected error and must abort. > > [11] Unknown symbol 'Margin' in class 'FileChooser'. > FCreateFile.FCreateFile.0 > > I also get a crash trying to run this code: > > ' Server Module > > Public Struct Server_QueueOut > Acknowledged As Boolean ' Whether or not transaction has been > acknowledged by recipient. > Player As Short ' Number of player transaction was sent to. > Timestamp As Float ' Time transaction was sent. > Type As Byte ' Transaction type. > Data As String ' Transaction payload. > End Struct > Public QueueOut[2000, 32768] As Struct Server_QueueOut > > ' Network module > > Public QueueSize As Short = 1023 ' Maximum number of incoming and > outgoing transaction queue elements. > > ' Set outgoing transaction queue acknowledgments to true. > For Counter2 = 0 To 1999 > For Counter1 = 0 To QueueSize > Server.QueueOut[Counter2, Counter1].Acknowledged = True > Next > Next > > It crashes the first time it tries to execute the > "Server.QueueOut[Counter2, Counter1].Acknowledged = True" line. I'll let > you know if the latest revision fixes it. > > Looks like the new module error was caused by creating a new project in the same directory as an old project. The current gb3 build has the same second issue, which I captured here: http://eightvirtues.com/sanctimonia/misc/What%20the%20fuck%20is%20going%20on%3f.webm I recreated the basic code and variables in a test project and the issue didn't occur, so it has something to do with unrelated variables and modules. The change I made across my project was changing the queue size from 256 to 32768, so the QueueOut array went from this: Public QueueOut[2000, 256] As Struct Server_QueueOut to this: Public QueueOut[2000, 32768] As Struct Server_QueueOut -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From kevinfishburne at ...1887... Wed Feb 29 07:26:39 2012 From: kevinfishburne at ...1887... (Kevin Fishburne) Date: Wed, 29 Feb 2012 01:26:39 -0500 Subject: [Gambas-user] gb3: multiple errors In-Reply-To: <4F4DC20A.7070701@...1887...> References: <4F4DBB81.2070501@...1887...> <4F4DC20A.7070701@...1887...> Message-ID: <4F4DC51F.7060408@...1887...> On 02/29/2012 01:13 AM, Kevin Fishburne wrote: > On 02/29/2012 12:45 AM, Kevin Fishburne wrote: >> I'm using the build from a few days ago (recompiling now) and get this >> error when trying to create a module in a new or existing project: >> >> This application has raised an unexpected error and must abort. >> >> [11] Unknown symbol 'Margin' in class 'FileChooser'. >> FCreateFile.FCreateFile.0 >> >> I also get a crash trying to run this code: >> >> ' Server Module >> >> Public Struct Server_QueueOut >> Acknowledged As Boolean ' Whether or not transaction has been >> acknowledged by recipient. >> Player As Short ' Number of player transaction was sent to. >> Timestamp As Float ' Time transaction was sent. >> Type As Byte ' Transaction type. >> Data As String ' Transaction payload. >> End Struct >> Public QueueOut[2000, 32768] As Struct Server_QueueOut >> >> ' Network module >> >> Public QueueSize As Short = 1023 ' Maximum number of incoming and >> outgoing transaction queue elements. >> >> ' Set outgoing transaction queue acknowledgments to true. >> For Counter2 = 0 To 1999 >> For Counter1 = 0 To QueueSize >> Server.QueueOut[Counter2, Counter1].Acknowledged = True >> Next >> Next >> >> It crashes the first time it tries to execute the >> "Server.QueueOut[Counter2, Counter1].Acknowledged = True" line. I'll let >> you know if the latest revision fixes it. >> >> > Looks like the new module error was caused by creating a new project in > the same directory as an old project. > > The current gb3 build has the same second issue, which I captured here: > > http://eightvirtues.com/sanctimonia/misc/What%20the%20fuck%20is%20going%20on%3f.webm > > I recreated the basic code and variables in a test project and the issue > didn't occur, so it has something to do with unrelated variables and > modules. The change I made across my project was changing the queue size > from 256 to 32768, so the QueueOut array went from this: > > Public QueueOut[2000, 256] As Struct Server_QueueOut > > to this: > > Public QueueOut[2000, 32768] As Struct Server_QueueOut > Holy shit I may be a genius (obviously not). It appears that creating such a large array of structures caused a RAM issue. The initial declaration didn't raise an error, but attempting to read/write from/to the array caused a RAM usage spike which in turn caused the sig 11. I have 2 GB of RAM assigned to the VM I'm running the server in, and I can't believe that the array of structures actually consumed that much RAM. Let's say that it in fact did need that much RAM. Does GAMBAS normally handle such things gracefully, or is this a bug? -- Kevin Fishburne Eight Virtues www: http://sales.eightvirtues.com e-mail: sales at ...1887... phone: (770) 853-6271 From eilert-sprachen at ...221... Wed Feb 29 08:56:38 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 29 Feb 2012 08:56:38 +0100 Subject: [Gambas-user] Was there a masked edit box? In-Reply-To: <4F4D3BB2.2010308@...221...> References: <4F4CC359.2070808@...221...> <4F4D3BB2.2010308@...221...> Message-ID: <4F4DDA36.1050306@...221...> Am 28.02.2012 21:40, schrieb Matti: > Hi Rolf, > > What is your question? :) > > Really: "Was there..."? - I don't remember. From the docs, I don't think so. Yes, that was the question... > > Or: "Is there... in gambas3"? - Yes: > http://gambasdoc.org/help/comp/gb.form/maskbox?v3 Ok, that means, I remembered it from Gambas3. Currently, I'm sitting most of the time in front of an old system which has Gambas2 only. So I was somewhat lost... :-) But thanks for the link! Regards Rolf From john.aaron.rose at ...626... Wed Feb 29 10:10:47 2012 From: john.aaron.rose at ...626... (John Rose) Date: Wed, 29 Feb 2012 09:10:47 +0000 Subject: [Gambas-user] DataSource & DataBrowser problem Message-ID: <1330506647.3793.68.camel@...2661...> I just installed all Gambas3 packages from kendek's launchpad ppa for Gambas pre-release: he created them yesterday evening after using subversion. How do I find out the version number of Gambas3 that he used apart from asking him? The previous problem is fixed when I try to add a new row to a SQLite3 database table (i.e. the display of a popup stating "Cannot modify record: SQL error or missing database". However, there are now new problems: When the DataBrowser control is initialised, the left hand side of it points to the centre of the data (with the 'scrolling' point matching that) rather than the left of the data as it used to do. When the 'New' icon is clicked (to add a new row), the cursor does not move automatically to that row. When the 'Save' icon is clicked, no save of data takes place (checked by closing the app & starting it again) unless the 'New' icon is clicked again (that also causes the left hand side of it to point to the centre of the data). From eilert-sprachen at ...221... Wed Feb 29 12:56:06 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 29 Feb 2012 12:56:06 +0100 Subject: [Gambas-user] How to organize dependent lists In-Reply-To: <20120228173326.GC622@...2774...> References: <4F4D0C5A.5020904@...221...> <20120228173326.GC622@...2774...> Message-ID: <4F4E1256.4040209@...221...> Am 28.02.2012 18:33, schrieb tobi: > hi, > > On Tue, 28 Feb 2012, Rolf-Werner Eilert wrote: > >> Hi folks, >> >> I would be interested in your opinions. In a project I've got two lists >> of data and further data which are mutually dependent, such as >> >> item 1: >> item 1 a >> data 1 aa >> data 1 ab >> item 1 b >> data 1 ba >> data 1 bb >> >> and so on, which could be seen like a tree or directory structure. >> >> Now my question is, how would YOU organize this internally? I mean, what >> kind of data structure would you prefer to be able to easily find your >> way through it? In the GUI, it looks like two ListBoxes and two TextBoxes: >> >> List1 List2 TextBox1 >> TextBox2 >> >> If you choose item1 in List1, List2 will show item1a and item1b. When >> you choose item1a, the Textboxes show data1aa and data1ab. If you choose >> item1b, the Textboxes show data1ba and data1bb. >> >> Of course, I could make a matrix of >> >> item1 item1a data1aa >> item1 item1a data1ab >> item1 item1b data1ba >> item1 item1b data1bb >> >> but how would my program EASILY find which data to show if the user >> clicks item1a for instance? Another idea was to leave out repetitions: >> >> item1 item1a data1aa >> data1ab >> item1b data1ba >> data1bb >> >> This shows the tree-like structure better, but is it a professional >> approach? >> >> Thanks for your ideas. >> >> Rolf >> >> ------------------------------------------------------------------------------ >> Keep Your Developer Skills Current with LearnDevNow! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-d2d >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > well, my approach would be using a class that has an array of instances of the same class (reminds > me of linked lists). i don't know if it is possible in gambas, haven't tried or read about it but it > may look like: > > --- > CNode.class: > > Public Children As CNode[] > --- > > or, which may be more intuitive in later usage: > > --- > CNode.class: > > Inherits Array > > Public Children As CNode[] > > Public Function _get(iInd As Integer) As CNode > Return Me.Children[iInd] > End > --- > > in fact, i haven't programmed in Gambas for about a month and have no possibility to check my > suggestions but i think you see the point. > > regards, > tobi Thank you, Tobi, Nando had a similar idea. I've never tried that, but now I see a chance to get this organized. Regards Rolf From eilert-sprachen at ...221... Wed Feb 29 12:57:15 2012 From: eilert-sprachen at ...221... (Rolf-Werner Eilert) Date: Wed, 29 Feb 2012 12:57:15 +0100 Subject: [Gambas-user] How to organize dependent lists In-Reply-To: <20120228201328.M46026@...951...> References: <4F4D0C5A.5020904@...221...> <20120228173326.GC622@...2774...> <20120228201328.M46026@...951...> Message-ID: <4F4E129B.80201@...221...> Thanks a lot for your ideas, I'll try and see if I get this organized with it. If anything goes wrong, I'll be back! :-) Regards Rolf Am 28.02.2012 21:17, schrieb nando: > The second level OBJECT[] actually turns out to be an array of Classes. > My experience is people understand the OBJECT[] way because of the container > within a container concept. > It is the same thing :) > > > > ---------- Original Message ----------- > From: tobi > To: info at ...394..., mailing list for gambas users > Sent: Tue, 28 Feb 2012 18:33:26 +0100 > Subject: Re: [Gambas-user] How to organize dependent lists > >> hi, >> >> On Tue, 28 Feb 2012, Rolf-Werner Eilert wrote: >> >>> Hi folks, >>> >>> I would be interested in your opinions. In a project I've got two lists >>> of data and further data which are mutually dependent, such as >>> >>> item 1: >>> item 1 a >>> data 1 aa >>> data 1 ab >>> item 1 b >>> data 1 ba >>> data 1 bb >>> >>> and so on, which could be seen like a tree or directory structure. >>> >>> Now my question is, how would YOU organize this internally? I mean, what >>> kind of data structure would you prefer to be able to easily find your >>> way through it? In the GUI, it looks like two ListBoxes and two TextBoxes: >>> >>> List1 List2 TextBox1 >>> TextBox2 >>> >>> If you choose item1 in List1, List2 will show item1a and item1b. When >>> you choose item1a, the Textboxes show data1aa and data1ab. If you choose >>> item1b, the Textboxes show data1ba and data1bb. >>> >>> Of course, I could make a matrix of >>> >>> item1 item1a data1aa >>> item1 item1a data1ab >>> item1 item1b data1ba >>> item1 item1b data1bb >>> >>> but how would my program EASILY find which data to show if the user >>> clicks item1a for instance? Another idea was to leave out repetitions: >>> >>> item1 item1a data1aa >>> data1ab >>> item1b data1ba >>> data1bb >>> >>> This shows the tree-like structure better, but is it a professional >>> approach? >>> >>> Thanks for your ideas. >>> >>> Rolf >>> >>> ------------------------------------------------------------------------------ >>> Keep Your Developer Skills Current with LearnDevNow! >>> The most comprehensive online learning library for Microsoft developers >>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >>> Metro Style Apps, more. Free future releases when you subscribe now! >>> http://p.sf.net/sfu/learndevnow-d2d >>> _______________________________________________ >>> Gambas-user mailing list >>> Gambas-user at lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> well, my approach would be using a class that has an array of instances of the >> same class (reminds me of linked lists). i don't know if it is possible in >> gambas, haven't tried or read about it but it may look like: >> >> --- >> CNode.class: >> >> Public Children As CNode[] >> --- >> >> or, which may be more intuitive in later usage: >> >> --- >> CNode.class: >> >> Inherits Array >> >> Public Children As CNode[] >> >> Public Function _get(iInd As Integer) As CNode >> Return Me.Children[iInd] >> End >> --- >> >> in fact, i haven't programmed in Gambas for about a month and have no >> possibility to check my suggestions but i think you see the point. >> >> regards, >> tobi >> >> ------------------------------------------------------------------------------ >> Keep Your Developer Skills Current with LearnDevNow! >> The most comprehensive online learning library for Microsoft developers >> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, >> Metro Style Apps, more. Free future releases when you subscribe now! >> http://p.sf.net/sfu/learndevnow-d2d >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > ------- End of Original Message ------- > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jeanluc.bertin277 at ...1661... Wed Feb 29 13:08:29 2012 From: jeanluc.bertin277 at ...1661... (TME) Date: Wed, 29 Feb 2012 04:08:29 -0800 (PST) Subject: [Gambas-user] gambas3 ans debain squeeze Message-ID: <33410649.post@...1379...> Hello I try to compile gambas3 on debian squeeze Somebody can say to me what are packages-dev necessary for the compilation (after download => svn checkout https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/) ? I found nothing on this subject thanck you jean-luc -- View this message in context: http://old.nabble.com/gambas3-ans-debain-squeeze-tp33410649p33410649.html Sent from the gambas-user mailing list archive at Nabble.com. From jeanluc.bertin277 at ...1661... Wed Feb 29 13:08:49 2012 From: jeanluc.bertin277 at ...1661... (TME) Date: Wed, 29 Feb 2012 04:08:49 -0800 (PST) Subject: [Gambas-user] gambas3 ans debain squeeze In-Reply-To: <33410649.post@...1379...> References: <33410649.post@...1379...> Message-ID: <33413267.post@...1379...> Hi I tried to complier with the package for Ubuntu Lucid The result for /config -C give me that : || || GTK+ toolkit is disabled || || Cairo component is disabled || FreeType backend for Cairo is disabled || || Image loading and saving is disabled || || GNU Scientific Library component is disabled || || THESE COMPONENTS ARE DISABLED: || - gb.cairo || - gb.gsl || - gb.gtk || - gb.image.io Somebody would know he to which packages-dev it corresponds? Thank you for your replie regards jean-luc -- View this message in context: http://old.nabble.com/gambas3-ans-debain-squeeze-tp33410649p33413267.html Sent from the gambas-user mailing list archive at Nabble.com. From ea7dfh at ...2382... Wed Feb 29 14:14:12 2012 From: ea7dfh at ...2382... (Jesus) Date: Wed, 29 Feb 2012 14:14:12 +0100 Subject: [Gambas-user] gambas3 ans debain squeeze In-Reply-To: <33413267.post@...1379...> References: <33410649.post@...1379...> <33413267.post@...1379...> Message-ID: <4F4E24A4.60106@...2382...> El 29/02/12 13:08, TME escribi?: > > Hi > > I tried to complier with the package for Ubuntu Lucid > The result for /config -C give me that : > || > || GTK+ toolkit is disabled > || > || Cairo component is disabled > || FreeType backend for Cairo is disabled > || > || Image loading and saving is disabled > || > || GNU Scientific Library component is disabled > || > || THESE COMPONENTS ARE DISABLED: > || - gb.cairo > || - gb.gsl > || - gb.gtk > || - gb.image.io > > Somebody would know he to which packages-dev it corresponds? > > Thank you for your replie > regards > jean-luc > Hi jean-luc As stated in the wiki, http://gambasdoc.org/help/install/ubuntu?v3 these are the dependencies for Ubuntu which is based on Debian. Try with these, may be some of them should not be exact, but you are in the way. Look in your package manager for similar names. sudo apt-get install build-essential autoconf libbz2-dev libfbclient2 libmysqlclient-dev unixodbc-dev libpq-dev libsqlite0-dev libsqlite3-dev libgtk2.0-dev libldap2-dev libcurl4-gnutls-dev libgtkglext1-dev libpcre3-dev libsdl-sound1.2-dev libsdl-mixer1.2-dev libsdl-image1.2-dev libsage-dev libxml2-dev libxslt1-dev libbonobo2-dev libcos4-dev libomniorb4-dev librsvg2-dev libpoppler-dev libpoppler-glib-dev libasound2-dev libesd0-dev libdirectfb-dev libaa1-dev libxtst-dev libffi-dev kdelibs4-dev firebird2.1-dev libqt4-dev libglew1.5-dev libimlib2-dev libv4l-dev libsdl-ttf2.0-dev libgnome-keyring-dev libgdk-pixbuf2.0-dev linux-libc-dev Regards -- Jesus Guardon From gambas at ...1... Wed Feb 29 14:42:22 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Wed, 29 Feb 2012 14:42:22 +0100 Subject: [Gambas-user] gb3: multiple errors In-Reply-To: <4F4DC51F.7060408@...1887...> References: <4F4DBB81.2070501@...1887...> <4F4DC20A.7070701@...1887...> <4F4DC51F.7060408@...1887...> Message-ID: <4F4E2B3E.3080807@...1...> Le 29/02/2012 07:26, Kevin Fishburne a ?crit : >>> >>> Public Struct Server_QueueOut >>> Acknowledged As Boolean ' Whether or not transaction has been >>> acknowledged by recipient. >>> Player As Short ' Number of player transaction was sent to. >>> Timestamp As Float ' Time transaction was sent. >>> Type As Byte ' Transaction type. >>> Data As String ' Transaction payload. >>> End Struct Size of the structure (32 bits) : 8 (Gambas object base) + 1 + 1 (padding) + 2 + 4 (padding) + 8 + 1 + 3 (padding) + 4 = 32 bytes >>> Public QueueOut[2000, 32768] As Struct Server_QueueOut 2000 * 32768 * 32 = 2097152000 bytes = 2 Gb. It's worse on 64 bits because of the padding. -- Beno?t Minisini From emil.lenngren at ...626... Wed Feb 29 14:46:21 2012 From: emil.lenngren at ...626... (Emil Lenngren) Date: Wed, 29 Feb 2012 14:46:21 +0100 Subject: [Gambas-user] gb3: multiple errors In-Reply-To: <4F4E2B3E.3080807@...1...> References: <4F4DBB81.2070501@...1887...> <4F4DC20A.7070701@...1887...> <4F4DC51F.7060408@...1887...> <4F4E2B3E.3080807@...1...> Message-ID: Arrange the struct like this to get zero padding (I think): Data As String Timestamp As Float Player As Short Type As Byte Acknowledged As Boolean 2012/2/29 Beno?t Minisini > Le 29/02/2012 07:26, Kevin Fishburne a ?crit : > >>> > >>> Public Struct Server_QueueOut > >>> Acknowledged As Boolean ' Whether or not transaction has been > >>> acknowledged by recipient. > >>> Player As Short ' Number of player transaction was sent > to. > >>> Timestamp As Float ' Time transaction was sent. > >>> Type As Byte ' Transaction type. > >>> Data As String ' Transaction payload. > >>> End Struct > > Size of the structure (32 bits) : > 8 (Gambas object base) > + 1 > + 1 (padding) > + 2 > + 4 (padding) > + 8 > + 1 > + 3 (padding) > + 4 > = 32 bytes > > >>> Public QueueOut[2000, 32768] As Struct Server_QueueOut > > 2000 * 32768 * 32 = 2097152000 bytes = 2 Gb. > > It's worse on 64 bits because of the padding. > > -- > Beno?t Minisini > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From gambas at ...1... Wed Feb 29 14:48:28 2012 From: gambas at ...1... (=?ISO-8859-1?Q?Beno=EEt_Minisini?=) Date: Wed, 29 Feb 2012 14:48:28 +0100 Subject: [Gambas-user] DataSource & DataBrowser problem In-Reply-To: <1330506647.3793.68.camel@...2661...> References: <1330506647.3793.68.camel@...2661...> Message-ID: <4F4E2CAC.1090201@...1...> Le 29/02/2012 10:10, John Rose a ?crit : > I just installed all Gambas3 packages from kendek's launchpad ppa for > Gambas pre-release: he created them yesterday evening after using > subversion. How do I find out the version number of Gambas3 that he used > apart from asking him? Ask him : or find the package creation date, I will guess the revison number from it. Usually the revision number is put in the package name. > > The previous problem is fixed when I try to add a new row to a SQLite3 > database table (i.e. the display of a popup stating "Cannot modify > record: SQL error or missing database". However, there are now new > problems: > > When the DataBrowser control is initialised, the left hand side of it > points to the centre of the data (with the 'scrolling' point matching > that) rather than the left of the data as it used to do. > > When the 'New' icon is clicked (to add a new row), the cursor does not > move automatically to that row. > > When the 'Save' icon is clicked, no save of data takes place (checked by > closing the app& starting it again) unless the 'New' icon is clicked > again (that also causes the left hand side of it to point to the centre > of the data). > Do you use gb.gtk or gb.qt4? -- Beno?t Minisini From jeanluc.bertin277 at ...1661... Wed Feb 29 16:31:46 2012 From: jeanluc.bertin277 at ...1661... (TME) Date: Wed, 29 Feb 2012 07:31:46 -0800 (PST) Subject: [Gambas-user] gambas3 ans debain squeeze In-Reply-To: <4F4E24A4.60106@...2382...> References: <33410649.post@...1379...> <33413267.post@...1379...> <4F4E24A4.60106@...2382...> Message-ID: <33414841.post@...1379...> Thank you for your replies I tried with library Ubuntu Lucid, Ubuntu Maverick, and other library Ubuntu I have always the same result : ===> GTK+ toolkit is disabled Cairo component is disabled ,FreeType backend for Cairo is disabled Image loading and saving is disabled GNU Scientific Library component is disabled THESE COMPONENTS ARE DISABLED: gb.cairo gb.gsl gb.gtk gb.image.io Nobody has installed Gambas3 on Debian squeeze with KDE ? Jesus-21 wrote: > > El 29/02/12 13:08, TME escribi?: >> >> Hi >> >> I tried to complier with the package for Ubuntu Lucid >> The result for /config -C give me that : >> || >> || GTK+ toolkit is disabled >> || >> || Cairo component is disabled >> || FreeType backend for Cairo is disabled >> || >> || Image loading and saving is disabled >> || >> || GNU Scientific Library component is disabled >> || >> || THESE COMPONENTS ARE DISABLED: >> || - gb.cairo >> || - gb.gsl >> || - gb.gtk >> || - gb.image.io >> >> Somebody would know he to which packages-dev it corresponds? >> >> Thank you for your replie >> regards >> jean-luc >> > > > Hi jean-luc > > As stated in the wiki, http://gambasdoc.org/help/install/ubuntu?v3 > these are the dependencies for Ubuntu which is based on Debian. > Try with these, may be some of them should not be exact, but you are in > the way. Look in your package manager for similar names. > > sudo apt-get install build-essential autoconf libbz2-dev libfbclient2 > libmysqlclient-dev unixodbc-dev libpq-dev libsqlite0-dev libsqlite3-dev > libgtk2.0-dev libldap2-dev libcurl4-gnutls-dev libgtkglext1-dev > libpcre3-dev libsdl-sound1.2-dev libsdl-mixer1.2-dev libsdl-image1.2-dev > libsage-dev libxml2-dev libxslt1-dev libbonobo2-dev libcos4-dev > libomniorb4-dev librsvg2-dev libpoppler-dev libpoppler-glib-dev > libasound2-dev libesd0-dev libdirectfb-dev libaa1-dev libxtst-dev > libffi-dev kdelibs4-dev firebird2.1-dev libqt4-dev libglew1.5-dev > libimlib2-dev libv4l-dev libsdl-ttf2.0-dev libgnome-keyring-dev > libgdk-pixbuf2.0-dev linux-libc-dev > > Regards > -- > Jesus Guardon > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- View this message in context: http://old.nabble.com/gambas3-ans-debain-squeeze-tp33410649p33414841.html Sent from the gambas-user mailing list archive at Nabble.com. From jussi.lahtinen at ...626... Wed Feb 29 16:41:09 2012 From: jussi.lahtinen at ...626... (Jussi Lahtinen) Date: Wed, 29 Feb 2012 17:41:09 +0200 Subject: [Gambas-user] gambas3 ans debain squeeze In-Reply-To: <33414841.post@...1379...> References: <33410649.post@...1379...> <33413267.post@...1379...> <4F4E24A4.60106@...2382...> <33414841.post@...1379...> Message-ID: http://gambasdoc.org/help/doc/distro?en&view http://gambasdoc.org/help/install?en&view Jussi On Wed, Feb 29, 2012 at 17:31, TME wrote: > > Thank you for your replies > > I tried with library Ubuntu Lucid, Ubuntu Maverick, and other library > Ubuntu > I have always the same result : > ===> > GTK+ toolkit is disabled > Cairo component is disabled ,FreeType backend for Cairo is disabled > Image loading and saving is disabled > GNU Scientific Library component is disabled > THESE COMPONENTS ARE DISABLED: > gb.cairo > gb.gsl > gb.gtk > gb.image.io > > Nobody has installed Gambas3 on Debian squeeze with KDE ? > > > > > Jesus-21 wrote: > > > > El 29/02/12 13:08, TME escribi?: > >> > >> Hi > >> > >> I tried to complier with the package for Ubuntu Lucid > >> The result for /config -C give me that : > >> || > >> || GTK+ toolkit is disabled > >> || > >> || Cairo component is disabled > >> || FreeType backend for Cairo is disabled > >> || > >> || Image loading and saving is disabled > >> || > >> || GNU Scientific Library component is disabled > >> || > >> || THESE COMPONENTS ARE DISABLED: > >> || - gb.cairo > >> || - gb.gsl > >> || - gb.gtk > >> || - gb.image.io > >> > >> Somebody would know he to which packages-dev it corresponds? > >> > >> Thank you for your replie > >> regards > >> jean-luc > >> > > > > > > Hi jean-luc > > > > As stated in the wiki, http://gambasdoc.org/help/install/ubuntu?v3 > > these are the dependencies for Ubuntu which is based on Debian. > > Try with these, may be some of them should not be exact, but you are in > > the way. Look in your package manager for similar names. > > > > sudo apt-get install build-essential autoconf libbz2-dev libfbclient2 > > libmysqlclient-dev unixodbc-dev libpq-dev libsqlite0-dev libsqlite3-dev > > libgtk2.0-dev libldap2-dev libcurl4-gnutls-dev libgtkglext1-dev > > libpcre3-dev libsdl-sound1.2-dev libsdl-mixer1.2-dev libsdl-image1.2-dev > > libsage-dev libxml2-dev libxslt1-dev libbonobo2-dev libcos4-dev > > libomniorb4-dev librsvg2-dev libpoppler-dev libpoppler-glib-dev > > libasound2-dev libesd0-dev libdirectfb-dev libaa1-dev libxtst-dev > > libffi-dev kdelibs4-dev firebird2.1-dev libqt4-dev libglew1.5-dev > > libimlib2-dev libv4l-dev libsdl-ttf2.0-dev libgnome-keyring-dev > > libgdk-pixbuf2.0-dev linux-libc-dev > > > > Regards > > -- > > Jesus Guardon > > > > > ------------------------------------------------------------------------------ > > Virtualization & Cloud Management Using Capacity Planning > > Cloud computing makes use of virtualization - but cloud computing > > also focuses on allowing computing to be delivered as a service. > > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > > _______________________________________________ > > Gambas-user mailing list > > Gambas-user at lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > -- > View this message in context: > http://old.nabble.com/gambas3-ans-debain-squeeze-tp33410649p33414841.html > Sent from the gambas-user mailing list archive at Nabble.com. > > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From jeanluc.bertin277 at ...1661... Wed Feb 29 16:59:19 2012 From: jeanluc.bertin277 at ...1661... (TME) Date: Wed, 29 Feb 2012 07:59:19 -0800 (PST) Subject: [Gambas-user] gambas3 ans debain squeeze In-Reply-To: References: <33410649.post@...1379...> <33413267.post@...1379...> <4F4E24A4.60106@...2382...> <33414841.post@...1379...> Message-ID: <33415029.post@...1379...> Jussi Lahtinen yes i know ! before post here i tried this web :working: I post message here because in list french gambas user, Beno?t Minisini say me that there is an error in list of package for Debian and gambas 3! Beno?t Minisini => "Cette ligne est pour Gambas 2 apparemment, pas pour Gambas 3. La personne qui a ?crit ?a a fait une erreur." Jussi Lahtinen wrote: > > http://gambasdoc.org/help/doc/distro?en&view > http://gambasdoc.org/help/install?en&view > > Jussi > > > > On Wed, Feb 29, 2012 at 17:31, TME wrote: > >> >> Thank you for your replies >> >> I tried with library Ubuntu Lucid, Ubuntu Maverick, and other library >> Ubuntu >> I have always the same result : >> ===> >> GTK+ toolkit is disabled >> Cairo component is disabled ,FreeType backend for Cairo is disabled >> Image loading and saving is disabled >> GNU Scientific Library component is disabled >> THESE COMPONENTS ARE DISABLED: >> gb.cairo >> gb.gsl >> gb.gtk >> gb.image.io >> >> Nobody has installed Gambas3 on Debian squeeze with KDE ? >> >> >> >> >> Jesus-21 wrote: >> > >> > El 29/02/12 13:08, TME escribi?: >> >> >> >> Hi >> >> >> >> I tried to complier with the package for Ubuntu Lucid >> >> The result for /config -C give me that : >> >> || >> >> || GTK+ toolkit is disabled >> >> || >> >> || Cairo component is disabled >> >> || FreeType backend for Cairo is disabled >> >> || >> >> || Image loading and saving is disabled >> >> || >> >> || GNU Scientific Library component is disabled >> >> || >> >> || THESE COMPONENTS ARE DISABLED: >> >> || - gb.cairo >> >> || - gb.gsl >> >> || - gb.gtk >> >> || - gb.image.io >> >> >> >> Somebody would know he to which packages-dev it corresponds? >> >> >> >> Thank you for your replie >> >> regards >> >> jean-luc >> >> >> > >> > >> > Hi jean-luc >> > >> > As stated in the wiki, http://gambasdoc.org/help/install/ubuntu?v3 >> > these are the dependencies for Ubuntu which is based on Debian. >> > Try with these, may be some of them should not be exact, but you are in >> > the way. Look in your package manager for similar names. >> > >> > sudo apt-get install build-essential autoconf libbz2-dev libfbclient2 >> > libmysqlclient-dev unixodbc-dev libpq-dev libsqlite0-dev libsqlite3-dev >> > libgtk2.0-dev libldap2-dev libcurl4-gnutls-dev libgtkglext1-dev >> > libpcre3-dev libsdl-sound1.2-dev libsdl-mixer1.2-dev >> libsdl-image1.2-dev >> > libsage-dev libxml2-dev libxslt1-dev libbonobo2-dev libcos4-dev >> > libomniorb4-dev librsvg2-dev libpoppler-dev libpoppler-glib-dev >> > libasound2-dev libesd0-dev libdirectfb-dev libaa1-dev libxtst-dev >> > libffi-dev kdelibs4-dev firebird2.1-dev libqt4-dev libglew1.5-dev >> > libimlib2-dev libv4l-dev libsdl-ttf2.0-dev libgnome-keyring-dev >> > libgdk-pixbuf2.0-dev linux-libc-dev >> > >> > Regards >> > -- >> > Jesus Guardon >> > >> > >> ------------------------------------------------------------------------------ >> > Virtualization & Cloud Management Using Capacity Planning >> > Cloud computing makes use of virtualization - but cloud computing >> > also focuses on allowing computing to be delivered as a service. >> > http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> > _______________________________________________ >> > Gambas-user mailing list >> > Gambas-user at lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/gambas-user >> > >> > >> >> -- >> View this message in context: >> http://old.nabble.com/gambas3-ans-debain-squeeze-tp33410649p33414841.html >> Sent from the gambas-user mailing list archive at Nabble.com. >> >> >> >> ------------------------------------------------------------------------------ >> Virtualization & Cloud Management Using Capacity Planning >> Cloud computing makes use of virtualization - but cloud computing >> also focuses on allowing computing to be delivered as a service. >> http://www.accelacomm.com/jaw/sfnl/114/51521223/ >> _______________________________________________ >> Gambas-user mailing list >> Gambas-user at lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity Planning > Cloud computing makes use of virtualization - but cloud computing > also focuses on allowing computing to be delivered as a service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > > -- View this message in context: http://old.nabble.com/gambas3-ans-debain-squeeze-tp33410649p33415029.html Sent from the gambas-user mailing list archive at Nabble.com. From arnaudien at ...67... Wed Feb 29 22:17:16 2012 From: arnaudien at ...67... (. .) Date: Wed, 29 Feb 2012 21:17:16 +0000 Subject: [Gambas-user] gambas3 ans debain squeeze In-Reply-To: <33415029.post@...1379...> References: <33410649.post@...1379...> <33413267.post@...1379...>,<4F4E24A4.60106@...2382...> <33414841.post@...1379...>, , <33415029.post@...1379...> Message-ID: Hi, I use Gambas 3 on Debian Squeeze. First of all, remove the previous installed version (in root, with whereis command) I install the requirementsapt-get install build-essential autoconf libbz2-dev libfbclient2 \ libmysqlclient-dev unixodbc-dev libpq-dev libsqlite0-dev libsqlite3-dev \ libgtk2.0-dev libldap2-dev libcurl4-gnutls-dev libgtkglext1-dev libpcre3-dev \ libsdl-sound1.2-dev libsdl-mixer1.2-dev libsdl-image1.2-dev libsage-dev \ libxml2-dev libxslt1-dev libbonobo2-dev libcos4-dev libomniorb4-dev \ librsvg2-dev libpoppler-dev libpoppler-glib-dev libasound2-dev libesd0-dev \ libdirectfb-dev libaa1-dev libxtst-dev libffi-dev kdelibs4-dev firebird2.1-dev \ libqt4-dev libglew1.5-dev libimlib2-dev libv4l-dev libsdl-ttf2.0-dev \ libgnome-keyring-dev# I don't know why this lib doesn't install on Debian but it's OK on Ubuntuapt-get install libgdk-pixbuf2.0-devI get the last version SVNmkdir trunk svn checkout https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/ cd trunk ./reconf-all ./configure -C make sudo make install For Archlinux users# remove previous gambas versionyaourt -R gambas3 # install requirements yaourt -S automake autoconf gcc intltool mysql postgresql \ libffi bzip2 glib2 v4l-utils zlib mesa libgl glew xdg-utils gtk2 imlib2 \ gdk-pixbuf2 postgresql-libs libmysqlclient unixodbc sqlite2 sqlite3 \ librsvg curl poppler sdl_mixer sdl_ttf libxtst pcre libxcursor libsm \ dbus-core libxml2 libxslt libgnome-keyring The last step with svn is the same as Debian install. Hope it can help. --Arnaud From rterry at ...1823... Wed Feb 29 22:21:35 2012 From: rterry at ...1823... (richard terry) Date: Thu, 1 Mar 2012 08:21:35 +1100 Subject: [Gambas-user] mouse down bug in Form IDE Message-ID: <201203010821.35126.rterry@...1823...> SVN is 4515 but this bug has been present for a while I've tried to narrow it down without success, but roughly seems to occur when a form is shown in the ide and the first thing you do is click on a control. If one goes to the hierachy tree first, clicks on anything, then goes back to the IDE it seems not to occur. see the picture. -------------- next part -------------- A non-text attachment was scrubbed... Name: mouse_down_png.png Type: image/png Size: 30894 bytes Desc: not available URL: From abbat.81 at ...787... Wed Feb 29 23:28:15 2012 From: abbat.81 at ...787... (abbat) Date: Wed, 29 Feb 2012 14:28:15 -0800 (PST) Subject: [Gambas-user] Process in TableVew and to Kill a Process Message-ID: <33417515.post@...1379...> Help me please. 1) How to situate processes in TableView or GridView by Name and PID columns? 2) How to kill Process? I cannot find any example of it and about Process.Kill. I tried: Dim p As Process = "tvtime" p.Kill ____ Process.Kill(9207) _____ Process.Kill(tvtime) Its does not work. Thank you -- View this message in context: http://old.nabble.com/Process-in-TableVew-and-to-Kill-a-Process-tp33417515p33417515.html Sent from the gambas-user mailing list archive at Nabble.com. From jeanluc.bertin277 at ...1661... Wed Feb 29 23:37:15 2012 From: jeanluc.bertin277 at ...1661... (TME) Date: Wed, 29 Feb 2012 14:37:15 -0800 (PST) Subject: [Gambas-user] gambas3 ans debain squeeze In-Reply-To: References: <33410649.post@...1379...> <33413267.post@...1379...> <4F4E24A4.60106@...2382...> <33414841.post@...1379...> <33415029.post@...1379...> Message-ID: <33417552.post@...1379...> Thanck Arnaud :drunk: but i have always the same result: ------------------------------------------------------------------ GTK+ toolkit is disabled Cairo component is disabled ,FreeType backend for Cairo is disabled Image loading and saving is disabled GNU Scientific Library component is disabled gb.cairo gb.gsl gb.gtk gb.image.io are disabled ------------------------------------------------------------------- and when i install the package-dev : -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- jean-luc at ...57...:~$ sudo aptitude install build-essential autoconf libbz2-dev libfbclient2 libmysqlclient-dev unixodbc-dev libpq-dev libsqlite0-dev libsqlite3-dev libgtk2.0-dev libldap2-dev libcurl4-gnutls-dev libgtkglext1-dev libpcre3-dev libsdl-sound1.2-dev libsdl-mixer1.2-dev libsdl-image1.2-dev libsage-dev libxml2-dev libxslt1-dev libbonobo2-dev libcos4-dev libomniorb4-dev librsvg2-dev libpoppler-dev libpoppler-glib-dev libasound2-dev libesd0-dev libdirectfb-dev libaa1-dev libxtst-dev libffi-dev kdelibs4-dev firebird2.1-dev libqt4-dev libglew1.5-dev libimlib2-dev libv4l-dev libsdl-ttf2.0-dev libgnome-keyring-dev libgdk-pixbuf2.0-dev Impossible de trouver un paquet dont le nom ou la description correspond ? ??libgdk-pixbuf2.0-dev?? Impossible de trouver un paquet dont le nom ou la description correspond ? ??libgdk-pixbuf2.0-dev?? Les NOUVEAUX paquets suivants vont ?tre install?s?: libcairo2-dev{ab} libcurl4-gnutls-dev{b} libgtk2.0-dev libgtkglext1-dev libpango1.0-dev{a} libpoppler-glib-dev librsvg2-dev 0 paquets mis ? jour, 7 nouvellement install?s, 0 ? enlever et 0 non mis ? jour. Il est n?cessaire de t?l?charger 5 708 ko/6 748 ko d'archives. Apr?s d?paquetage, 20,1 Mo seront utilis?s. Les paquets suivants ont des d?pendances non satisfaites?: libcurl4-gnutls-dev: Est en conflit avec: libcurl-dev qui est un paquet virtuel libcairo2-dev: D?pend: libpixman-1-dev (>= 0.18.4) mais il ne sera pas install?. libcurl4-openssl-dev: Est en conflit avec: libcurl-dev qui est un paquet virtuel Les actions suivantes permettront de r?soudre ces d?pendances?: Supprimer les paquets suivants?: 1) libcurl4-openssl-dev Conserver les paquets suivants dans leur version actuelle?: 2) libcairo2-dev [Non install?] 3) libgtk2.0-dev [Non install?] 4) libgtkglext1-dev [Non install?] 5) libpango1.0-dev [Non install?] 6) libpoppler-glib-dev [Non install?] 7) librsvg2-dev [Non install?] Accepter cette solution?? [Y/n/q/?] y Les NOUVEAUX paquets suivants vont ?tre install?s?: libcurl4-gnutls-dev Les paquets suivants seront ENLEV?S?: libcurl3{u} libcurl4-openssl-dev{a} libssh2-1{u} libssh2-1-dev{u} 0 paquets mis ? jour, 1 nouvellement install?s, 4 ? enlever et 0 non mis ? jour. Il est n?cessaire de t?l?charger 0 o/1 040 ko d'archives. Apr?s d?paquetage, 2 077 ko seront lib?r?s. Voulez-vous continuer?? [Y/n/?] y (Lecture de la base de donn?es... 124223 fichiers et r?pertoires d?j? install?s.) Suppression de libcurl4-openssl-dev ... Suppression de libcurl3 ... Suppression de libssh2-1-dev ... Suppression de libssh2-1 ... Traitement des actions diff?r?es (??triggers??) pour ??man-db??... S?lection du paquet libcurl4-gnutls-dev pr?c?demment d?s?lectionn?. (Lecture de la base de donn?es... 123739 fichiers et r?pertoires d?j? install?s.) D?paquetage de libcurl4-gnutls-dev (? partir de .../libcurl4-gnutls-dev_7.21.0-2.1+squeeze1_i386.deb) ... Traitement des actions diff?r?es (??triggers??) pour ??man-db??... Param?trage de libcurl4-gnutls-dev (7.21.0-2.1+squeeze1) ... jean-luc at ...57...:~$ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- sorry but the result of install package-dev is in french :-/: There is problem with cairo So i can understand that gb.cairo is disabled, but why the other components? Thanck you regards Jean-Luc -- View this message in context: http://old.nabble.com/gambas3-ans-debain-squeeze-tp33410649p33417552.html Sent from the gambas-user mailing list archive at Nabble.com. From vuott at ...325... Wed Feb 29 23:40:50 2012 From: vuott at ...325... (Ru Vuott) Date: Wed, 29 Feb 2012 22:40:50 +0000 (GMT) Subject: [Gambas-user] R: Process in TableVew and to Kill a Process In-Reply-To: <33417515.post@...1379...> Message-ID: <1330555250.56060.YahooMailClassic@...2748...> ' Gambas class file Private hpro As Process Public Sub Button1_Click() ' An application start, i.e. ? Gedit ? hpro = Exec ["gedit"] End Public Sub button2_Click() ' it closes application process hpro.kill End Public Sub hpro_Kill() ' this event is raised, when process is closed Print "Process closed !" End --- Mer 29/2/12, abbat ha scritto: > Da: abbat > Oggetto: [Gambas-user] Process in TableVew and to Kill a Process > A: gambas-user at lists.sourceforge.net > Data: Mercoled? 29 febbraio 2012, 23:28 > > Help me please. > > 1) How to situate processes in TableView or GridView by Name > and PID > columns? > 2) How to kill Process? > > > I cannot find any example of it and about Process.Kill. > > I tried: > > Dim p As Process = "tvtime" > p.Kill > ____ > > Process.Kill(9207) > _____ > > Process.Kill(tvtime) > > Its does not work. > > > > Thank you > > > > -- > View this message in context: http://old.nabble.com/Process-in-TableVew-and-to-Kill-a-Process-tp33417515p33417515.html > Sent from the gambas-user mailing list archive at > Nabble.com. > > > ------------------------------------------------------------------------------ > Virtualization & Cloud Management Using Capacity > Planning > Cloud computing makes use of virtualization - but cloud > computing > also focuses on allowing computing to be delivered as a > service. > http://www.accelacomm.com/jaw/sfnl/114/51521223/ > _______________________________________________ > Gambas-user mailing list > Gambas-user at lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > From vuott at ...325... Wed Feb 29 23:54:15 2012 From: vuott at ...325... (Ru Vuott) Date: Wed, 29 Feb 2012 22:54:15 +0000 (GMT) Subject: [Gambas-user] R: Process in TableVew and to Kill a Process - RECTIUS In-Reply-To: <1330555250.56060.YahooMailClassic@...2748...> Message-ID: <1330556055.21300.YahooMailClassic@...2691...> ' Gambas class file Private hpro As Process Public Sub Button1_Click() ' An application start, i.e. ? Gedit ? ? hpro = Exec ["gedit"] As "hpro" End Public Sub button2_Click() ' it closes application process ? hpro.kill End ' this event is raised, when process is closed: Public Sub hpro_Kill() ???Print "Process closed !" End