[Gambas-user] OpenSuse 11.3 + Gambas2.21 + MP3 playback
Hello everybody, I know that openSUSE violates the packaging convention, but did anybody managed to get the MP3 files play within a gambas2 application? I've installed libmikmod, as gambas2 could not find it after basic installation, and I know that there is no gambas2-gb-sdl-sound library for openSuse. Is there any workaround? Thanks! -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Gambas2.21 crashes upon MP3 playback
It happens when I use the provided example project of a music player, when I change the position of the slider. The same happens n my own project too. It is a bug. Signal #11 raised. -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Logical error in Gambas2.21
PUBLIC SUB MaxFind(tomb AS String[], minta AS String) AS Integer ' A function in Archs module that finds the highest index in the array tomb which contains minta DIM supst AS String[] DIM mfind AS Integer = -1 DIM cel AS Integer supst = NEW String[] supst = tomb WHILE supst.Find(minta) <> -1 cel = supst.Find(minta) mfind = cel IF cel >= 0 THEN supst[cel] = "~" ENDIF WEND supst.Clear RETURN mfind END -- 'This is the problematic part: when the Arch.MaxFind() returns -1 the block is executed and the program crashes, since an array could not have index -1. But it means for Gambas even if -1>-1 is FALSE the block is executed! IF Archs.MaxFind(temporal, telem) > -1 THEN j = Archs.MaxFind(temporal, telem) IF temporalpath[j] <> tut THEN temporal.Add(telem) temporalpath.Add(tut) ENDIF ENDIF -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Logical error in Gambas2.21
PUBLIC SUB MaxFind(tomb AS String[], minta AS String) AS Integer ' A function in Archs module that finds the highest index in the array tomb which contains minta DIM supst AS String[] DIM mfind AS Integer = -1 DIM cel AS Integer supst = NEW String[] supst = tomb WHILE supst.Find(minta) <> -1 cel = supst.Find(minta) mfind = cel IF cel >= 0 THEN supst[cel] = "~" ENDIF WEND supst.Clear RETURN mfind END -- 'This is the problematic part: when the Arch.MaxFind() returns -1 the block is executed and the program crashes, since an array could not have index -1. But it means for Gambas even if -1>-1 is FALSE the block is executed! IF Archs.MaxFind(temporal, telem) > -1 THEN j = Archs.MaxFind(temporal, telem) IF temporalpath[j] <> tut THEN temporal.Add(telem) temporalpath.Add(tut) ENDIF ENDIF -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Feature request: optional packages
I'd like to see an option during packaging to add external packages as dependencies. It could be done with or without version number (only package name). -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Feature request: optional packages
When will be the change to version 3.00? Will the 2.xx projects be compatible with it? -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Feature request: optional packages
Thanks! I hope there will be few changes with the existing code. 2010/9/27 Benoît Minisini > > When will be the change to version 3.00? > > I try to make a release candidate before the end of the year. > > > Will the 2.xx projects be > > compatible with it? > > No. You have to change things. But no so many. For example the > documentation > website is based on a CGI script written with the Gambas 3 IDE, and run by > the > 1.9.27 gambas interpreter! > > Regards, > > -- > Benoît Minisini > > > -- > Start uncovering the many advantages of virtual appliances > and start using them to simplify application deployment and > accelerate your shift to cloud computing. > http://p.sf.net/sfu/novell-sfdev2dev > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Is it possible to create .DEB packages from Fedora?
I'd like to move to Fedora, but I won't do it without knowing whether I'll be able to create gambas2 project packages for Debian based distributions. Is it solved in Fedora? Thanks! Csaba -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Is it possible to create .DEB packages from Fedora?
2010/9/30 Olivier Cruilles > hi, > > It's possible to install all necessary on Fedora to create .deb package > from Gambas2 IDE > but to check if the package have no problem on real Debian distribution it > better to test it after > on virtual machine or a reel computer installed with Debian system. > > > Le 29 sept. 2010 à 21:53, M. Cs. a écrit : > > > > > I'd like to move to Fedora, but I won't do it without knowing whether > I'll > > be able to create gambas2 project packages for Debian based > distributions. > > Is it solved in Fedora? > > > > Thanks! > > > > Csaba > > > -- > > Start uncovering the many advantages of virtual appliances > > and start using them to simplify application deployment and > > accelerate your shift to cloud computing. > > http://p.sf.net/sfu/novell-sfdev2dev > > ___ > > Gambas-user mailing list > > Gambas-user@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > Olivier Cruilles > Mail: linu...@club-internet.fr > > > > > -- > Start uncovering the many advantages of virtual appliances > and start using them to simplify application deployment and > accelerate your shift to cloud computing. > http://p.sf.net/sfu/novell-sfdev2dev > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > Could you just tell me how to do that? I mean, if you're already doing it on Fedora it's simple to give us all a short HowTo. It would help to Matteo too. Thank you very much! Csaba -- Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] gambas2-gb-sdl-sound in version 2.21 full with bugs
I know that everybody is fixed upon gambas3, but I'm desperately trying to say, that there are so many bugs in it. For example, it freezes the entire application upon MP3 playback if the bitrate is higher than 128 kbps which is the only accepted rate, since if the bitrate is lower, or the frequency is not 44.1 KHz the playback is funny and distorted. Is somebody maintaining this part of the project? Or if something is even more its "back-backend", is that part a dead project? Another bug: If you pause a song (MP3) and try to move the position of the song the application crashes with signal #11. I'd really appreciate if somebody would take this seriously. Thanks! -- Virtualization is moving to the mainstream and overtaking non-virtualized environment for deploying applications. Does it make network security easier or more difficult to achieve? Read this whitepaper to separate the two and get a better understanding. http://p.sf.net/sfu/hp-phase2-d2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Gambas app run as root
1. Open your project 2. Add a new module, let's say "Sudo" 3. Paste these lines in: ' Gambas class file PUBLIC wins AS Form PUBLIC black AS Button PUBLIC szoveg1 AS TextBox PUBLIC hProcess AS Process PUBLIC SUB ReadPassword() DIM black AS Button DIM labi, labi2 AS Label wins = NEW Form wins.Width = 200 wins.Height = 140 wins.Title = "Update: 'locate'" labi = NEW Label(wins) labi.X = 20 labi.Y = 10 labi.Width = 160 labi.Height = 25 labi.Text = "Enter the root password:" szoveg1 = NEW TextBox(wins) szoveg1.Width = 160 szoveg1.Height = 25 szoveg1.X = 20 szoveg1.Y = 40 szoveg1.Password = TRUE labi2 = NEW Label(wins) labi2.X = 20 labi2.Y = 70 labi2.Width = 160 labi2.Height = 25 labi2.Text = "Shell: su -c 'updatedb'" black = NEW Button(wins) black.Width = 100 black.Height = 25 black.X = 50 black.Y = 105 black.Text = "Update" Object.Attach(black, ME, "runty") wins.Center wins.Show() hProcess = SHELL "su -c 'updatedb'" FOR INPUT OUTPUT END PUBLIC SUB runty_Click() PRINT #hProcess, szoveg1.Text wins.Delete() END ' PUBLIC SUB Process_read() DIM sOutput AS String LINE INPUT #LAST, sOutput PRINT sOutput END 4. Customize the commands you want to execute 5. Call the module with reference Sudo.ReadPassword() from the main program. -- Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 & L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today. http://p.sf.net/sfu/beautyoftheweb ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Barcode reader
Is it possible to use Gambas2 (or 3) together with a barcode scanner under Linux. Is there any module available for that ? Thanks! Csaba -- Download new Adobe(R) Flash(R) Builder(TM) 4 The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly Flex(R) Builder(TM)) enable the development of rich applications that run across multiple browsers and platforms. Download your free trials today! http://p.sf.net/sfu/adobe-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Gambas2: Archlinux/Slackware packages on Ubuntu, how can I make them?
I think that the makepkg is not available outer the Archlinux itself. For the tar-1.13: 1. Obtain it from here: http://ftp.gnu.org/gnu/tar/ 2. Extract it to a folder 3. Open terminal in the extracted folder and type: ./configure 4. When finished: make 5. When finished: sudo make install 6. When finished: sudo mv /usr/local/bin/tar /usr/local/bin/tar-1.13 7. When finished: sudo ln -s /usr/local/bin/tar-1.13 /usr/bin/tar-1.13 -- Nokia and AT&T present the 2010 Calling All Innovators-North America contest Create new apps & games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Gambas2: Archlinux/Slackware packages on Ubuntu, how can I make them?
But it isn't written how to install it on Ubuntu. It looks like a description only. -- Nokia and AT&T present the 2010 Calling All Innovators-North America contest Create new apps & games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Requests for Gambas3
Dear Benoit and all, I'm writing this request as serious cry for your reconsideration and help. I was using Gambas2 on various distributions, and I'm trying to maintain the GamCat project, which is written in Gambas2, but it is harder and harder to do. First I've heard that openSuse is not following your concept of packaging the components, so they don't have gambas2-gb-sdl-sound component at all. Some times ago the component gambas2-gb-qt-kde has disappeared from Mandriva too. PCLinuxOS have only one package for gambas2 so it IS impossible to use projects written in G2 on various Linux distributions. In fact, only *buntu has full G2 support today, and this is a big regression. What I suggest is: - Have only two packages for the entire G3: one for the IDE component (for those not using G3 for development) and the rest of the components shipped in a single package. I have good reasons for that: gambas is not bigger than around 40MB. This is not a big size. I'd like to see gambas as a widely usable framework, not what is today. It would be so nice just to fire up the gambas3 package and have working applications written in it. Today I can't say gambas2 is very useful, because I can't force a user of e.g. GamCat to compile gambas2 from sources in order to have all the possible opions at hand. It is a real pain to package projects for different kind of Linuxes. It would be a pity for this great work to become a narrowing chunk. We cannot force packagers to obey the packaging rules of the many components, and the situation is really insane. Please consider it, for the project's sake. Thank you! Csaba -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book "Blueprint to a Billion" shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Requests for Gambas3
"An intermediate solution is the ability of making self-contained package, like Google does with Google Earth for example." But that isn't viable, since if I wanted to package an application on a system I need to have to have everything already installed in order to have the required libraries to be put into the target package, and that brings me back to the root of the problems: only *buntu has the background for that kind of work. -- The Next 800 Companies to Lead America's Growth: New Video Whitepaper David G. Thomson, author of the best-selling book "Blueprint to a Billion" shares his insights and actions to help propel your business during the next growth cycle. Listen Now! http://p.sf.net/sfu/SAP-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] No Data event with gb.gtk libraries
I'd like to move my project from KDE based stuff to GNOME. I have grid views, and I'm getting errors when I try to fill them with Data event. Why, which components would solve the problem? Thanks! (gambas 2.21) Csaba -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] No Data event with gb.gtk libraries
O.K: There's a big mess with the gb components among the different kinds of distributions. I was trying to find a good replacement solution for the KDE libraries, since at least a half of the platforms are lacking the gb-qt-kde component. My project can run without this library, but is ugly as hell without it. I've tried just simply to turn off gb.qt and gb.qt.ext and to turn in gb.gtk and gb.gtk.ext. But I've realized that in gtk versions there are no printing modules. Beside that, the gb.sdl component is unusable since it requires .gui or .gtk or .qt components, and at the same time are in conflict with the same. Please Benoit, make a global project cleanup! It's a hell of a mess. I'm currently on Mandriva 2010.1 but I found the same situation on Ubuntu too. Csaba -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] No Data event with gb.gtk libraries
> > And yes, I've tried to run my program with the same code as it worked > before: I have some search queries where the results are put into gridviewe. > With .gtk components the Data event returns an error finding no event data. Csaba > > -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] CDE. An interesting packaging tool
Although I'm not a gambas developer, I appreciate the idea. I would prefer to have all the must-haves packaged into single file, instead of fighting with unresolved package dependencies. It's better to have a myprogram.bin installer, than myprogram.rpm, myprogram.deb... Maybe Benoit would argue because of the package size. It's more like Windows. But who cares. If I'd be sure my program will run independently of the Linux platform flavor, I'd yes to size increment. Csaba -- Centralized Desktop Delivery: Dell and VMware Reference Architecture Simplifying enterprise desktop deployment and management using Dell EqualLogic storage and VMware View: A highly scalable, end-to-end client virtualization framework. Read more! http://p.sf.net/sfu/dell-eql-dev2dev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] How many is too many in GB3?
I've installed gambas3 from ubuntu's PPAs, and the first thing I've realized is that the number of allowed constants or code rows fell dramatically. I have a FMain of 11.000 rows written in gb2. Could you give me an esteem how much I have to modulize it to become acceptable for gb3? Thanks! -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] How many is too many in GB3?
2010/12/17 Fabien Bodard > 11000 rows in one class ... wh > > > Le 17 décembre 2010 13:12, Benoît Minisini > a écrit : > >> I've installed gambas3 from ubuntu's PPAs, and the first thing I've > >> realized is that the number of allowed constants or code rows fell > >> dramatically. I have a FMain of 11.000 rows written in gb2. Could you > give > >> me an esteem how much I have to modulize it to become acceptable for > gb3? > >> > >> Thanks! > > > > Actually the maximum number of constants didn't change. But Gambas 3 uses > more > > constants for form definitions. > > > > There is no limit on the number of lines. > > > > Otherwise I think I have a way to extend the maximum number of contants, > so be > > patient! > > > > Regards, > > > > -- > > Benoît Minisini > > > > > -- > > Lotusphere 2011 > > Register now for Lotusphere 2011 and learn how > > to connect the dots, take your collaborative environment > > to the next level, and enter the era of Social Business. > > http://p.sf.net/sfu/lotusphere-d2d > > ___ > > Gambas-user mailing list > > Gambas-user@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > > > -- > Fabien Bodard > > > -- > Lotusphere 2011 > Register now for Lotusphere 2011 and learn how > to connect the dots, take your collaborative environment > to the next level, and enter the era of Social Business. > http://p.sf.net/sfu/lotusphere-d2d > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > Yes, it is a complex program, with a lot of buttons, grids etc. I've already moved many of the parts into modules, still I have quite a lot of subroutines. I've transformed the gb2 into gb3. I'm preparing the porting to gb3, and I've encountered this situation. It's not a big problem for me to put some of the functions to modules, but after having moved around 500 lines I couldn't achieve to run the program. -- Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] gambas2 and gambas3 Natty
Hello, because of a foolish error I cannot use both gambas2 and gambas3 on Natty: gambas3-script_2.99.1-1natty0_i386.deb (--install): trying to overwrite '/usr/share/icons/hicolor/64x64/mimetypes/application-x-gambasscript.png', which is also in package gambas2-script 2.21.0-1ubuntu1 Because of a stupid icon! Is it possible to resolve it? -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] gambas2 and gambas3 Natty
Yes, I've installed these packages, and had to remove gambas2, although many of my apps are written in G2. G3 just looks more complicated, so I'll need some time for the change. Thanks for your work! Csaba 2011/6/25, Ian Haywood : > On Sat, Jun 25, 2011 at 5:29 AM, M. Cs. wrote: >> Hello, >> because of a foolish error I cannot use both gambas2 and gambas3 on Natty: >> >> gambas3-script_2.99.1-1natty0_i386.deb (--install): >> trying to overwrite >> '/usr/share/icons/hicolor/64x64/mimetypes/application-x-gambasscript.png', >> which is also in package gambas2-script 2.21.0-1ubuntu1 >> >> Because of a stupid icon! >> Is it possible to resolve it? > glad to know someone uses these packages.:-) > > The immediate solution is to use dpkg --force-overwrite overwriting > is OK it just means > your icon will be the new gambas3 icon even for gambas2 files. > > longer term I'm not sure. The gambas3 icon file can't go anywhere else > or have any other name > as it is a debian standard. > I'll research the options. > > Ian > > -- > All the data continuously generated in your IT infrastructure contains a > definitive record of customers, application performance, security > threats, fraudulent activity and more. Splunk takes this data and makes > sense of it. Business sense. IT sense. Common sense.. > http://p.sf.net/sfu/splunk-d2d-c1 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] I need simple example
Hi, I know how to print text in G2, but I'd need a simple transcription for the following G2 code to G3: PUBLIC SUB ExecutePrint(mytext) IF Printer.Setup() THEN RETURN Printer.Resolution = 300 Draw.Begin(Printer) Draw.Font.Size = 12 Draw.Text(mytext, 564, 457) Draw.End END The examples prepared for the GUI are much too complicated (were also in G2). "Simplicity!" (Hannibal Lecter) Thanks! -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] gambas2 and gambas3 Natty
Yes. I've just succeeded, Thanks! 2011/6/25, Ian Haywood : > On Sat, Jun 25, 2011 at 6:39 PM, M. Cs. wrote: >> Yes, I've installed these packages, and had to remove gambas2, >> although many of my apps are written in G2. G3 just looks more >> complicated, so I'll need some time for the change. >> Thanks for your work! > you should be able to install G2 and G3 together using the > --force-overwrite option, do you try this? > > Ian > > -- > All the data continuously generated in your IT infrastructure contains a > definitive record of customers, application performance, security > threats, fraudulent activity and more. Splunk takes this data and makes > sense of it. Business sense. IT sense. Common sense.. > http://p.sf.net/sfu/splunk-d2d-c1 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Array of PictureBoxes
I would like to have ability to create an array of PictureBoxes or Labels, so that I could add and remove them dinamically using some id or name. Something like path nodes in Gimp. Is it possible in Gambas? -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need simple example
Thanks! Csaba 2011/6/25, Fabien Bodard : > Dim hPrinter as Printer > > > Public sub _New() > > hPrinter = new Printer(me) as "Printer" > > if not Printer.configure() then >'you must to define the numbers of pages before >printer.count = 1 >'Launch the printing >printer.print > endif > > end > > > Public sub Printer_Draw() > > Paint.Font.Size=12 > Paint.Text(myText,564,457) > 'fill the vectorialpath > Paint.Fill > > end > > > > > 2011/6/25 M. Cs. : >> Hi, >> I know how to print text in G2, but I'd need a simple transcription >> for the following G2 code to G3: >> >> PUBLIC SUB ExecutePrint(mytext) >> >> IF Printer.Setup() THEN RETURN >> Printer.Resolution = 300 >> Draw.Begin(Printer) >> Draw.Font.Size = 12 >> Draw.Text(mytext, 564, 457) >> Draw.End >> >> END >> >> The examples prepared for the GUI are much too complicated (were also in >> G2). >> "Simplicity!" (Hannibal Lecter) >> >> Thanks! >> >> -- >> All the data continuously generated in your IT infrastructure contains a >> definitive record of customers, application performance, security >> threats, fraudulent activity and more. Splunk takes this data and makes >> sense of it. Business sense. IT sense. Common sense.. >> http://p.sf.net/sfu/splunk-d2d-c1 >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > > -- > Fabien Bodard > > -- > All the data continuously generated in your IT infrastructure contains a > definitive record of customers, application performance, security > threats, fraudulent activity and more. Splunk takes this data and makes > sense of it. Business sense. IT sense. Common sense.. > http://p.sf.net/sfu/splunk-d2d-c1 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need simple example
Well, I tried the example you gave me, but it is full of errors! I've modified like this: PUBLIC hPrinter as Printer Public sub _New() hPrinter = new Printer if not hPrinter.configure() then 'you must to define the numbers of pages before hPrinter.count = 1 'Launch the printing hPrinter.Print endif end Public sub hPrinter_Draw() Paint.Font.Size=12 Paint.Text(myText,564,457) 'fill the vectorialpath Paint.Fill end But it prints empty pages only! Any correction? 2011/6/25, M. Cs. : > Thanks! > > Csaba > > 2011/6/25, Fabien Bodard : >> Dim hPrinter as Printer >> >> >> Public sub _New() >> >> hPrinter = new Printer(me) as "Printer" >> >> if not Printer.configure() then >>'you must to define the numbers of pages before >>printer.count = 1 >>'Launch the printing >>printer.print >> endif >> >> end >> >> >> Public sub Printer_Draw() >> >> Paint.Font.Size=12 >> Paint.Text(myText,564,457) >> 'fill the vectorialpath >> Paint.Fill >> >> end >> >> >> >> >> 2011/6/25 M. Cs. : >>> Hi, >>> I know how to print text in G2, but I'd need a simple transcription >>> for the following G2 code to G3: >>> >>> PUBLIC SUB ExecutePrint(mytext) >>> >>> IF Printer.Setup() THEN RETURN >>> Printer.Resolution = 300 >>> Draw.Begin(Printer) >>> Draw.Font.Size = 12 >>> Draw.Text(mytext, 564, 457) >>> Draw.End >>> >>> END >>> >>> The examples prepared for the GUI are much too complicated (were also in >>> G2). >>> "Simplicity!" (Hannibal Lecter) >>> >>> Thanks! >>> >>> -- >>> All the data continuously generated in your IT infrastructure contains a >>> definitive record of customers, application performance, security >>> threats, fraudulent activity and more. Splunk takes this data and makes >>> sense of it. Business sense. IT sense. Common sense.. >>> http://p.sf.net/sfu/splunk-d2d-c1 >>> ___ >>> Gambas-user mailing list >>> Gambas-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> >> >> >> -- >> Fabien Bodard >> >> -- >> All the data continuously generated in your IT infrastructure contains a >> definitive record of customers, application performance, security >> threats, fraudulent activity and more. Splunk takes this data and makes >> sense of it. Business sense. IT sense. Common sense.. >> http://p.sf.net/sfu/splunk-d2d-c1 >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need simple example
It won't work... In your original script At line hPrinter = new Printer(me) as "Printer" it raises error too many parameters ...why should people change a synthax wich worked in G2... 2011/6/25, M. Cs. : > Well, I tried the example you gave me, but it is full of errors! > > I've modified like this: > > PUBLIC hPrinter as Printer > > > Public sub _New() > > hPrinter = new Printer > > if not hPrinter.configure() then >'you must to define the numbers of pages before >hPrinter.count = 1 >'Launch the printing >hPrinter.Print > endif > > end > > > Public sub hPrinter_Draw() > > Paint.Font.Size=12 > Paint.Text(myText,564,457) > 'fill the vectorialpath > Paint.Fill > > end > > But it prints empty pages only! > Any correction? > > 2011/6/25, M. Cs. : >> Thanks! >> >> Csaba >> >> 2011/6/25, Fabien Bodard : >>> Dim hPrinter as Printer >>> >>> >>> Public sub _New() >>> >>> hPrinter = new Printer(me) as "Printer" >>> >>> if not Printer.configure() then >>>'you must to define the numbers of pages before >>>printer.count = 1 >>>'Launch the printing >>>printer.print >>> endif >>> >>> end >>> >>> >>> Public sub Printer_Draw() >>> >>> Paint.Font.Size=12 >>> Paint.Text(myText,564,457) >>> 'fill the vectorialpath >>> Paint.Fill >>> >>> end >>> >>> >>> >>> >>> 2011/6/25 M. Cs. : >>>> Hi, >>>> I know how to print text in G2, but I'd need a simple transcription >>>> for the following G2 code to G3: >>>> >>>> PUBLIC SUB ExecutePrint(mytext) >>>> >>>> IF Printer.Setup() THEN RETURN >>>> Printer.Resolution = 300 >>>> Draw.Begin(Printer) >>>> Draw.Font.Size = 12 >>>> Draw.Text(mytext, 564, 457) >>>> Draw.End >>>> >>>> END >>>> >>>> The examples prepared for the GUI are much too complicated (were also >>>> in >>>> G2). >>>> "Simplicity!" (Hannibal Lecter) >>>> >>>> Thanks! >>>> >>>> -- >>>> All the data continuously generated in your IT infrastructure contains >>>> a >>>> definitive record of customers, application performance, security >>>> threats, fraudulent activity and more. Splunk takes this data and makes >>>> sense of it. Business sense. IT sense. Common sense.. >>>> http://p.sf.net/sfu/splunk-d2d-c1 >>>> ___ >>>> Gambas-user mailing list >>>> Gambas-user@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> >>> >>> >>> -- >>> Fabien Bodard >>> >>> -- >>> All the data continuously generated in your IT infrastructure contains a >>> definitive record of customers, application performance, security >>> threats, fraudulent activity and more. Splunk takes this data and makes >>> sense of it. Business sense. IT sense. Common sense.. >>> http://p.sf.net/sfu/splunk-d2d-c1 >>> ___ >>> Gambas-user mailing list >>> Gambas-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need simple example
If Not Printer.Configure() Then Another error Printer.Configure not static 2011/6/25, M. Cs. : > It won't work... > In your original script > At line hPrinter = new Printer(me) as "Printer" it raises error too > many parameters > > > ...why should people change a synthax wich worked in G2... > > 2011/6/25, M. Cs. : >> Well, I tried the example you gave me, but it is full of errors! >> >> I've modified like this: >> >> PUBLIC hPrinter as Printer >> >> >> Public sub _New() >> >> hPrinter = new Printer >> >> if not hPrinter.configure() then >>'you must to define the numbers of pages before >>hPrinter.count = 1 >>'Launch the printing >>hPrinter.Print >> endif >> >> end >> >> >> Public sub hPrinter_Draw() >> >> Paint.Font.Size=12 >> Paint.Text(myText,564,457) >> 'fill the vectorialpath >> Paint.Fill >> >> end >> >> But it prints empty pages only! >> Any correction? >> >> 2011/6/25, M. Cs. : >>> Thanks! >>> >>> Csaba >>> >>> 2011/6/25, Fabien Bodard : >>>> Dim hPrinter as Printer >>>> >>>> >>>> Public sub _New() >>>> >>>> hPrinter = new Printer(me) as "Printer" >>>> >>>> if not Printer.configure() then >>>>'you must to define the numbers of pages before >>>>printer.count = 1 >>>>'Launch the printing >>>>printer.print >>>> endif >>>> >>>> end >>>> >>>> >>>> Public sub Printer_Draw() >>>> >>>> Paint.Font.Size=12 >>>> Paint.Text(myText,564,457) >>>> 'fill the vectorialpath >>>> Paint.Fill >>>> >>>> end >>>> >>>> >>>> >>>> >>>> 2011/6/25 M. Cs. : >>>>> Hi, >>>>> I know how to print text in G2, but I'd need a simple transcription >>>>> for the following G2 code to G3: >>>>> >>>>> PUBLIC SUB ExecutePrint(mytext) >>>>> >>>>> IF Printer.Setup() THEN RETURN >>>>> Printer.Resolution = 300 >>>>> Draw.Begin(Printer) >>>>> Draw.Font.Size = 12 >>>>> Draw.Text(mytext, 564, 457) >>>>> Draw.End >>>>> >>>>> END >>>>> >>>>> The examples prepared for the GUI are much too complicated (were also >>>>> in >>>>> G2). >>>>> "Simplicity!" (Hannibal Lecter) >>>>> >>>>> Thanks! >>>>> >>>>> -- >>>>> All the data continuously generated in your IT infrastructure contains >>>>> a >>>>> definitive record of customers, application performance, security >>>>> threats, fraudulent activity and more. Splunk takes this data and >>>>> makes >>>>> sense of it. Business sense. IT sense. Common sense.. >>>>> http://p.sf.net/sfu/splunk-d2d-c1 >>>>> ___ >>>>> Gambas-user mailing list >>>>> Gambas-user@lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>> >>>> >>>> >>>> >>>> -- >>>> Fabien Bodard >>>> >>>> -- >>>> All the data continuously generated in your IT infrastructure contains >>>> a >>>> definitive record of customers, application performance, security >>>> threats, fraudulent activity and more. Splunk takes this data and makes >>>> sense of it. Business sense. IT sense. Common sense.. >>>> http://p.sf.net/sfu/splunk-d2d-c1 >>>> ___ >>>> Gambas-user mailing list >>>> Gambas-user@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> >> > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need simple example
Public Sub _new() Dim hPrinter As Printer hPrinter = New Printer If Not hPrinter.Configure() Then 'you must to define the numbers of pages before hPrinter.Count = 1 'Launch the printing hPrinter.Print Endif End Public Sub Form_Open() End Public Sub hPrinter_Draw() Paint.Font.Size = 12 Paint.Text("Nothing", 564, 457) 'fill the vectorialpath Paint.Fill End It prints empty pages only!!! 2011/6/25, M. Cs. : > If Not Printer.Configure() Then > > Another error Printer.Configure not static > > 2011/6/25, M. Cs. : >> It won't work... >> In your original script >> At line hPrinter = new Printer(me) as "Printer" it raises error too >> many parameters >> >> >> ...why should people change a synthax wich worked in G2... >> >> 2011/6/25, M. Cs. : >>> Well, I tried the example you gave me, but it is full of errors! >>> >>> I've modified like this: >>> >>> PUBLIC hPrinter as Printer >>> >>> >>> Public sub _New() >>> >>> hPrinter = new Printer >>> >>> if not hPrinter.configure() then >>>'you must to define the numbers of pages before >>>hPrinter.count = 1 >>>'Launch the printing >>>hPrinter.Print >>> endif >>> >>> end >>> >>> >>> Public sub hPrinter_Draw() >>> >>> Paint.Font.Size=12 >>> Paint.Text(myText,564,457) >>> 'fill the vectorialpath >>> Paint.Fill >>> >>> end >>> >>> But it prints empty pages only! >>> Any correction? >>> >>> 2011/6/25, M. Cs. : >>>> Thanks! >>>> >>>> Csaba >>>> >>>> 2011/6/25, Fabien Bodard : >>>>> Dim hPrinter as Printer >>>>> >>>>> >>>>> Public sub _New() >>>>> >>>>> hPrinter = new Printer(me) as "Printer" >>>>> >>>>> if not Printer.configure() then >>>>>'you must to define the numbers of pages before >>>>>printer.count = 1 >>>>>'Launch the printing >>>>>printer.print >>>>> endif >>>>> >>>>> end >>>>> >>>>> >>>>> Public sub Printer_Draw() >>>>> >>>>> Paint.Font.Size=12 >>>>> Paint.Text(myText,564,457) >>>>> 'fill the vectorialpath >>>>> Paint.Fill >>>>> >>>>> end >>>>> >>>>> >>>>> >>>>> >>>>> 2011/6/25 M. Cs. : >>>>>> Hi, >>>>>> I know how to print text in G2, but I'd need a simple transcription >>>>>> for the following G2 code to G3: >>>>>> >>>>>> PUBLIC SUB ExecutePrint(mytext) >>>>>> >>>>>> IF Printer.Setup() THEN RETURN >>>>>> Printer.Resolution = 300 >>>>>> Draw.Begin(Printer) >>>>>> Draw.Font.Size = 12 >>>>>> Draw.Text(mytext, 564, 457) >>>>>> Draw.End >>>>>> >>>>>> END >>>>>> >>>>>> The examples prepared for the GUI are much too complicated (were also >>>>>> in >>>>>> G2). >>>>>> "Simplicity!" (Hannibal Lecter) >>>>>> >>>>>> Thanks! >>>>>> >>>>>> -- >>>>>> All the data continuously generated in your IT infrastructure >>>>>> contains >>>>>> a >>>>>> definitive record of customers, application performance, security >>>>>> threats, fraudulent activity and more. Splunk takes this data and >>>>>> makes >>>>>> sense of it. Business sense. IT sense. Common sense.. >>>>>> http://p.sf.net/sfu/splunk-d2d-c1 >>>>>> ___ >>>>>> Gambas-user mailing list >>>>>> Gambas-user@lists.sourceforge.net >>>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> Fabien Bodard >>>>> >>>>> -- >>>>> All the data continuously generated in your IT infrastructure contains >>>>> a >>>>> definitive record of customers, application performance, security >>>>> threats, fraudulent activity and more. Splunk takes this data and >>>>> makes >>>>> sense of it. Business sense. IT sense. Common sense.. >>>>> http://p.sf.net/sfu/splunk-d2d-c1 >>>>> ___ >>>>> Gambas-user mailing list >>>>> Gambas-user@lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>> >>>> >>> >> > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense.. http://p.sf.net/sfu/splunk-d2d-c1 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] ScrollView properties
How can get the the minimum and maximum value of scrolling position of a ScrollView? The task I'd like to solve is to open a picture which is put into a PictureBox inside a ScrollView. My problem is how to get the right X and Y coordinates under the mouse pointer, but related to the (0,0) coordinates of the picture. So I need to determine the mouse position over the picture, not the screen or scrollview .The PictureBox is dimensioned according to the width and height of the picture I open, so there are no scaling, but working with the original picture size. I was trying to solve this with proportions in scrolling minimum and maximum value, but I cannot access to the min and max value of the scrollbar position of the view. Any ideas? -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] ScrollView properties
Thanks! It works. 2011/6/26, tobias : > hi, > > to be more exact. you should use: > PRINT Mouse.ScreenX - PictureBox1.ScreenX > this will give the position of the mouse relative to PictureBox1's 0,0 > which is the same as your pictures 0,0 > > regards, > tobi > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Create and delete labels dinamically
I know how to create a label object with the myLabel=New Label(Fmain) sentence. But how could I create an array of labels in order to be able to remove them if needed? -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Create and delete labels dinamically
Thanks! I wonder whether it is possible with any kind of controls to do the same thing? 2011/6/27, Caveat : > > Private allLabels as TextLabel[] > > Public Sub Test_Click() > > allLabels = New TextLabel[10] > createLabels() > deleteLabels() > tidyLabels() > > End > > Public Sub createLabels() > > Dim idx As Integer > > For idx = 0 To 9 > allLabels[idx] = New TextLabel(Me) > allLabels[idx].X = 10 > allLabels[idx].Y = 10 + (idx * 22) > allLabels[idx].Width = 450 > allLabels[idx].Height = 20 > allLabels[idx].Tag = idx > allLabels[idx].Text = "I am label " & idx > Next > > End > > Public Sub deleteLabels() > > allLabels[3].Delete > allLabels[8].Delete > > End > > Public Sub tidyLabels() > > Dim aLabel As TextLabel > Dim idx, idy As Integer > For idx = 0 To allLabels.length - 1 > If Object.IsValid(allLabels[idx]) Then > allLabels[idx].Y = 10 + (idy * 22) > Inc idy > End If > Next > > End > > Regards, > Caveat > > On Mon, 2011-06-27 at 11:41 +0200, M. Cs. wrote: >> I know how to create a label object with the >> myLabel=New Label(Fmain) sentence. But how could I create an array of >> labels in order to be able to remove them if needed? >> >> -- >> All of the data generated in your IT infrastructure is seriously valuable. >> Why? It contains a definitive record of application performance, security >> threats, fraudulent activity, and more. Splunk takes this data and makes >> sense of it. IT sense. And common sense. >> http://p.sf.net/sfu/splunk-d2d-c2 >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Create and delete labels dinamically
And the other remark is this is only a static solution: I need to declare the dimension of array, which is a handicap. 2011/6/27, M. Cs. : > Thanks! I wonder whether it is possible with any kind of controls to > do the same thing? > > 2011/6/27, Caveat : >> >> Private allLabels as TextLabel[] >> >> Public Sub Test_Click() >> >> allLabels = New TextLabel[10] >> createLabels() >> deleteLabels() >> tidyLabels() >> >> End >> >> Public Sub createLabels() >> >> Dim idx As Integer >> >> For idx = 0 To 9 >> allLabels[idx] = New TextLabel(Me) >> allLabels[idx].X = 10 >> allLabels[idx].Y = 10 + (idx * 22) >> allLabels[idx].Width = 450 >> allLabels[idx].Height = 20 >> allLabels[idx].Tag = idx >> allLabels[idx].Text = "I am label " & idx >> Next >> >> End >> >> Public Sub deleteLabels() >> >> allLabels[3].Delete >> allLabels[8].Delete >> >> End >> >> Public Sub tidyLabels() >> >> Dim aLabel As TextLabel >> Dim idx, idy As Integer >> For idx = 0 To allLabels.length - 1 >> If Object.IsValid(allLabels[idx]) Then >> allLabels[idx].Y = 10 + (idy * 22) >> Inc idy >> End If >> Next >> >> End >> >> Regards, >> Caveat >> >> On Mon, 2011-06-27 at 11:41 +0200, M. Cs. wrote: >>> I know how to create a label object with the >>> myLabel=New Label(Fmain) sentence. But how could I create an array of >>> labels in order to be able to remove them if needed? >>> >>> -- >>> All of the data generated in your IT infrastructure is seriously >>> valuable. >>> Why? It contains a definitive record of application performance, >>> security >>> threats, fraudulent activity, and more. Splunk takes this data and makes >>> sense of it. IT sense. And common sense. >>> http://p.sf.net/sfu/splunk-d2d-c2 >>> ___ >>> Gambas-user mailing list >>> Gambas-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> >> >> -- >> All of the data generated in your IT infrastructure is seriously >> valuable. >> Why? It contains a definitive record of application performance, security >> threats, fraudulent activity, and more. Splunk takes this data and makes >> sense of it. IT sense. And common sense. >> http://p.sf.net/sfu/splunk-d2d-c2 >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Menu over a control
How can í create a flying menu over a dinamically created control? I know how can I do it for static elements, but if I have an array of let say TextLabels, how can I attach a menu to each of the elements (in order to get and use X and Y coordinates of the controls) ? Is It possible to use Object.Attach(Me,container,"ArrayClick("&i&")")? I know it's a bit Javascriptish, but I don't know how to use one suboutine for multiple elements. It would be silly to have 100 predefined TextLabels and 100 subs PUBLIC SUB TextLabel[1]_Click() Action_Activate("mymenu") END PUBLIC SUB TextLabel[2]_Click() Action_Activate("mymenu") END ... I don't see how can Gambas manage this dinamic contents. -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Menu over a control
Merci Fabien! 2011/6/28, Fabien Bodard : > Public sub _New() dim i as integer > > dim hTextLabel as TextLabel > > For i = 0 to 100 > hTextLabel = new TextLabel(Me) as "MyText" > hTextLabel.Tag = i > next > end > > Public Sub MyText_Click() > > select case Last.Tag > Case 1 >'Text1 > Case 2 >'Text2 > 'etc > end > end > > > > 2011/6/28 M. Cs. : >> How can í create a flying menu over a dinamically created control? >> I know how can I do it for static elements, but if I have an array of >> let say TextLabels, how can I attach a menu to each of the elements >> (in order to get and use X and Y coordinates of the controls) ? >> >> Is It possible to use Object.Attach(Me,container,"ArrayClick("&i&")")? >> I know it's a bit Javascriptish, but I don't know how to use one >> suboutine for multiple elements. >> >> It would be silly to have 100 predefined TextLabels and 100 subs >> >> PUBLIC SUB TextLabel[1]_Click() >> Action_Activate("mymenu") >> END >> >> PUBLIC SUB TextLabel[2]_Click() >> Action_Activate("mymenu") >> END >> ... >> >> >> I don't see how can Gambas manage this dinamic contents. >> >> -- >> All of the data generated in your IT infrastructure is seriously valuable. >> Why? It contains a definitive record of application performance, security >> threats, fraudulent activity, and more. Splunk takes this data and makes >> sense of it. IT sense. And common sense. >> http://p.sf.net/sfu/splunk-d2d-c2 >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > > -- > Fabien Bodard > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Menu over a control
Still I have a problem: If I create TextLabels as you told me, I can get their tags, so I can identify them, but cannot remove them. In other case if I create them as a TextLabel[], I can add and remove them, but cannot figure which one of them has been clicked. How to make both of the option usable? 2011/6/28, M. Cs. : > Merci Fabien! > > 2011/6/28, Fabien Bodard : >> Public sub _New() dim i as integer >> >> dim hTextLabel as TextLabel >> >> For i = 0 to 100 >> hTextLabel = new TextLabel(Me) as "MyText" >> hTextLabel.Tag = i >> next >> end >> >> Public Sub MyText_Click() >> >> select case Last.Tag >> Case 1 >>'Text1 >> Case 2 >>'Text2 >> 'etc >> end >> end >> >> >> >> 2011/6/28 M. Cs. : >>> How can í create a flying menu over a dinamically created control? >>> I know how can I do it for static elements, but if I have an array of >>> let say TextLabels, how can I attach a menu to each of the elements >>> (in order to get and use X and Y coordinates of the controls) ? >>> >>> Is It possible to use Object.Attach(Me,container,"ArrayClick("&i&")")? >>> I know it's a bit Javascriptish, but I don't know how to use one >>> suboutine for multiple elements. >>> >>> It would be silly to have 100 predefined TextLabels and 100 subs >>> >>> PUBLIC SUB TextLabel[1]_Click() >>> Action_Activate("mymenu") >>> END >>> >>> PUBLIC SUB TextLabel[2]_Click() >>> Action_Activate("mymenu") >>> END >>> ... >>> >>> >>> I don't see how can Gambas manage this dinamic contents. >>> >>> -- >>> All of the data generated in your IT infrastructure is seriously >>> valuable. >>> Why? It contains a definitive record of application performance, >>> security >>> threats, fraudulent activity, and more. Splunk takes this data and makes >>> sense of it. IT sense. And common sense. >>> http://p.sf.net/sfu/splunk-d2d-c2 >>> ___ >>> Gambas-user mailing list >>> Gambas-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> >> >> >> -- >> Fabien Bodard >> >> -- >> All of the data generated in your IT infrastructure is seriously >> valuable. >> Why? It contains a definitive record of application performance, security >> threats, fraudulent activity, and more. Splunk takes this data and makes >> sense of it. IT sense. And common sense. >> http://p.sf.net/sfu/splunk-d2d-c2 >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Menu over a control
Thaa,...I've managed to solve this problem, but ran into another: Menus. Once I had simply to create menu with: mymenu=New Menu(FMain) mysub1=New Menu(mymenu) mysub1.Text="Item1" mysub1.Action="Action1" mymenu.popup() And it worked like a charm. Now in G3 it says after the popup there's no return value(???) Really G3 is a new language! 2011/6/29, M. Cs. : > Still I have a problem: > > If I create TextLabels as you told me, I can get their tags, so I can > identify them, but cannot remove them. In other case if I create them > as a TextLabel[], I can add and remove them, but cannot figure which > one of them has been clicked. How to make both of the option usable? > > 2011/6/28, M. Cs. : >> Merci Fabien! >> >> 2011/6/28, Fabien Bodard : >>> Public sub _New() dim i as integer >>> >>> dim hTextLabel as TextLabel >>> >>> For i = 0 to 100 >>> hTextLabel = new TextLabel(Me) as "MyText" >>> hTextLabel.Tag = i >>> next >>> end >>> >>> Public Sub MyText_Click() >>> >>> select case Last.Tag >>> Case 1 >>>'Text1 >>> Case 2 >>>'Text2 >>> 'etc >>> end >>> end >>> >>> >>> >>> 2011/6/28 M. Cs. : >>>> How can í create a flying menu over a dinamically created control? >>>> I know how can I do it for static elements, but if I have an array of >>>> let say TextLabels, how can I attach a menu to each of the elements >>>> (in order to get and use X and Y coordinates of the controls) ? >>>> >>>> Is It possible to use Object.Attach(Me,container,"ArrayClick("&i&")")? >>>> I know it's a bit Javascriptish, but I don't know how to use one >>>> suboutine for multiple elements. >>>> >>>> It would be silly to have 100 predefined TextLabels and 100 subs >>>> >>>> PUBLIC SUB TextLabel[1]_Click() >>>> Action_Activate("mymenu") >>>> END >>>> >>>> PUBLIC SUB TextLabel[2]_Click() >>>> Action_Activate("mymenu") >>>> END >>>> ... >>>> >>>> >>>> I don't see how can Gambas manage this dinamic contents. >>>> >>>> -- >>>> All of the data generated in your IT infrastructure is seriously >>>> valuable. >>>> Why? It contains a definitive record of application performance, >>>> security >>>> threats, fraudulent activity, and more. Splunk takes this data and >>>> makes >>>> sense of it. IT sense. And common sense. >>>> http://p.sf.net/sfu/splunk-d2d-c2 >>>> ___ >>>> Gambas-user mailing list >>>> Gambas-user@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> >>> >>> >>> -- >>> Fabien Bodard >>> >>> -- >>> All of the data generated in your IT infrastructure is seriously >>> valuable. >>> Why? It contains a definitive record of application performance, >>> security >>> threats, fraudulent activity, and more. Splunk takes this data and makes >>> sense of it. IT sense. And common sense. >>> http://p.sf.net/sfu/splunk-d2d-c2 >>> ___ >>> Gambas-user mailing list >>> Gambas-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>> >> > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Menu over a control
Can you give me a menu example for Gambas3, since the Gambas2 way of doing it doesn't work? Thanks 2011/6/29, Rolf-Werner Eilert : > Yes, that would be a problem, but there is LAST to handle this: > > LAST.Tag would give you the tag of the object which was clicked last. > You will identify the correct type of object by its name of origin "MyText". > > Now you can insert > > Public SUB MyText_Click() > > When you type LAST. you will get the list of options here and can be > sure to react to the right object as it is defined by "MyText". > > Rolf > > > Am 29.06.2011 09:20, schrieb M. Cs.: >> Still I have a problem: >> >> If I create TextLabels as you told me, I can get their tags, so I can >> identify them, but cannot remove them. In other case if I create them >> as a TextLabel[], I can add and remove them, but cannot figure which >> one of them has been clicked. How to make both of the option usable? >> >> 2011/6/28, M. Cs.: >>> Merci Fabien! >>> >>> 2011/6/28, Fabien Bodard: >>>> Public sub _New() dim i as integer >>>> >>>> dim hTextLabel as TextLabel >>>> >>>> For i = 0 to 100 >>>>hTextLabel = new TextLabel(Me) as "MyText" >>>>hTextLabel.Tag = i >>>> next >>>> end >>>> >>>> Public Sub MyText_Click() >>>> >>>>select case Last.Tag >>>> Case 1 >>>> 'Text1 >>>> Case 2 >>>> 'Text2 >>>> 'etc >>>>end >>>> end >>>> >>>> >>>> >>>> 2011/6/28 M. Cs.: >>>>> How can í create a flying menu over a dinamically created control? >>>>> I know how can I do it for static elements, but if I have an array of >>>>> let say TextLabels, how can I attach a menu to each of the elements >>>>> (in order to get and use X and Y coordinates of the controls) ? >>>>> >>>>> Is It possible to use Object.Attach(Me,container,"ArrayClick("&i&")")? >>>>> I know it's a bit Javascriptish, but I don't know how to use one >>>>> suboutine for multiple elements. >>>>> >>>>> It would be silly to have 100 predefined TextLabels and 100 subs >>>>> >>>>> PUBLIC SUB TextLabel[1]_Click() >>>>> Action_Activate("mymenu") >>>>> END >>>>> >>>>> PUBLIC SUB TextLabel[2]_Click() >>>>> Action_Activate("mymenu") >>>>> END >>>>> ... >>>>> >>>>> >>>>> I don't see how can Gambas manage this dinamic contents. >>>>> >>>>> -- >>>>> All of the data generated in your IT infrastructure is seriously >>>>> valuable. >>>>> Why? It contains a definitive record of application performance, >>>>> security >>>>> threats, fraudulent activity, and more. Splunk takes this data and >>>>> makes >>>>> sense of it. IT sense. And common sense. >>>>> http://p.sf.net/sfu/splunk-d2d-c2 >>>>> ___ >>>>> Gambas-user mailing list >>>>> Gambas-user@lists.sourceforge.net >>>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>>> >>>> >>>> >>>> >>>> -- >>>> Fabien Bodard >>>> >>>> -- >>>> All of the data generated in your IT infrastructure is seriously >>>> valuable. >>>> Why? It contains a definitive record of application performance, >>>> security >>>> threats, fraudulent activity, and more. Splunk takes this data and makes >>>> sense of it. IT sense. And common sense. >>>> http://p.sf.net/sfu/splunk-d2d-c2 >>>> ___ >>>> Gambas-user mailing list >>>> Gambas-user@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> >> >> -- >> All of the data generated in your IT infrastructure is se
Re: [Gambas-user] Menu over a control
OK. I found that I have to put PUBLIC SUB Action_Activate(key as string) AS Boolean in order to get dinamical menus to work. The As Boolean wasn't present in G2. 2011/6/29, tobias : > hi, > > i just installed kubuntu 11.04 yesterday, i couldn't compile gambas3 > with my old ubuntu... > i hope, i can figure it out at home, if your questions isn't answered > then :) > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] External library variable
"I really don't care about the syntax." But I do! I'm really appreciated with the work of the Gambas team, but I'd like to express that the synthax is a quite important thing: 1. Compatibility with G2 projects 2. Time, a lot of times to spend hunting to find the changes, and the solutions for the methods you've used just like that in G2 and now in G3 not. A simple example: in G2 there was enough to write a function in order to have things printed out, now in G3 there are at least 2-3 subroutines for the same task. IMHO this isn't as good a strategy. I don't care what lies behind the synthax, but it's not really efficient thing to learn the language over and over. Once again, Gambas is GREAT, but it would be better to leave the synthax unchanged. Csaba 2011/6/29, Gary D Walborn : > Benoit, > >You come through again! I really don't care about the syntax. I'm vary > pleased that there is a mechanism to do this. I was afraid I'd have to > write a wrapper to duplicate the original library calls and add accessor > function for the variables. If the system call works, it will save me a ton > of work! Thank you SO MUCH for all your help. > > -- > Gary D. Walborn > gwalb...@gmail.com > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Dinamic lines
Hi, I need a clear explanation how does the printing in G3 works. All I want is to have a button clicked and afterwards a grid of changeable number of lines to be drawn over a picture, like some kind of guides implemented in Inkscape. I know in G3 there are some events during the printing regardless to the destination of the printing: Begin, Draw and End. The problem with included examples are that they are done with built-in components of printer, DrawArea etc. So I cannot discover how to do the things. There would be few bricks to discover which are badly missed in examples: How to draw a line How to draw a text How to do it on a printer How to do it on a canvas How to make lines removable I don't need complex projects with proportions, resizing etc., since I can do it alone. I need the synthax. I'm sorry, I'm a teacher, so take this as a complaint of a teacher who's thinking with the head of a student: the examples are difficult to analize. Thanks Csaba -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Dinamic lines
Let me give a detailed explanation: In example Chart there are two forms. The first one is for collecting the chart data, so it isn't very interesting. I'll list you the second class, which is reponsible for the chart-drawing: Public total As Integer Public value As Float[] Public Sub btnClose_Click() Me.Close End Public Sub _new() Me.Center End Public Sub Form_Open() Draw_Chart End Public Sub Draw_Chart() Dim i As Integer Dim skala_1 As Integer Dim skala_2 As Integer Dim distance_x As Float Dim distance_y As Float Dim width_draw As Integer Dim tot As Integer Dim colors As Integer[] Dim bottom As Integer Dim sumdata As Integer colors = New Integer[] colors.Resize(total + 1) For i = 1 To total sumdata = sumdata + value[i] Next If sumdata = 0 Then sumdata = 1 For i = 1 To total value[i] = (value[i] / sumdata) * 10 Next drwchart.Clear draw.Begin(drwchart) skala_1 = drwchart.ClientH / 11 distance_y = drwchart.ClientH - skala_1 bottom = distance_y + 8 For i = 0 To 100 Step 10 draw.Foreground = color.black draw.Text(i, 0, distance_y) draw.Line(25, distance_y + 8, drwchart.clientw, distance_y + 8) distance_y = distance_y - skala_1 Next draw.Line(30, 0, 30, drwchart.ClientH) skala_2 = (drwchart.ClientW - 30) \ 10 distance_x = skala_2 + 30 width_draw = skala_2 / 2 For i = 1 To Total draw.LineWidth = 1 draw.Foreground = color.Black draw.Text(i, distance_x - (width_draw / 2) - 4, drwchart.ClientH - 20) draw.Line(distance_x - (width_draw / 2), 0, distance_x - (width_draw / 2), drwchart.ClientH - skala_1 + 8) draw.LineWidth = width_draw draw.Foreground = color.RGB(i * 100, i * 10, i * 50) colors[i] = draw.Foreground tot = skala_1 * value[i] + skala_1 - 8 draw.Line(distance_x - (width_draw / 2), bottom, distance_x - (width_draw / 2), drwchart.ClientH - tot) distance_x = distance_x + skala_2 Next DRAW.End End Public Sub btnAbout_Click() Dim i As String i = "Example to make bar chart\n" i = i & "This example has made by : " & Chr(10) i = i & " Yudi Astira" & Chr(10) i = i & " y...@kecoak.or.id" & Chr(10) i = i & " necrose #hdteam on Dal.Net" & Chr(10) i = i & "Thank You" message.Info(i, "&Close") End --- If you take a look to the structure of this, the first thing is that only the Draw_Chart() is interesting. If I would like to emphasize the real important things I'd shorten it to this: Public Sub Draw_Chart() drwchart.Clear draw.Begin(drwchart) draw.LineWidth = 1 draw.Foreground = color.Black draw.Line(30, 0, 30, drwchart.ClientH) draw.End End The other things can be done if you know the basic synthax. And here comes the first irregularity: if I try to implement these steps in a program where I'm creating new DrawingArea if I put the creation of this into the same function as the Begin method, I run into error "Drawing cannot be done outside the Draw event handler". But actually it works in this example! And this is the only available example for chart-drawing, and it isn't written in the spirit of the documents! I simply don't know how to write a working function for that task. A good example is made of usable, simple bricks: if I know how to draw a line, I'll know how to draw a circle, rectangle etc. too. So what's the structure of the printing process? If I define a printer: Public samsung AS Printer How to force it to print a line, a text or an image? At least in the documentation it should be clearly stated. Should I write a sub: PUBLIC SUB Printit() ??? what to put here, can I do it in one function??? END Or I will need: 1. PUBLIC SUB Printit() 2. PUBLIC SUB samsung_Begin() 3. PUBLIC SUB samsung_Draw() What is defined in 1,2 and 3 function? And the same stands for the DrawingArea task too. I don't know how to initiate the process! One task for 3 functions?! I hope I was clear. > Did you read the Printing example source code? Did you find it too complex? > > -- > Benoît Minisini > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT se
[Gambas-user] Modules not recognized
I've created a module called Paper, and a PUBLIC SUB DoPrint() on it, and when I try to invoke the module with PUBLIC SUB myButton_Click() Paper.DoPrint END from FMain, I'm getting error "Unknown identifier Paper on FMain..." Men, is this still Gambas??? This was the standard way of handling the modules in G2. :-( What's wrong? -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Modules not recognized
Hmmm, I see the examples have no modules. Does it mean that in G3 the modules are not working yet? 2011/6/30, M. Cs. : > I've created a module called Paper, and a PUBLIC SUB DoPrint() on it, > and when I try to invoke the module with > > PUBLIC SUB myButton_Click() > Paper.DoPrint > END > > from FMain, I'm getting error "Unknown identifier Paper on FMain..." > > Men, is this still Gambas??? This was the standard way of handling the > modules in G2. :-( > > What's wrong? > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Modules not recognized
O.K. I've discovered that the modules should be added to the sources branch of the project! 2011/6/30, M. Cs. : > Hmmm, I see the examples have no modules. Does it mean that in G3 the > modules are not working yet? > > > 2011/6/30, M. Cs. : >> I've created a module called Paper, and a PUBLIC SUB DoPrint() on it, >> and when I try to invoke the module with >> >> PUBLIC SUB myButton_Click() >> Paper.DoPrint >> END >> >> from FMain, I'm getting error "Unknown identifier Paper on FMain..." >> >> Men, is this still Gambas??? This was the standard way of handling the >> modules in G2. :-( >> >> What's wrong? >> > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Please help me!
Public samsung As Printer Public Sub PrintID() samsung = New Printer If samsung.Configure() Then Return samsung.Count = 1 samsung.Print End Public Sub samsung_Begin() End Public Sub samsung_Draw() Dim i As Integer Dim tagok As String[] tagok = Split(datae[curr], ";")' gets data from a csv sheet For i = 0 To tagok.Count - 1 Paint.Font = Font["Lucida Sans"] Paint.Font.Size = lett[i]'array of font sizes Paint.Color = Color.Black Paint.DrawText(tagok[i], CFloat(xcor[i]), CFloat(ycor[i])) Next End Still it prints blank pages. -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Please help me!
Yes, Benoit, still even if change the synthax to: Public Sub PrintID() Dim i As Integer Dim tagok As String[] samsung = New Printer As "samsung" If samsung.Configure() Then Return samsung.Count = 1 samsung.Print End Public Sub samsung_Begin() End Public Sub samsung_Draw() Dim i As Integer Dim tagok As String[] tagok = Split(datae[curr], ";") For i = 0 To tagok.Count - 1 Paint.Font = Font["Lucida Sans"] Paint.Font.Size = lett[i] Paint.DrawText(tagok[i], CFloat(xcor[i]), CFloat(ycor[i])) Next End It prints blank pages only, while the Printer example works O.K. I don't understand this at all. I'm wrestling with this since 3 days. 2011/6/30, Benoît Minisini : >> Public samsung As Printer >> >> Public Sub PrintID() >> samsung = New Printer > > --> samsung = New Printer As "samsung" > > In Gambas, if you don't specify an event name, you don't get events. > > Regards, > > -- > Benoît Minisini > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Please help me!
O.K. The printing started now, but it prints the texts one over another regardless to the coordinates given by CFloat(xcor[i]) and CFloat(ycor[i]). Why? 2011/6/30, Fabien Bodard : > Le 30 juin 2011 14:00, Benoît Minisini a > écrit : >>> Yes, Benoit, >>> still even if change the synthax to: >>> >>> Public Sub PrintID() >>> Dim i As Integer >>> Dim tagok As String[] >>> samsung = New Printer As "samsung" >>> If samsung.Configure() Then Return >>> samsung.Count = 1 >>> samsung.Print >>> >>> End >>> >>> Public Sub samsung_Begin() >>> >>> End >>> >>> Public Sub samsung_Draw() >>> Dim i As Integer >>> Dim tagok As String[] >>> tagok = Split(datae[curr], ";") >>> For i = 0 To tagok.Count - 1 >>> Paint.Font = Font["Lucida Sans"] >>> Paint.Font.Size = lett[i] >>> Paint.DrawText(tagok[i], CFloat(xcor[i]), CFloat(ycor[i])) > > 'hey tou forgot that !! > > Paint.fill > > > > >>> Next >>> End >>> >>> It prints blank pages only, while the Printer example works O.K. >>> I don't understand this at all. I'm wrestling with this since 3 days. >>> >> >> If you send me a project, I will be able to look deeper in your problem! >> >> -- >> Benoît Minisini >> >> -- >> All of the data generated in your IT infrastructure is seriously valuable. >> Why? It contains a definitive record of application performance, security >> threats, fraudulent activity, and more. Splunk takes this data and makes >> sense of it. IT sense. And common sense. >> http://p.sf.net/sfu/splunk-d2d-c2 >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > > > when you are using paint it have 2 time : > > creating the path > > filling or trace it > > > To fill it : Paint.fill > > To trace the border : Paint.Stroke > > You can do the both : > > Paint.Fill(true) > Paint.Stroke > > > If you want to have a letter With a border Red and the middle yellow > Paint.Font.Size = 16 > Paint.Text("a",1,1) > Paint.Brush = Paint.Color(color.yellow) > Paint.Fill(true) > Paint.Brush = paint.Color(Color.red) > Paint.Fill > > > > So now your code will be > > > > -- > Fabien Bodard > > Public Sub samsung_Draw() > Dim i As Integer > Dim tagok As String[] > tagok = Split(datae[curr], ";") > For i = 0 To tagok.Count - 1 > Paint.Font = Font["Lucida Sans"] > Paint.Font.Size = lett[i] > Paint.DrawText(tagok[i], CFloat(xcor[i]), CFloat(ycor[i])) > Paint.Fill > next > end > > If you forgot the fill statement ... the printer draw nothing > > Paint class work like cairo, and is really different of the draw class. > > Take a look at the painting example. > > -- > Fabien Bodard > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Please help me!
I've tried to do exactly what I've done in G2: giving coordinates in original pixel sizes of the image. Can I set the resolution to 300 dpi and to use the originally measured horizontal and vertical pixel coordinates for printing? You know the program I'm working on is right about the using mouse coordinates for positioning the text, to avoid the unnecessary measurement coordinate's transformation. But as it seems to me, G3 is about how to make simple things complicated :( Thanks anyway, I'll try to fix it. Csaba 2011/7/1, Fabien Bodard : > 2011/7/1 M. Cs. : >> O.K. The printing started now, but it prints the texts one over >> another regardless to the coordinates given by CFloat(xcor[i]) and >> CFloat(ycor[i]). Why? > Do you use the true size ? > > What are the coord ? > > be carefull as the printer with in pixel is différent as the screen width > > > For exemple in printer_draw() just try taht : > > > Print Paint.Width it's the page wisth in pixel > Print Paint.Height 'same thing for the height > > Printers have generally 1200 dpi ... but it depend of the printer ! > > in gb.report i use a virtual intermediate size ... in cm > > all is stored in cm and is converted at the last time in pixel. So i > can exactly calculate positions. > > The font size is directly managed by qt or gtk at the good size in > function of the printer resolution. > > > > >> >> 2011/6/30, Fabien Bodard : >>> Le 30 juin 2011 14:00, Benoît Minisini a >>> écrit : >>>>> Yes, Benoit, >>>>> still even if change the synthax to: >>>>> >>>>> Public Sub PrintID() >>>>> Dim i As Integer >>>>> Dim tagok As String[] >>>>> samsung = New Printer As "samsung" >>>>> If samsung.Configure() Then Return >>>>> samsung.Count = 1 >>>>> samsung.Print >>>>> >>>>> End >>>>> >>>>> Public Sub samsung_Begin() >>>>> >>>>> End >>>>> >>>>> Public Sub samsung_Draw() >>>>> Dim i As Integer >>>>> Dim tagok As String[] >>>>> tagok = Split(datae[curr], ";") >>>>> For i = 0 To tagok.Count - 1 >>>>> Paint.Font = Font["Lucida Sans"] >>>>> Paint.Font.Size = lett[i] >>>>> Paint.DrawText(tagok[i], CFloat(xcor[i]), CFloat(ycor[i])) >>> >>> 'hey tou forgot that !! >>> >>> Paint.fill >>> >>> >>> >>> >>>>> Next >>>>> End >>>>> >>>>> It prints blank pages only, while the Printer example works O.K. >>>>> I don't understand this at all. I'm wrestling with this since 3 days. >>>>> >>>> >>>> If you send me a project, I will be able to look deeper in your problem! >>>> >>>> -- >>>> Benoît Minisini >>>> >>>> -- >>>> All of the data generated in your IT infrastructure is seriously >>>> valuable. >>>> Why? It contains a definitive record of application performance, >>>> security >>>> threats, fraudulent activity, and more. Splunk takes this data and makes >>>> sense of it. IT sense. And common sense. >>>> http://p.sf.net/sfu/splunk-d2d-c2 >>>> ___ >>>> Gambas-user mailing list >>>> Gambas-user@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/gambas-user >>>> >>> >>> >>> when you are using paint it have 2 time : >>> >>> creating the path >>> >>> filling or trace it >>> >>> >>> To fill it : Paint.fill >>> >>> To trace the border : Paint.Stroke >>> >>> You can do the both : >>> >>> Paint.Fill(true) >>> Paint.Stroke >>> >>> >>> If you want to have a letter With a border Red and the middle yellow >>> Paint.Font.Size = 16 >>> Paint.Text("a",1,1) >>> Paint.Brush = Paint.Color(color.yellow) >>> Paint.Fill(true) >>> Paint.Brush = paint.Color(Color.red) >>> Paint.Fill >>> >>> >>> >>> So now your code will be >>> >>> >>> >>> -- >>> Fabien Bodard >>> >>> Pu
Re: [Gambas-user] Please help me!
Thanks, these are clear words we need! I think it is very important to have clear explanations. 2011/7/3, Benoît Minisini : >> I've tried to do exactly what I've done in G2: giving coordinates in >> original pixel sizes of the image. >> Can I set the resolution to 300 dpi and to use the originally measured >> horizontal and vertical pixel coordinates for printing? You know the >> program I'm working on is right about the using mouse coordinates for >> positioning the text, to avoid the unnecessary measurement >> coordinate's transformation. But as it seems to me, G3 is about how to >> make simple things complicated :( >> >> Thanks anyway, I'll try to fix it. >> >> Csaba >> > > There are three reasons for the new Printer API in Gambas 3 : > > - The Qt drawing model has changed. > - GTK+ got a printer API that uses Cairo. > - The Gambas 2 Printer API was blocking the GUI. > > So it is a bit more complicated now, as you have to use events, and the new > Paint class that mimics the Cairo API. > > Otherwise, there is no "unnecessary coordinate transformation". If you using > screen coordinates for printing in Gambas 2 worked, then it just means that > you were lucky. > > Because doing that is as false in Gambas 2 as it is in Gambas 3. > > In other words, you have to do coordinate transformation. > > To do that, for example, you draw inside the (0, 0, Printer.PaperWidth, > Printer.PaperHeight) rectangle, each unit being a millimeter. And before > calling the Paint method, you scale the rectangle to (0, 0, Draw.Width, > Draw.Height). > > To do this scaling, you have the "Paint matrix", i.e. the Paint.Scale() > method. > > I will try to add these explanations to the wiki. > > Regards, > > -- > Benoît Minisini > > -- > All of the data generated in your IT infrastructure is seriously valuable. > Why? It contains a definitive record of application performance, security > threats, fraudulent activity, and more. Splunk takes this data and makes > sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-d2d-c2 > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2d-c2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] About Printer
Please don't forget to publish your working solution. We've spent 3 days with Fabian in private investigations with the printing and at the and I have a nearly working solution for the printing. The emphasis is on the word NEARLY. There are still problems with some pixel constraints. Printing is everything but easy in gambas. This is the first time for me to hear about prtPrinter.FullPage option, so please, PLEASE, give us tested and explained examples. 2011/7/19, Demosthenes Koptsis : > On Tue, 2011-07-19 at 15:13 +0200, Benoît Minisini wrote: >> > > > >> > > > 'Set scale >> > > > wFactor = prtPrinter.PaperWidth / Paint.Width >> > > > hFactor = prtPrinter.PaperHeight / Paint.Height >> > > > Paint.Scale(wFactor, hFactor) >> > > > >> > > Ok, i took this example from this page > http://www.gambasdoc.org/help/howto/print?v3 > > i think there is also inverted the scale factors. > > >> I'm stupid, the scale factors must be inverted! >> >> wFactor = Paint.Width / prtPrinter.PaperWidth >> hFactor = Paint.Height / prtPrinter.PaperHeight >> Paint.Scale(wFactor, hFactor) >> >> And prtPrinter.FullPage must be set to TRUE before calling >> prtPrinter.Print. >> Otherwise, Paint.Width and Paint.Height will take the margins into >> account. >> > > -- > Regards, > Demosthenes > > > -- > Magic Quadrant for Content-Aware Data Loss Prevention > Research study explores the data loss prevention market. Includes in-depth > analysis on the changes within the DLP market, and the criteria used to > evaluate the strengths and weaknesses of these DLP solutions. > http://www.accelacomm.com/jaw/sfnl/114/51385063/ > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Magic Quadrant for Content-Aware Data Loss Prevention Research study explores the data loss prevention market. Includes in-depth analysis on the changes within the DLP market, and the criteria used to evaluate the strengths and weaknesses of these DLP solutions. http://www.accelacomm.com/jaw/sfnl/114/51385063/ ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Creating database in Gambas3
Hi! I want to port my G2 application to G3. I would like to know what are the news for database handling in G3. 1. How to check whether a sqlite database exist? 2. How to create a database? 3. Can I use DB.Exec() for table creation or is there another preferred way to do it? Thanks! Csaba -- Malware Security Report: Protecting Your Business, Customers, and the Bottom Line. Protect your business and customers by understanding the threat from malware and how it can impact your online business. http://www.accelacomm.com/jaw/sfnl/114/51427462/ ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Install gambas3 on Oneiric
Hi, I would like to install Gambas3 on Oneiric 64bit, but using Haywood's PPA for Natty I couldn't fulfill the task. Are there packages for this release? Thanks! -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Install gambas3 on Oneiric
THANKS! Csaba 2011/11/26, Jussi Lahtinen : > I don't have packages, but compiling the source is not difficult. > > > 1. First install essential packages you need to compile: > > *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 > * > > > 2. Commands to get sources to ~/trunk folder: > > *cd ~/ > svn checkout https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/ > * > > > 3. Script to compile (or recompile), just copy this to text editor, save it > as whatever.sh and open file properties to give privileges for execution: > > *#!/bin/sh > sudo rm -f /usr/local/bin/gbx3 /usr/local/bin/gbc3 /usr/local/bin/gba3 > /usr/local/bin/gbi3 > sudo rm -rf /usr/local/lib/gambas3 > sudo rm -rf /usr/local/share/gambas3 > cd ~/trunk > echo "Old installation cleaned!" > ( ./reconf-all && ./configure -C && make && sudo make install ) > > ~/Desktop/compile.log 2>&1 > sudo -k > echo "Done!"* > > > Or look at the official help for compiling: > http://gambasdoc.org/help/install?en&view > > Jussi > > > > > On Sat, Nov 26, 2011 at 14:13, M. Cs. wrote: > >> Hi, I would like to install Gambas3 on Oneiric 64bit, but using >> Haywood's PPA for Natty I couldn't fulfill the task. Are there >> packages for this release? >> >> Thanks! >> >> >> -- >> All the data continuously generated in your IT infrastructure >> contains a definitive record of customers, application performance, >> security threats, fraudulent activity, and more. Splunk takes this >> data and makes sense of it. IT sense. And common sense. >> http://p.sf.net/sfu/splunk-novd2d >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > -- > All the data continuously generated in your IT infrastructure > contains a definitive record of customers, application performance, > security threats, fraudulent activity, and more. Splunk takes this > data and makes sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-novd2d > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Form.Screen is incorrectly overridden in class FMain
What could that mean? I'm trying to port a G2 project to G3, but this error is shown upon program start. Thanks! Csaba -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Form.Screen is incorrectly overridden in class FMain
Thanks! Gambas 3 did really improve in the last 6 months! I've tried to port the same app then, but there were many problems which are simply solved now! 2011/11/26, Benoît Minisini : > Le 26/11/2011 20:25, M. Cs. a écrit : >> What could that mean? >> I'm trying to port a G2 project to G3, but this error is shown upon >> program start. >> Thanks! >> >> Csaba >> > > Form.Screen is a new property in Gambas 3. So you must use another name > for your own use. > > Regards, > > -- > Benoît Minisini > > -- > All the data continuously generated in your IT infrastructure > contains a definitive record of customers, application performance, > security threats, fraudulent activity, and more. Splunk takes this > data and makes sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-novd2d > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Menu icons are not displayed
Hello all! I have a problem. While around 90% of the ported project works well on G3, my menu images are not visible. They are present in the project's root folder just as they were there in G2. Any idea? Csaba -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Menu icons are not displayed
I'm using Xubuntu 11.10, and the images on startmenu items are displayed well. I'll check it under LXDE. 2011/11/27, Benoît Minisini : > Le 27/11/2011 18:04, M. Cs. a écrit : >> Hello all! >> I have a problem. While around 90% of the ported project works well on >> G3, my menu images are not visible. They are present in the project's >> root folder just as they were there in G2. Any idea? >> >> Csaba >> > > Let me guess: you are using Ubuntu or the Ubuntu Qt4 style that does not > display icons in menus? > > -- > Benoît Minisini > > -- > All the data continuously generated in your IT infrastructure > contains a definitive record of customers, application performance, > security threats, fraudulent activity, and more. Splunk takes this > data and makes sense of it. IT sense. And common sense. > http://p.sf.net/sfu/splunk-novd2d > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Menu icons are not displayed
Yes, you got it! The menu icons are displayed correctly when I use LXDE desktop. So this may be issue with XFCE style. Thanks! 2011/11/27, M. Cs. : > I'm using Xubuntu 11.10, and the images on startmenu items are displayed > well. > I'll check it under LXDE. > > 2011/11/27, Benoît Minisini : >> Le 27/11/2011 18:04, M. Cs. a écrit : >>> Hello all! >>> I have a problem. While around 90% of the ported project works well on >>> G3, my menu images are not visible. They are present in the project's >>> root folder just as they were there in G2. Any idea? >>> >>> Csaba >>> >> >> Let me guess: you are using Ubuntu or the Ubuntu Qt4 style that does not >> display icons in menus? >> >> -- >> Benoît Minisini >> >> -- >> All the data continuously generated in your IT infrastructure >> contains a definitive record of customers, application performance, >> security threats, fraudulent activity, and more. Splunk takes this >> data and makes sense of it. IT sense. And common sense. >> http://p.sf.net/sfu/splunk-novd2d >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Release of Gambas 3 RC7
Hello Benoit! Congrats for the RC7 and a possible bug with string functions: This function should return the string in mixed case, but it won't: Public Sub TextTog2_Click() Dim intet, gig, a, b As String Dim insta As String[] Dim i As Integer gig = editTitle.Text insta = Split(gig, " ") intet = "" For i = 0 To insta.Count - 1 a = Left$(insta[i], 1) b = Lower$(Mid$(insta[i], 2)) intet = intet & a & b & " " Next intet = Trim$(intet) editTitle.Text = intet End It should work like: Im the text -> Im The Textwhere the editTitle is a text input 2011/12/24, Benoît Minisini : > As promised, but a bit late, here is the seventh release candidate of > Gambas 3! > > As many bugs as possible were fixed, and a few last-minute new features > were implemented. Mainly: > > * A new "Gambas" highlighting theme for the IDE. > * A new TabPanel control, that is a TabStrip with thin borders. > * The ability to define the connection timeout in the database component. > * gb.report that is almost finished. > > See the Release Notes for the full ChangeLog. > > Please report any problem as usual... > > The final release is planned for the 31 Dec 2011. > > Best regards, > > -- > Benoît Minisini > > -- > Write once. Port to many. > Get the SDK and tools to simplify cross-platform app development. Create > new or port existing apps to sell to consumers worldwide. Explore the > Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join > http://p.sf.net/sfu/intel-appdev > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Write once. Port to many. Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join http://p.sf.net/sfu/intel-appdev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Release of Gambas 3 RC7
Oh, you are right! Cheers! 2011/12/25, Caveat : > Huh? Perhaps I'm enjoying my box of English beers too much (Christmas > present so I feel obliged to drink them today) but how do you expect "Im > the text" to turn into "Im The Text" (with apologies to the apostrophe > police) when you don't use any Upper functions? > > Or is your code deliberately obscure and using some trick to make the > initial letters uppercase? > > Season's greetings! > Caveat > > On Sun, 2011-12-25 at 17:52 +0100, M. Cs. wrote: >> Hello Benoit! >> Congrats for the RC7 and a possible bug with string functions: >> This function should return the string in mixed case, but it won't: >> >> Public Sub TextTog2_Click() >> Dim intet, gig, a, b As String >> Dim insta As String[] >> Dim i As Integer >> gig = editTitle.Text >> insta = Split(gig, " ") >> intet = "" >> For i = 0 To insta.Count - 1 >> a = Left$(insta[i], 1) >> b = Lower$(Mid$(insta[i], 2)) >> intet = intet & a & b & " " >> Next >> intet = Trim$(intet) >> editTitle.Text = intet >> End >> >> It should work like: Im the text -> Im The Textwhere the editTitle >> is a text input >> >> 2011/12/24, Benoît Minisini : >> > As promised, but a bit late, here is the seventh release candidate of >> > Gambas 3! >> > >> > As many bugs as possible were fixed, and a few last-minute new features >> > were implemented. Mainly: >> > >> > * A new "Gambas" highlighting theme for the IDE. >> > * A new TabPanel control, that is a TabStrip with thin borders. >> > * The ability to define the connection timeout in the database >> > component. >> > * gb.report that is almost finished. >> > >> > See the Release Notes for the full ChangeLog. >> > >> > Please report any problem as usual... >> > >> > The final release is planned for the 31 Dec 2011. >> > >> > Best regards, >> > >> > -- >> > Benoît Minisini >> > >> > -- >> > Write once. Port to many. >> > Get the SDK and tools to simplify cross-platform app development. Create >> > new or port existing apps to sell to consumers worldwide. Explore the >> > Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join >> > http://p.sf.net/sfu/intel-appdev >> > ___ >> > Gambas-user mailing list >> > Gambas-user@lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/gambas-user >> > >> >> -- >> Write once. Port to many. >> Get the SDK and tools to simplify cross-platform app development. Create >> new or port existing apps to sell to consumers worldwide. Explore the >> Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join >> http://p.sf.net/sfu/intel-appdev >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -- > Write once. Port to many. > Get the SDK and tools to simplify cross-platform app development. Create > new or port existing apps to sell to consumers worldwide. Explore the > Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join > http://p.sf.net/sfu/intel-appdev > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Write once. Port to many. Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join http://p.sf.net/sfu/intel-appdev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Gambas 3 is out!
Congrats Benoit! I wish you a Gambastic new year! Csaba 2011/12/31, Willy Raets : > Successful installation of Gambas 3 on Ubuntu 10.10 > > [System] > OperatingSystem=Linux > Kernel=2.6.35-31-generic > Architecture=i686 > Memory=2051628 kB > DistributionVendor=Ubuntu > DistributionRelease="Ubuntu 10.10" > Desktop=Gnome > > [Gambas 2] > Version=2.22.0 > Path=/usr/bin/gbx2 > > [Gambas 3] > Version=3.0.0 > Path=/usr/local/bin/gbx3 > > Thanks again for all the good work..hope to find Gambas in the > repositories of Ubuntu soon.. > > Willy > > > > On za, 2011-12-31 at 05:34 +0100, Benoît Minisini wrote: > >> Le 31/12/2011 05:23, Willy Raets a écrit : >> > On gambas website it says Gambas 3 on download button. >> > Downloads gambas3-2.99.7.tar.bz2 -> this must be a mistake since this >> > is >> > RC7 already on my system >> > >> > Someone overlooked something maybe? >> > >> > Willy >> > >> >> Oops. I fix that and go to bed... >> > > > -- > 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 > -- > Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex > infrastructure or vast IT resources to deliver seamless, secure access to > virtual desktops. With this all-in-one solution, easily deploy virtual > desktops for less than the cost of PCs and save 60% on VDI infrastructure > costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Cannot close GUI application
The command Quit() won't work in my application, so I cannot terminate the process. The GUI disappears, but the process remains. Is there any safe way to close a GUI application? Csaba -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Cannot close GUI application
Thanks for the replies! Csaba 2012/1/2, Ron : > You always get unfreed stuff when using Quit in a GUI project is my > experience. > > In Form_Close() > > ' exit program > Main.CloseAll() > FMain.Close > > END > > In CloseAll() I close all file handles, sockets, serial ports and stop > timers. > Then FMain.Close does the trick nicely. > > Regards, > Ron_2nd. > 2012/1/2 Fabien Bodard > >> Le 2 janvier 2012 19:57, Benoît Minisini >> a écrit : >> > Le 02/01/2012 17:03, M. Cs. a écrit : >> >> The command Quit() won't work in my application, so I cannot terminate >> >> the process. The GUI disappears, but the process remains. Is there any >> >> safe way to close a GUI application? >> >> >> >> Csaba >> >> >> > >> > Please elaborate. Send me a project so that I can reproduce the problem. >> > The QUIT instruction aborts the program brutally (almost), so it should >> > quit! >> >> I'm on it ... Bad design... many variables are not freed. >> >> It's not a bug >> >> > >> > -- >> > Benoît Minisini >> > >> > >> -- >> > Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a >> > complex >> > infrastructure or vast IT resources to deliver seamless, secure access >> > to >> > virtual desktops. With this all-in-one solution, easily deploy virtual >> > desktops for less than the cost of PCs and save 60% on VDI >> > infrastructure >> > costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox >> > ___ >> > Gambas-user mailing list >> > Gambas-user@lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> >> >> -- >> Fabien Bodard >> >> >> -- >> Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex >> infrastructure or vast IT resources to deliver seamless, secure access to >> virtual desktops. With this all-in-one solution, easily deploy virtual >> desktops for less than the cost of PCs and save 60% on VDI infrastructure >> costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > -- > Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex > infrastructure or vast IT resources to deliver seamless, secure access to > virtual desktops. With this all-in-one solution, easily deploy virtual > desktops for less than the cost of PCs and save 60% on VDI infrastructure > costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Write once. Port to many. Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join http://p.sf.net/sfu/intel-appdev ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] File opening dialog and one more question
Hi, in G2 we had a file opening dialog which was identical as KDE's native one. It seems to be removed, or am I wrong? I would like to have that old one. It's more convenient with the system-wide bookmarks etc. And the question: I don't understand the STATIC word's meaning. Is it given to define a constant inside a class? What's the practical usage of it? I have to redesign my Gambas project, and I need to know the exact usage. The documentation didn't make it clear to me. I Know what Public and what Private is. Thanks! Csaba -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Dependencies in packages
Another question: In the package making dialog there is a list of dependencies to be added to the package. How can I add mp3info as dependency? I've tried to add just string mp3info without min and max versions, but the installer is not pulling it as dependency. Thanks! -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] File opening dialog and one more question
Unfortunately the built-in file opening dialog just doesn't work for me. The project has been ported from G2 to G3. I have a filter added for the .tar.gz filetype but although it shows the correct files, I cannot open them. The OK button simply doesn't work. It's maybe up to the porting. I'll check it. 2012/1/5, Caveat : > Part one > > I never really looked into how GTK-alike the FileChooser was, but it > didn't seem to 'fit' on my regular forms, so I just made a small Form > which handles file choosing/opening and raises the appropriate events. > > To answer part two... > > As I understand it, static variables exist only once for the class > regardless of how many instances of the class you have in memory. > Non-static variables exist per instance of the class. > > A static variable that's not defined as a Const can be a little > dangerous (or at least confusing), as anyone changing the value on a > particular instance of the class changes it for all other instances of > that class too (as there is only one 'copy' of the variable). Const > implies static...so the static keyword is optional when defining a > const. > > As an example, you might have a CurrencyConverter class which defines > Euro to Belgian Francs as a static const set to 40., UKP to US$ as > static (but not const... so changing it on one instance of > CurrencyConverter will change it for all instances), and the amount to > convert as non-static, non-const... hope that example made some sense! > > Regards, > Caveat > > > On Thu, 2012-01-05 at 12:35 +0100, M. Cs. wrote: >> Hi, >> in G2 we had a file opening dialog which was identical as KDE's native >> one. It seems to be removed, or am I wrong? I would like to have that >> old one. It's more convenient with the system-wide bookmarks etc. >> >> And the question: I don't understand the STATIC word's meaning. Is it >> given to define a constant inside a class? What's the practical usage >> of it? I have to redesign my Gambas project, and I need to know the >> exact usage. The documentation didn't make it clear to me. I Know what >> Public and what Private is. Thanks! >> >> Csaba >> >> -- >> Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex >> infrastructure or vast IT resources to deliver seamless, secure access to >> virtual desktops. With this all-in-one solution, easily deploy virtual >> desktops for less than the cost of PCs and save 60% on VDI infrastructure >> costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user > > > > -- > Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex > infrastructure or vast IT resources to deliver seamless, secure access to > virtual desktops. With this all-in-one solution, easily deploy virtual > desktops for less than the cost of PCs and save 60% on VDI infrastructure > costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] The good old tar-1.13 is still an obstacle
Hello, I simply don't know how to install tar-1.13 on Kubuntu Oneiric. The old method of creating it from sources an then making a symbolic link with ln -s /usr/local/bin/tar-1.13 /usr/bin/tar-1.13 doesn't solves the problem. Any working solution of faking it? Csaba -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] File opening dialog and one more question
Yes, it was caused by porting. I've fixed it. 2012/1/5, M. Cs. : > Unfortunately the built-in file opening dialog just doesn't work for > me. The project has been ported from G2 to G3. I have a filter added > for the .tar.gz filetype but although it shows the correct files, I > cannot open them. The OK button simply doesn't work. It's maybe up to > the porting. I'll check it. > > 2012/1/5, Caveat : >> Part one >> >> I never really looked into how GTK-alike the FileChooser was, but it >> didn't seem to 'fit' on my regular forms, so I just made a small Form >> which handles file choosing/opening and raises the appropriate events. >> >> To answer part two... >> >> As I understand it, static variables exist only once for the class >> regardless of how many instances of the class you have in memory. >> Non-static variables exist per instance of the class. >> >> A static variable that's not defined as a Const can be a little >> dangerous (or at least confusing), as anyone changing the value on a >> particular instance of the class changes it for all other instances of >> that class too (as there is only one 'copy' of the variable). Const >> implies static...so the static keyword is optional when defining a >> const. >> >> As an example, you might have a CurrencyConverter class which defines >> Euro to Belgian Francs as a static const set to 40., UKP to US$ as >> static (but not const... so changing it on one instance of >> CurrencyConverter will change it for all instances), and the amount to >> convert as non-static, non-const... hope that example made some sense! >> >> Regards, >> Caveat >> >> >> On Thu, 2012-01-05 at 12:35 +0100, M. Cs. wrote: >>> Hi, >>> in G2 we had a file opening dialog which was identical as KDE's native >>> one. It seems to be removed, or am I wrong? I would like to have that >>> old one. It's more convenient with the system-wide bookmarks etc. >>> >>> And the question: I don't understand the STATIC word's meaning. Is it >>> given to define a constant inside a class? What's the practical usage >>> of it? I have to redesign my Gambas project, and I need to know the >>> exact usage. The documentation didn't make it clear to me. I Know what >>> Public and what Private is. Thanks! >>> >>> Csaba >>> >>> -- >>> Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a >>> complex >>> infrastructure or vast IT resources to deliver seamless, secure access >>> to >>> virtual desktops. With this all-in-one solution, easily deploy virtual >>> desktops for less than the cost of PCs and save 60% on VDI >>> infrastructure >>> costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox >>> ___ >>> Gambas-user mailing list >>> Gambas-user@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/gambas-user >> >> >> >> -- >> Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex >> infrastructure or vast IT resources to deliver seamless, secure access to >> virtual desktops. With this all-in-one solution, easily deploy virtual >> desktops for less than the cost of PCs and save 60% on VDI infrastructure >> costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox >> ___ >> Gambas-user mailing list >> Gambas-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/gambas-user >> > -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] File opening dialog and one more question
Thank you! 2012/1/5, Benoît Minisini : > Le 05/01/2012 12:35, M. Cs. a écrit : >> Hi, >> in G2 we had a file opening dialog which was identical as KDE's native >> one. It seems to be removed, or am I wrong? I would like to have that >> old one. It's more convenient with the system-wide bookmarks etc. > > I'm not sure. But when you call Dialog.Open(), the standard Qt file > dialog is used (or the GTK+ one if you use gb.gtk). Then maybe Qt can > use the KDE dialog if it is present, but I don't think so. > > In GB2, you had a gb.qt.kde component that uses the KDE3 dialog > automatically. In GB3, you don't have any KDE4 component, so you don't > have the KDE dialogs. > >> >> And the question: I don't understand the STATIC word's meaning. Is it >> given to define a constant inside a class? What's the practical usage >> of it? I have to redesign my Gambas project, and I need to know the >> exact usage. The documentation didn't make it clear to me. I Know what >> Public and what Private is. Thanks! >> >> Csaba >> > > "Static" means: > > - For a variable, that the variable is stored in the class, not in any > object. So there is only one such variable. Its value does not depend on > the object. > > - For a method (or a property), that the method cannot use any > non-static symbol (ME is NULL). > > - For a constant, nothing, as a constant is always static (as its value > cannot change). > > I hope it will be clear for you! > > Regards, > > -- > Benoît Minisini > > -- > Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex > infrastructure or vast IT resources to deliver seamless, secure access to > virtual desktops. With this all-in-one solution, easily deploy virtual > desktops for less than the cost of PCs and save 60% on VDI infrastructure > costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Another basics
Hello, before i take off with redesign, I'd like to check whether I'm right or not: 1. Modules are for functions and procedures. To split the program into building bricks 2. Classes for object construction. If I need an object, I'm using classes with private variables, private subs for the internal tasks of a class, and public subs for communication between the modules and classes. Am I right? Csaba -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Another basics
Hello Fabien, and I also think it would be nice to hear about how to keep the code clean. I have to rewrite the things in order to have a program without unfreed allocations. What I intend to do is to use more private variables on modules and well defined functions to access to them across the modules if needed. 2012/1/6, Fabien Bodard : > well :) > > i'm not a true professionnal of computing so words i use are not good. > (and my english is really bad) > > In a class you have 3 time > > _Init > Called only one time at the first use of the class > > _New > Called at each NEW instantiation > > _Free > Called when a classe is freed (when the ref to this class instance > not stored anywhere) > > > > > You can access a public var from anywhere but this var is linked to an > instance > > If you use static public the var is accessible from the class name > like with a module and not depend of an instance. (it allow for > example to share a value between each instance of a class > > Private var is accessible ony from the sub of the current class > > static private can be used only from a static sub. > > > > I use public var for property that just store a value and can be > accessed in read write mode > > i use property for value that need controle or that generate an event > > > for example > dim $iX as private > property X as integer > > Private X_Read() as Integer > return $iX > end > > Private X_Write(Value as integer) > $iX = min(Value,100) 'max 100 > RefreshDraw() 'redraw the object when the x is changed > end > > > You can use Property Read for a read only value > > > this is some basis. > > -- > Fabien Bodard > > -- > Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex > infrastructure or vast IT resources to deliver seamless, secure access to > virtual desktops. With this all-in-one solution, easily deploy virtual > desktops for less than the cost of PCs and save 60% on VDI infrastructure > costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] The good old tar-1.13 is still an obstacle
Hello Benoit! Your method doesn't work on Kubuntu 11.10. I simply cannot create Slackware package with IDE. Any other solution? Csaba 2012/1/5, Benoît Minisini : > Le 05/01/2012 17:12, M. Cs. a écrit : >> Hello, >> I simply don't know how to install tar-1.13 on Kubuntu Oneiric. The >> old method of creating it from sources an then making a symbolic link >> with ln -s /usr/local/bin/tar-1.13 /usr/bin/tar-1.13 doesn't solves >> the problem. Any working solution of faking it? >> >> Csaba >> > > Personnaly, I create a symbolic link name "tar-1.13" that points at the > actual current tar, and the last time I tried it worked. > > -- > Benoît Minisini > > -- > Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex > infrastructure or vast IT resources to deliver seamless, secure access to > virtual desktops. With this all-in-one solution, easily deploy virtual > desktops for less than the cost of PCs and save 60% on VDI infrastructure > costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex infrastructure or vast IT resources to deliver seamless, secure access to virtual desktops. With this all-in-one solution, easily deploy virtual desktops for less than the cost of PCs and save 60% on VDI infrastructure costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Difficulties using Gambas 3 IDE
It's quite difficult to use the new IDE: I'm designing a project using panels and Hboxes and Vboxes and other expanders, but it is almost impossible to determine which element I'm editing. The Property box is messing the names of the elements, after few settings done. After 5-6 settings I cannot distinguish whether I'm doing the setup of a proper element or not. The packager doesn't draws the external dependencies at all. Is this a number of bugs? -- RSA(R) Conference 2012 Mar 27 - Feb 2 Save $400 by Jan. 27 Register now! http://p.sf.net/sfu/rsa-sfdev2dev2 ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Database question
Hi! Is there any built in function in Gambas3 which can secure the database connection from the errors caused by special characters? I have written functions for replacing the dangerous characters like ', +, . and so on, but I'd like to know whether there is a way to make queries secure from failures. Thanks! -- 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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Database question
Yes, Benoit. I'll check the documentation, since I always used the Myconnection.Exec("SELECT FROM table WHERE field='"& myvar & "';) form of the querying, and now I would like to change it to a more convenient way, since I always had to assure myvar is safe. 2012/1/18, Benoît Minisini : > Le 18/01/2012 14:17, M. Cs. a écrit : >> Hi! >> Is there any built in function in Gambas3 which can secure the >> database connection from the errors caused by special characters? >> >> I have written functions for replacing the dangerous characters like >> ', +, . and so on, but I'd like to know whether there is a way to make >> queries secure from failures. >> >> Thanks! >> > > SQL quoting is automatically done by the following methods of the > Connection class: Exec(), Find(), Edit(), Delete(), Subst(), provided that: > > - You use "&1", "&2"... inside the request string to tell where quoted > arguments must be inserted. > > - You actually pass these arguments. > > Is it what you need? > > -- > 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Database question
I'm sorry Benoit, I would like to ask your help with this kind of insertions: If I have a table called MyTable with creation: CREATE TABLE CENTRAL(VName Text,FPath TEXT,FName TEXT,FSubs INTEGER,FSize REAL,FChanged TEXT); How could I ensure the failsafe insert query with following fields: VName-> Photos 5. FPath -> /Image3 /2011 FName-> Brother's day.jpg FSubs-> 1 FSize-> 568234.2 FChanged-> 2011-12-06 So how to use &1 and &2 arguments in work? And how can I retrieve the fields where FName is Like sign ' as in Brother's day.jpg? The query usually fails just like that If I try to seek for the files containing certain characters which are in use by the Sqlite backend. I only need two lines of the answer. Thanks! Csaba 2012/1/18, M. Cs. : > Yes, Benoit. I'll check the documentation, since I always used the > Myconnection.Exec("SELECT FROM table WHERE field='"& myvar & "';) form > of the querying, and now I would like to change it to a more > convenient way, since I always had to assure myvar is safe. > > 2012/1/18, Benoît Minisini : >> Le 18/01/2012 14:17, M. Cs. a écrit : >>> Hi! >>> Is there any built in function in Gambas3 which can secure the >>> database connection from the errors caused by special characters? >>> >>> I have written functions for replacing the dangerous characters like >>> ', +, . and so on, but I'd like to know whether there is a way to make >>> queries secure from failures. >>> >>> Thanks! >>> >> >> SQL quoting is automatically done by the following methods of the >> Connection class: Exec(), Find(), Edit(), Delete(), Subst(), provided >> that: >> >> - You use "&1", "&2"... inside the request string to tell where quoted >> arguments must be inserted. >> >> - You actually pass these arguments. >> >> Is it what you need? >> >> -- >> 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Database question
Some more clarification of my problem: I had two procedures to communicate with the sqlite database: Public Sub Trans(be As String) As String Dim atmen As String atmen = Replace$(be, "$", ".") atmen = Replace$(atmen, "€", "-") atmen = Replace$(atmen, "_", " ") atmen = Replace$(atmen, "£", "/") atmen = Replace$(atmen, "¢", "+") atmen = Replace$(atmen, "§", "'") atmen = Replace$(atmen, "¥", ":") Return atmen End Public Sub TransB(be As String) As String Dim atmen As String atmen = Replace$(be, ".", "$") atmen = Replace$(atmen, "-", "€") atmen = Replace$(atmen, " ", "_") atmen = Replace$(atmen, "/", "£") atmen = Replace$(atmen, "+", "¢") atmen = Replace$(atmen, "'", "§") atmen = Replace$(atmen, ":", "¥") Return atmen End These were the guards for special characters. The first one did the conversion from database to GUI, the second did encode the strings for the database insertion. I suppose there is a better way for doing it. I'd like to learn that way! 2012/1/19, M. Cs. : > I'm sorry Benoit, > I would like to ask your help with this kind of insertions: > If I have a table called MyTable with creation: > > CREATE TABLE CENTRAL(VName Text,FPath TEXT,FName TEXT,FSubs > INTEGER,FSize REAL,FChanged TEXT); > > How could I ensure the failsafe insert query with following fields: > VName-> Photos 5. > FPath -> /Image3 /2011 > FName-> Brother's day.jpg > FSubs-> 1 > FSize-> 568234.2 > FChanged-> 2011-12-06 > > So how to use &1 and &2 arguments in work? > > And how can I retrieve the fields where FName is Like sign ' as in > Brother's day.jpg? > > The query usually fails just like that If I try to seek for the files > containing certain characters which are in use by the Sqlite backend. > > I only need two lines of the answer. Thanks! > > Csaba > > > 2012/1/18, M. Cs. : >> Yes, Benoit. I'll check the documentation, since I always used the >> Myconnection.Exec("SELECT FROM table WHERE field='"& myvar & "';) form >> of the querying, and now I would like to change it to a more >> convenient way, since I always had to assure myvar is safe. >> >> 2012/1/18, Benoît Minisini : >>> Le 18/01/2012 14:17, M. Cs. a écrit : >>>> Hi! >>>> Is there any built in function in Gambas3 which can secure the >>>> database connection from the errors caused by special characters? >>>> >>>> I have written functions for replacing the dangerous characters like >>>> ', +, . and so on, but I'd like to know whether there is a way to make >>>> queries secure from failures. >>>> >>>> Thanks! >>>> >>> >>> SQL quoting is automatically done by the following methods of the >>> Connection class: Exec(), Find(), Edit(), Delete(), Subst(), provided >>> that: >>> >>> - You use "&1", "&2"... inside the request string to tell where quoted >>> arguments must be inserted. >>> >>> - You actually pass these arguments. >>> >>> Is it what you need? >>> >>> -- >>> 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Database question
Thanks Caveat! This little helped to me! A good example is worthy a thousand words! Csaba 2012/1/19, Caveat : > As Benoit says... > >> SQL quoting is automatically done by the following methods of the >> Connection class: Exec(), Find(), Edit(), Delete(), Subst(), provided >> that: > >> - You use "&1", "&2"... inside the request string to tell where >> quoted arguments must be inserted. > >> - You actually pass these arguments. > > Example: > > ... > conn = DataAccess.getConnection() > rSet = conn.Exec("select * from ART001 where CLEF = &1", "AS20") > ' ... or e.g. conn.Exec("select * from ART001 > ' where CLEF = &1 AND DELE = &2", "AS20", "0") > ' ... etc. > If rSet Not Null Then > If rSet.Count > 0 Then > rSet.MoveFirst > Print rSet["CLEF"], rSet["NOMNL"] > Endif > Endif > > Kind regards, > Caveat > > On Thu, 2012-01-19 at 14:09 +0100, M. Cs. wrote: >> Some more clarification of my problem: >> I had two procedures to communicate with the sqlite database: >> >> Public Sub Trans(be As String) As String >> Dim atmen As String >> atmen = Replace$(be, "$", ".") >> atmen = Replace$(atmen, "€", "-") >> atmen = Replace$(atmen, "_", " ") >> atmen = Replace$(atmen, "£", "/") >> atmen = Replace$(atmen, "¢", "+") >> atmen = Replace$(atmen, "§", "'") >> atmen = Replace$(atmen, "¥", ":") >> >> Return atmen >> End >> >> Public Sub TransB(be As String) As String >> Dim atmen As String >> atmen = Replace$(be, ".", "$") >> atmen = Replace$(atmen, "-", "€") >> atmen = Replace$(atmen, " ", "_") >> atmen = Replace$(atmen, "/", "£") >> atmen = Replace$(atmen, "+", "¢") >> atmen = Replace$(atmen, "'", "§") >> atmen = Replace$(atmen, ":", "¥") >> Return atmen >> End >> >> These were the guards for special characters. >> The first one did the conversion from database to GUI, the second did >> encode the strings for the database insertion. >> I suppose there is a better way for doing it. >> I'd like to learn that way! >> >> 2012/1/19, M. Cs. : >> > I'm sorry Benoit, >> > I would like to ask your help with this kind of insertions: >> > If I have a table called MyTable with creation: >> > >> > CREATE TABLE CENTRAL(VName Text,FPath TEXT,FName TEXT,FSubs >> > INTEGER,FSize REAL,FChanged TEXT); >> > >> > How could I ensure the failsafe insert query with following fields: >> > VName-> Photos 5. >> > FPath -> /Image3 /2011 >> > FName-> Brother's day.jpg >> > FSubs-> 1 >> > FSize-> 568234.2 >> > FChanged-> 2011-12-06 >> > >> > So how to use &1 and &2 arguments in work? >> > >> > And how can I retrieve the fields where FName is Like sign ' as in >> > Brother's day.jpg? >> > >> > The query usually fails just like that If I try to seek for the files >> > containing certain characters which are in use by the Sqlite backend. >> > >> > I only need two lines of the answer. Thanks! >> > >> > Csaba >> > >> > >> > 2012/1/18, M. Cs. : >> >> Yes, Benoit. I'll check the documentation, since I always used the >> >> Myconnection.Exec("SELECT FROM table WHERE field='"& myvar & "';) form >> >> of the querying, and now I would like to change it to a more >> >> convenient way, since I always had to assure myvar is safe. >> >> >> >> 2012/1/18, Benoît Minisini : >> >>> Le 18/01/2012 14:17, M. Cs. a écrit : >> >>>> Hi! >> >>>> Is there any built in function in Gambas3 which can secure the >> >>>> database connection from the errors caused by special characters? >> >>>> >> >>>> I have written functions for replacing the dangerous characters like >> >>>> ', +, . and so on, but I'd like to know whether there is a way to >> >>>> make >> >>>> queries secure from failures. >> >>
[Gambas-user] Help! I can't find the error
querry = "SELECT * FROM MP3;" tablak = DBconX.Exec(querry) DBconX.Begin() For Each tablak a1 = Trans(tablak!file) a2 = Trans(tablak!path) a3 = Trans(tablak!Volume) a4 = Trans(tablak!title) a5 = Trans(tablak!artist) a6 = Trans(tablak!album) a7 = Trans(tablak!genre) a8 = Trans(tablak!year) a9 = tablak!lenght a10 = Trans(tablak!lyric) DBconX.Exec("UPDATE MP3 SET file=&1,path=&2,Volume=&3,title=&4,artist=&5,album=&6,genre=&7,year=&8,lenght=&9,lyric=&10 WHERE file=&11 AND path=&12 AND Volume=&13 AND title=&14 AND artist=&15 AND album=&16 AND genre=&17 AND year=&18 AND lenght=&19 AND lyric=&20", a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, tablak!file, tablak!path, tablak!Volume, tablak!title, tablak!artist, tablak!album, tablak!genre, tablak!year, tablak!lenght, tablak!lyric) Next DBconX.Commit() Every variable is defined, the connection is opened the results are retrieved, yet at UPDATE it tells me error. I can't see why. Thanks! -- 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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Fill list box with mysql query
$Result=MyConnection.Exec("SELECT * FROM Mytable;") FOR EACH $Result MyListbox.Add($Result!fieldname) NEXT 2012/1/20, Keith Clark : > How would I go about filling a listbox with a result from a mysql > query? I know how to connect, write the query and get the result back > in say $Result. > > The $Result would contain only one field with multiple rows. > > Thanks, > > Keith > > > -- > 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] How to auto-adjust GridView column widths?
Is there a way to force a GridView control with 4 columns to adjust the column's width to the content's width? How would it work with a control which expands or stretches itself during maximizing the FMain? Thanks! -- 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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] How to auto-adjust GridView column widths?
Public Sub gv_Data(x As Integer, y As Integer) ' Fills the GridView with the querry results Dim i As Integer Dim szine As String If ((x Mod 2) = 0) Then szine = &E5E5E5& Else szine = &FF& Endif Select Case y Case 0 gV.Data.Text = Keress.Name(x) gV.Data.BackGround = szine Case 1 gV.Data.Text = Keress.Volm(x) gV.Data.BackGround = szine Case 2 gV.Data.Text = Keress.Road(x) gV.Data.BackGround = szine Case 3 gV.Data.Text = Keress.Size(x) gV.Data.BackGround = szine Case 4 gV.Data.Text = Keress.When(x) gV.Data.BackGround = szine End Select End Tell me just where to put, and how. I've tried many versions but always resulting with Stack overflow error. Thanks! Csaba 2012/1/22, Benoît Minisini : > Le 21/01/2012 17:48, M. Cs. a écrit : >> Is there a way to force a GridView control with 4 columns to adjust >> the column's width to the content's width? >> >> How would it work with a control which expands or stretches itself >> during maximizing the FMain? >> >> Thanks! >> > > Normally you have to set the column width to -1 to make it adjust its > contents. But I'm not sure that it works with GridView using the Data event. > > Just test and tell me. :-) > > -- > Benoît Minisini > > -- > 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] DB.Quote() doesn't quotes apostrophes
I have a dinamically created query text. I don't know the number of parameters passed to the DB.Exec, so I cannot use &1,&2,... form. I need to use the DB.Quote() My problem is: If I have a string mystring="Blackmore's Night", the DB.Quote(mystring) won't quote the ', so the query will crash. In fact I'm getting query string SELECT * FROM CATALOGS WHERE VName='Blackmore's Night' It occurs with sqlite database. Is there any solution for that? Thanks! Csaba -- 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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] DB.Quote() doesn't quotes apostrophes
Well, that was the thing I was fearing: I must handle the characters by my own. The strange thing is , that if I have something like DB.Exec("SELECT * FROM CATALOGS WHERE VName=&1","Blackmore's Night'") the query won't fail. I can even have query DB.Exec("SELECT * FROM CATALOGS WHERE VName LiKE &1","%'%") and the result won't fail. I wonder why? What's the advance in .Exec over .Quote? I will try Johnny's trick. Thanks! Csaba 2012/1/23, Benoît Minisini : > Le 23/01/2012 00:15, M. Cs. a écrit : >> I have a dinamically created query text. I don't know the number of >> parameters passed to the DB.Exec, so I cannot use&1,&2,... form. I >> need to use the DB.Quote() >> My problem is: If I have a string >> mystring="Blackmore's Night", >> the DB.Quote(mystring) won't quote the ', so the query will crash. In >> fact I'm getting query string >> SELECT * FROM CATALOGS WHERE VName='Blackmore's Night' >> It occurs with sqlite database. >> Is there any solution for that? >> >> Thanks! >> >> Csaba >> > > You must use DB.Subst(), not DB.Quote(). Maybe I said DB.Quote() > somewhere recently, that was a mistake then. > > Anyway you are right: DB.Quote(), which is used for quoting fields or > table names, is unable to quote "'" correctly. But you should not use > such character inside table or field names, so... > > Regards, > > -- > Benoît Minisini > > -- > 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] DB.Quote() doesn't quotes apostrophes
I'm sorry Benoit, but I didn't realized that in "You must use DB.Subst()" the You is me. I was thinking you are answering to Johnny. I'll give a try. Csaba 2012/1/23, Benoît Minisini : > Le 23/01/2012 14:03, M. Cs. a écrit : >> Well, that was the thing I was fearing: I must handle the characters >> by my own. The strange thing is , that if I have something like >> DB.Exec("SELECT * FROM CATALOGS WHERE VName=&1","Blackmore's Night'") >> the query won't fail. >> I can even have query >> DB.Exec("SELECT * FROM CATALOGS WHERE VName LiKE&1","%'%") >> and the result won't fail. I wonder why? What's the advance in .Exec >> over .Quote? >> >> I will try Johnny's trick. >> Thanks! >> >> Csaba >> > > Did you read my mail? > > -- > Benoît Minisini > > -- > 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] DB.Quote() doesn't quotes apostrophes
Hello again: PRINT DB.Subst("WHERE Name = &1 AND Date = &2", "Benoit", Now) WHERE Name = 'Benoit' AND Date = '2006-02-15 11:51:33.043' This is the given example for the DB.Subst. But what if the user has a textBox input in which he can enter the search phrases divided by gaps like: "Benoit .jpg Summer". I don't know what is going to be entered, maybe the text will be: "Benoit .jpg this Summer". How to form a query text using array ["Benoit",".jpg","this","Summer"] as words to be included if I don't know the number of the words until the runtime? I cannot foresee when will the array &1,&2,&3,...stop, so how could I use DB.Subst which operates with a definite number of arguments? I need something to intercept the problematic charactes before they are submitted to DB.Exec, during the formation of search query text. Do you understand my need? I'm not the one who've invented the ' signs in English language but they are present in almost every title or sentence. Thank you! Csaba 2012/1/23, M. Cs. : > I'm sorry Benoit, but I didn't realized that in "You must use > DB.Subst()" the You is me. I was thinking you are answering to Johnny. > I'll give a try. > > Csaba > > 2012/1/23, Benoît Minisini : >> Le 23/01/2012 14:03, M. Cs. a écrit : >>> Well, that was the thing I was fearing: I must handle the characters >>> by my own. The strange thing is , that if I have something like >>> DB.Exec("SELECT * FROM CATALOGS WHERE VName=&1","Blackmore's Night'") >>> the query won't fail. >>> I can even have query >>> DB.Exec("SELECT * FROM CATALOGS WHERE VName LiKE&1","%'%") >>> and the result won't fail. I wonder why? What's the advance in .Exec >>> over .Quote? >>> >>> I will try Johnny's trick. >>> Thanks! >>> >>> Csaba >>> >> >> Did you read my mail? >> >> -- >> Benoît Minisini >> >> -- >> 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] DB.Quote() doesn't quotes apostrophes
I found a way to do, but I didn't understand what Benoit wanted: If I have a query, I can always do the following: Replace "SELECT * FROM CATALOGS WHERE VName=." with "SELECT * FROM CATALOGS WHERE " & DB.Subst("VName=&1",...) & "..." That can solve the problem. I'm sorry but something can be very obvious for you, and not so clear to somebody not involved into Gambas! From the documentation I couldn't tell what is the difference between the quotation used by DB.Exec() and what's the gain from a function like DB.Subst(). This is really a painfull point in the documentations. Thanks anyway! Csaba 2012/1/23, Caveat : > Why not just process one term at a time? > > > Dim conn As Connection > Dim termStr As String > Dim terms As String[] > Dim enteredTerm, escapedTerm As String > > ... > conn = DataAccess.getConnection() > ... > ' Get termStr from the input box > 'termStr = txtQueryInput.Text > > ' Set termStr manually for testing > termStr = "abc def he's fill kill''d fine &1 %2 it's%" > > terms = Split(termStr, " ") > For Each enteredTerm In terms > escapedTerm = DB.Subst("&1", enteredTerm) > ' do something with the escaped term... > ... > Next > > Kind regards, > Caveat > > > -- > 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Gambas3 and ubuntu repositories
deb http://ppa.launchpad.net/nemh/gambas3/ubuntu oneiric main 2012/1/26, Christian DaGeek247 Stephens : > *Hey, when will gambas3 be available on the ubuntu repositories? Or is > there another repository that I can add to my repo list in ubuntu to get it? > * > > -- > *If a packet hits a pocket on a socket on a port,* > *and the bus is interrupted as a very last resort,* > *and the address of the memory makes your floppy disk abort,* > *then the socket packet pocket has an error to report! * > * > * > * **DaGeek247 of http://dageek247.tk/* > -- > 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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] Gambas WebPage
Will it be possible to display a native HTML/PHP code in it like in ... ? Why to depend on ASP? Csaba 2012/1/28, Sebastian Kulesz : > I really like this idea, it makes an application really versatile. > What I think is that before starting to code it you must define some > things. > > First, the security implications. Will real webpages be able to use > that syntax?. A nice feature would be a whitelist of allowed pages > that can be executed within a form, maybe with the include tag. > > Second, and most important. How would you manage to call each event > of a form input object, like a textbox? How could someone use the > value of a textbox, for example? What happens if two form objects have > the same "name" attribute? When an input button is pressed, the user > is normally redirected to the "action" webpage, will you override this > to execute an event and let the user choose? > > Third, about the links. A nice syntax would be > gambas://FormName/Method/Param1/Param2/... > > That's all I could think of. Thanks for all the work!! > > On 28/01/2012, at 07:07, "Benoît Minisini" > wrote: > >> Hi all, >> >> I have started the support of a new kind of "form" in the IDE, the >> "WebPage". >> >> WebPage is an HTML page with ASP-like syntax. It is implemented in the >> gb.web component. >> >> The IDE now can edit WebPage, but cannot compile them. >> >> Actually it is "just" a matter of modyfing the compiler so that the >> WebPage is transformed into Gambas code that generates the final HTML. >> >> At the moment, the following ASP-like syntax will be implemented: >> >> - <% ... %> to insert any Gambas code. >> >> - <%= ... %> to insert the result of a Gambas expression. Html$() will >> be automatically called. >> >> - Maybe something like <%INCLUDE ... %> to include a WebPage in another >> one. >> >> Note that the WebPage is a file with a ".webpage" extension, and that, >> they have their own class file attached (like any form). >> >> That way, you don't have to put all your code inside the HTML. Just what >> is needed. >> >> Internally all WebPages will inherit the WebPage class, and will have a >> "Render" method to render their contents (i.e. print to the standard >> output - don't forget that a Gambas web application is a CGI script!). >> They can be startup class too. >> >> I'd like to have the thoughts of Gambas users about that: what kind of >> syntax you would like, what ideas you have... >> >> One idea I have would be a standard syntax for the URL received by the >> CGI script, so that the displayed WebPage would be automatically >> selected from it. It could be something as simple as >> "http://myapp.com/". >> >> Thanks in advance for your comments. >> >> Regards, >> >> -- >> Benoît Minisini >> >> -- >> 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@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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Disabling the window's buttons on forms
Hello! How could I disable the Maximize, Minimize and Close buttons on a Form? If I used a borderless form, I'm losing the ability of resizing it, and If I use a form with borders, and If I start a Music on this form, it won't stop upon Close button's being pushed. Any idea? Csaba -- 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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] I need your help with Processes
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 -- 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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need your help with Processes
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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need your help with Processes
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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] I need your help with Processes
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@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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] Creating button as class element with variable function
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? -- 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@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user