Re: [Gambas-user] New in Gambas Farm: A gridview with automatic row height

2017-03-16 Thread Michael Layland
Thank you!   This was something on my 'Wish List'  :-)

Michael


On 03/16/2017 03:55 AM, Jorge Carrión wrote:
> Hi
> I've upload to Gambas Farm a new control that I called hGrid (the "h" of
> "Height" and yes, I know that h usually means "handle" but I'm lack of
> imagination, I'm afraid)
>
> Its a control that inherits of GridView with a new boolean property
> "wordWrap". If it is setted to True, the wordWrap property of cells its set
> to true too and the height of the rows is fitted to show all the cell
> contents.
>
> I hope it'll be usefull for someone.
>
>
> ​
>
> Best Regards
>
>
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
> ___
> Gambas-user mailing list
> Gambas-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Unable to create .deb installs for Ubuntu / Mint

2015-11-05 Thread Michael Perryman
Thanks it fixed that problem, but now producing other errors to prevent the
packages being created..  I will investigate those now.

Michael

On 5 November 2015 at 15:26, Benoît Minisini <gam...@users.sourceforge.net>
wrote:

> Le 05/11/2015 16:16, Michael Perryman a écrit :
> > Using the Gambas 3.7 versions on Mint 17.2 I was having no problems,
> > writing, compiling, testing, & creating installation packages for use in
> > Linux Mint 17.2.  A few weeks after installing 3.8 I needed to create an
> > installation package for use with Mint.  It failed to create an
> > installation package.
> >
> > Assuming that there was something wrong with my installation of Mint I
> > first tried reinstalling Mint 17.2, using just the defaults, on an empty
> > disk.  It still would not compile.
> >
> > Next I tried installing Ubuntu 15.10 on an empty disk.  First creating 3
> > partitions for use as "/", swap & home.
> >
> > Other than telling it to use the above disk structure do an default
> install
> > of Ubuntu Mate 15.10, letting it apply all updates during the install.
> >
> > Install Gambas with the following script.
> >
> > #!/bin/bash -vx
> > sudo add-apt-repository ppa:gambas-team/gambas3
> > sudo apt-get update
> > sudo apt-get install gambas3
> >
> > Copy source directory from what was a working program prier to Gambas 3.8
> > into a source directory on the test installation.
> > Create a separate directory in which to put the installation files.
> >
> > Load program and  chose project / compile all.
> >
> > Chose project / make / executable, choosing put shortcut on desktop.
> >
> >   Running the executable that has been placed from the desktop,
> everything
> > works.
> >
> > Now choosing project / make / installation package, & on Target
> > Distribution only ticking Ubuntu / Mint I get the message that I have
> > always had "makepkg is missing".  In addition I now get the 2 messages
> :-
> > autoconf and automake are missing.
> > makeself is missing.
> >
> > I Clicked next on every window until "Destination directory " is
> displayed.
> > Chose the install directory & click next.
> > Next screen click "create package"
> > The following is displayed.
> >
> >
> >
> > Saving CHANGELOG file.
> >
> >
> ==
> >
> > CREATING PACKAGE FOR UBUNTU / KUBUNTU / MINT
> >
> >
> > Making build directory.
> > Creating desktop file...
> > Sources are being debianizated.
> > Creating package...
> > cd
> '/home/michael/data/GambasInstall/GarminTools/ubuntu/garmintools-0.1.12'
> > dpkg-buildpackage -d -rfakeroot -uc -us
> > dpkg-buildpackage: source package garmintools
> > dpkg-buildpackage: source version 0.1.12-0ubuntu2
> > dpkg-buildpackage: source distribution unstable
> > dpkg-buildpackage: source changed by michael <michael@mint-660>
> > sh: 1: gcc: not found
> > dpkg-architecture: warning: couldn't determine gcc system type, falling
> > back to default (native compilation)
> > dpkg-buildpackage: host architecture amd64
> >   dpkg-source --before-build garmintools-0.1.12
> > dpkg-source: error: syntax error in garmintools-0.1.12/debian/control at
> > line 12: line with unknown format (not field-colon-value)
> > dpkg-buildpackage: error: dpkg-source --before-build garmintools-0.1.12
> > gave error exit status 25
> > The package build has failed.
> > Package.MakeDebPackage.991: 'dpkg-buildpackage' has failed.
> > Saving CHANGELOG file.
> >
> > End of CHANGELOG file
> > 
> >
> > Filegarmintools-0.1.12/debian/control  follows.  everything between
> the
> > rows of == The 12th line, said to be an error is part of the
> > Description
> >
> >
> ==
> > Source: garmintools
> > Section: contrib/electronics
> > Priority: optional
> > Maintainer: michael <michael@mint-660>
> > Build-Depends: debhelper (>= 5.0.0), gambas3-dev (>= 3.8), gambas3-dev
> (<<
> > 3.99.0), gambas3-gb-image (>= 3.8), gambas3-gb-image (<< 3.99.0),
> > gambas3-gb-form (>= 3.8), gambas3-gb-form (<< 3.99.0), gambas3-gb-pcre
> (>=
> > 3.8), gambas3-gb-pcre (<< 3.99.0)
> > Standards-Version: 3.9.6
> >
> > Package: garmin

[Gambas-user] Unable to create .deb installs for Ubuntu / Mint

2015-11-05 Thread Michael Perryman
Using the Gambas 3.7 versions on Mint 17.2 I was having no problems,
writing, compiling, testing, & creating installation packages for use in
Linux Mint 17.2.  A few weeks after installing 3.8 I needed to create an
installation package for use with Mint.  It failed to create an
installation package.

Assuming that there was something wrong with my installation of Mint I
first tried reinstalling Mint 17.2, using just the defaults, on an empty
disk.  It still would not compile.

Next I tried installing Ubuntu 15.10 on an empty disk.  First creating 3
partitions for use as "/", swap & home.

Other than telling it to use the above disk structure do an default install
of Ubuntu Mate 15.10, letting it apply all updates during the install.

Install Gambas with the following script.

#!/bin/bash -vx
sudo add-apt-repository ppa:gambas-team/gambas3
sudo apt-get update
sudo apt-get install gambas3

Copy source directory from what was a working program prier to Gambas 3.8
into a source directory on the test installation.
Create a separate directory in which to put the installation files.

Load program and  chose project / compile all.

Chose project / make / executable, choosing put shortcut on desktop.

 Running the executable that has been placed from the desktop, everything
works.

Now choosing project / make / installation package, & on Target
Distribution only ticking Ubuntu / Mint I get the message that I have
always had "makepkg is missing".  In addition I now get the 2 messages  :-
autoconf and automake are missing.
makeself is missing.

I Clicked next on every window until "Destination directory " is displayed.
Chose the install directory & click next.
Next screen click "create package"
The following is displayed.



Saving CHANGELOG file.

==

CREATING PACKAGE FOR UBUNTU / KUBUNTU / MINT


Making build directory.
Creating desktop file...
Sources are being debianizated.
Creating package...
cd '/home/michael/data/GambasInstall/GarminTools/ubuntu/garmintools-0.1.12'
dpkg-buildpackage -d -rfakeroot -uc -us
dpkg-buildpackage: source package garmintools
dpkg-buildpackage: source version 0.1.12-0ubuntu2
dpkg-buildpackage: source distribution unstable
dpkg-buildpackage: source changed by michael <michael@mint-660>
sh: 1: gcc: not found
dpkg-architecture: warning: couldn't determine gcc system type, falling
back to default (native compilation)
dpkg-buildpackage: host architecture amd64
 dpkg-source --before-build garmintools-0.1.12
dpkg-source: error: syntax error in garmintools-0.1.12/debian/control at
line 12: line with unknown format (not field-colon-value)
dpkg-buildpackage: error: dpkg-source --before-build garmintools-0.1.12
gave error exit status 25
The package build has failed.
Package.MakeDebPackage.991: 'dpkg-buildpackage' has failed.
Saving CHANGELOG file.

End of CHANGELOG file


Filegarmintools-0.1.12/debian/control  follows.  everything between the
rows of == The 12th line, said to be an error is part of the
Description

==
Source: garmintools
Section: contrib/electronics
Priority: optional
Maintainer: michael <michael@mint-660>
Build-Depends: debhelper (>= 5.0.0), gambas3-dev (>= 3.8), gambas3-dev (<<
3.99.0), gambas3-gb-image (>= 3.8), gambas3-gb-image (<< 3.99.0),
gambas3-gb-form (>= 3.8), gambas3-gb-form (<< 3.99.0), gambas3-gb-pcre (>=
3.8), gambas3-gb-pcre (<< 3.99.0)
Standards-Version: 3.9.6

Package: garmintools
Architecture: all
Depends: gambas3-runtime (>= 3.8), gambas3-runtime (<< 3.99.0),
gambas3-gb-image (>= 3.8), gambas3-gb-image (<< 3.99.0), gambas3-gb-form
(>= 3.8), gambas3-gb-form (<< 3.99.0), gambas3-gb-pcre (>= 3.8),
gambas3-gb-pcre (<< 3.99.0)
Description: 0.1.0
GPS data processing for navagation
gpx merge file correctl...
 0.1.0
GPS data processing for navagation
gpx merge file correctly forated
 This program is written in Gambas.
 
====

Does anyone know why this is failing & how to fix the problem.

Many thanks

Michael





System Information created by Gambas

[System]
Gambas=3.8.2
OperatingSystem=Linux
Kernel=4.2.0-16-generic
Architecture=x86_64
Distribution=Ubuntu 15.10
Desktop=MATE
Theme=Gtk
Language=en_GB.UTF-8
Memory=7887M

[Libraries]
Cairo=libcairo.so.2.11400.2
Curl=libcurl.so.4.3.0
DBus=libdbus-1.so.3.14.3
GStreamer=libgstreamer-0.10.so.0.30.0
GStreamer=libgstreamer-1.0.so.0.600.0
GTK+2=libgtk-x11-2.0.so.0.2400.28
GTK+3=libgtk-3.so.0.1600.7
OpenGL=libGL.so.1.2.0
Poppler=libpoppler.so.52.0.0
QT4=libQtCore.so.4.8.6
QT5=libQt5Core.so.5.4.2
SDL=libSDL-1.2.so.0.11.4

[Environment]
CLUTTER_BACKEND=x11
COMPIZ_CONFIG_PROFILE=mate

[Gambas-user] Balloon.Info on TrayIcon

2015-02-11 Thread Michael A. Capone
Hi folks,

First of all, a big THANK YOU for the creation of Gambas!  It has 
allowed us to port legacy VB code to linux and get several of our users 
off the Windows platform.

I've searched everywhere for this, and seen several requests, but no 
satisfactory answer.

Is there any way to implement a Balloon message that can be attached to 
a tray icon?  This is common functionality that is seen in many 
applications.  Unfortunately, TrayIcons are Classes, not Controls, 
so when you call

Balloon.Info(Hello World, myTrayIcon)

... you get the error Expected 'Control', got 'TrayIcon'.

I've found this question in mailing lists going back to 2008, but no 
answer.

My workaround is to render a small form in the lower right hand corner 
of the screen, put a tiny label on the tiny form, and have that label be 
the Control that the balloon attaches to.  A timer then closes the form 
after a few seconds.

The problem with that solution is that the newly rendered form steals 
focus from whatever application is currently running.  So if I'm typing 
away in an e-mail, and my miniature balloon form loads, my e-mail client 
loses focus.

I'm using gb.qt on Gambas 3.5.0; QT certainly has support for this 
(http://qt-project.org/doc/qt-4.8/desktop-systray.html), although I'll 
admit I know next to nothing about QT programming.  But is this a 
feature that can be built into the TrayIcon class, perhaps in the form 
of TrayIcon.Balloon.Info?  Or, is there a way to do that that I'm not 
familiar with yet?

Thanks so much!
Michael

--
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] 'GTK_IS_WIDGET (widget)' failed Only after installing Gambas3.6.0

2014-10-17 Thread Michael Perryman
This afternoon I saw Gambas 3.6.0 available as as an update,  installed it.

My program was working without problems using Gambas 3.5.

It has a form with 4 text labels, 4 test boxes, 2 buttons,  a progress bar.

As soon as the form loads I get the following error message in the
console.  The message can only be cleared by closing  reopening Gambas.


(FindWptsGUI:2758): Gtk-CRITICAL **: IA__gtk_widget_get_direction:
assertion 'GTK_IS_WIDGET (widget)' failed


Once it has occurred if I drag the window border to resize it, the same
message repeats a very large number of times.

I tried loading an old version from backup so as to ensure that I had not
accidentally changed the program.
The old version showed exactly the same error message.

1)Has anyone else had the problem?

2)As this appears to be a GTK problem, does anyone have any idea how I
can resolve the problem.

[System]
Gambas=3.6.0
OperatingSystem=Linux
Kernel=3.13.0-24-generic
Architecture=x86_64
Distribution=Linux Mint 17 Qiana
Desktop=MATE
Theme=QGtk
Language=en_GB.UTF-8
Memory=7863M
[Libraries]
Cairo=libcairo.so.2.11301.0
Curl=libcurl.so.4.3.0
DBus=libdbus-1.so.3.7.6
GStreamer=libgstreamer-0.10.so.0.30.0
GStreamer=libgstreamer-1.0.so.0.204.0
GTK+3=libgtk-3.so.0.1000.8
GTK+=libgtk-x11-2.0.so.0.2400.23
OpenGL=libGL.so.1.2.0
Poppler=libpoppler.so.44.0.0
Qt4=libQtCore.so.4.8.6
SDL=libSDL-1.2.so.0.11.4
--
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Webview editing problem

2013-12-02 Thread Michael Hart
On 29/11/13 09:39, michael wrote:
 I have written a small project which is intended to test editing an html page 
 (I would like to create a wysiwyg markdown editor). I have attached a copy. I 
 am having trouble with editing the html programattically 
 (http://gambasdoc.org/help/comp/gb.qt4.webkit/webview?v3, using the Eval 
 method to run the JavaScript document.execCommand). I have copied the 
 relevant code from the supplied WebBrowser project, and sending the Cut 
 command works in the WebBrowser project but not in mine. Sending the Bold or 
 Delete command does work in mine, using the keyboard to edit the html does 
 work in mine (eg Ctrl C, typing etc.).
 I am using Debian 7 Gnome, with Gambas 3.4.1 which I installed from source 
 (the repo version 3.1.1 is too old for another program I have written).
 Any Ideas ?

 Thank you
 Michael.  

No reply yet, it has been a while ?? But I have found the solution, by 
going through the WebBrowser example and commenting out the lines I 
didn't need, one line or Sub at a time. What is needed was the line

   WebSettings[WebSettings.JavascriptCanAccessClipboard] = True

in the Form_Open() Sub.

This allows me to click on the cut button which executes the command


document.execCommand('Cut', false, false)


This makes sense, since the WebView help page says using the Eval 
method to run the JavaScript document.execCommand) however it isn't 
stated on the WebView help page that you need to enable this. I think 
that such a statement would be a good idea.

Michael
--
Rapidly troubleshoot problems before they affect your business. Most IT 
organizations don't have a clear picture of how application performance 
affects their revenue. With AppDynamics, you get 100% visibility into your 
Java,.NET,  PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351iu=/4140/ostg.clktrk
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] Webview editing problem

2013-11-28 Thread michael
I have written a small project which is intended to test editing an html page 
(I would like to create a wysiwyg markdown editor). I have attached a copy. I 
am having trouble with editing the html programattically 
(http://gambasdoc.org/help/comp/gb.qt4.webkit/webview?v3, using the Eval method 
to run the JavaScript document.execCommand). I have copied the relevant code 
from the supplied WebBrowser project, and sending the Cut command works in the 
WebBrowser project but not in mine. Sending the Bold or Delete command does 
work in mine, using the keyboard to edit the html does work in mine (eg Ctrl C, 
typing etc.).
I am using Debian 7 Gnome, with Gambas 3.4.1 which I installed from source (the 
repo version 3.1.1 is too old for another program I have written).
Any Ideas ?

Thank you
Michael.  

Gambas3_HtmlEditor.tar.gz
Description: GNU Zip compressed data
--
Rapidly troubleshoot problems before they affect your business. Most IT 
organizations don't have a clear picture of how application performance 
affects their revenue. With AppDynamics, you get 100% visibility into your 
Java,.NET,  PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349351iu=/4140/ostg.clktrk___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] Paint an image

2013-11-24 Thread Michael Kuyumcu
Dear list members,

in my program I seemingly cannot get an image to be painted.

I have a DrawingArea called fr.
In memory I keep an image named img.


In my form code, I declare
public img as image

In the Form_Open handler, I instantiate img with
img = New Image(fr.Width, fr.Height)

In some other code that is then run, I fill the x/y pixels of img with
integer values
img[x,y] =  some integer 


Then I issue a fr.Refresh command, hoping fr would display


 Public Sub fr_Draw()
   Paint.Begin(fr)
   fr.Cached = True
   fr.Background = Color.RGB(100, 140, 180)

   Paint.Image(img, 0, 0) ???
  
   paint.End

 End


In the line containing the ???, I have tried many variations of code
to make img appear in the fr DrawingArea, all without success.
The background color, however, is displayed correctly.

What do I have to write in place of ??? to make img display?

Thank you.

Regards,
ukimiku


--
Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing 
conversations that shape the rapidly evolving mobile landscape. Sign up now. 
http://pubads.g.doubleclick.net/gampad/clk?id=63431311iu=/4140/ostg.clktrk
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] ARM debugging - where to start?

2011-09-08 Thread Joe Michael
On Tue, 2011-09-06 at 13:12 +0200, Benoît Minisini wrote:

  Hi,
  
  I have an ARM based Genesi Smarttop unit which runs Ubuntu 10.10 and it
  has Gambas version 2. When Gambas starts up gbx2 runs, consumes all
  resources
  in a big loop. If I start with it in command line, I get no output -
  zip. No clues what
  could be going on. I left a message in their forum
  http://www.powerdeveloper.org/forums/viewtopic.php?t=2042
  but no response for some weeks now.
  
  So it looks like I have an excuse to go from being a big fan of Gambas
  to an even
  bigger fan and help debug  :-)
  
  Bearing in mind this is ARM platform, and I don't know first thing about
  gamabas
  development, what is the first things I should do?
  Please be explicit with syntax for use of commands and parameters to be
  sent
  to get some debug messages and results, as I won't be able to
  second guess what is being suggested.
  
  I am familiar with C (skill rating 9/10), C++ (4/10), using gambas
  (8/10).
  
  
  Thanks.
  
  JM
  
 
 Gambas 2 already runs some project on ARM, but two ARM computers are well-
 known to be very different!
 
 Go to the directory of the Gambas 2 project you want to run, and use the 
 debugger. Hit CTRL+C to stop it when it loops, and send me the backtrace.
 
 $ cd /path/to/my/gambas/project
 $ gdb gbx2
 ...
 (gdb) run
 ...
 ^C
 (gdb) bt
 ...
 
 Please try to compile the latest version of gambas, and with debugging 
 information enabled. Try to compile with and without optimization too, to see 
 if something changes.
 
 Regards,
 


Results of running gdb: 
--- 

~/code/gambas/app1$ gdb gbx2 
GNU gdb (GDB) 7.2-ubuntu 
Copyright (C) 2010 Free Software Foundation, Inc. 
License GPLv3+: GNU GPL version 3 or later
http://gnu.org/licenses/gpl.html 
This is free software: you are free to change and redistribute it. 
There is NO WARRANTY, to the extent permitted by law. Type show
copying 
and show warranty for details. 
This GDB was configured as arm-linux-gnueabi. 
For bug reporting instructions, please see: 
http://www.gnu.org/software/gdb/bugs/... 
Reading symbols from /usr/bin/gbx2...(no debugging symbols
found)...done. 
(gdb) run 
Starting program: /usr/bin/gbx2 
[Thread debugging using libthread_db enabled] 
^C 
Program received signal SIGINT, Interrupt. 
0x0001850a in ?? () 
(gdb) bt 
#0 0x0001850a in ?? () 
#1 0x0001ee68 in ?? () 
Backtrace stopped: previous frame identical to this frame (corrupt
stack?) 
(gdb)

[Will also try compiling gb3 as suggested over next few days to see if
it
adds any new information, and post results. Thnx.]
__
This message has been checked for viruses and spam by Corpex using
the ArmourPlate Anti Virus and Anti Spam Scanning Service.
To find out more and see our email archiving service see
http://www.armourplate.com or call Corpex on UK 0845 050 1898.
--
Doing More with Less: The Next Generation Virtual Desktop 
What are the key obstacles that have prevented many mid-market businesses
from deploying virtual desktops?   How do next-generation virtual desktops
provide companies an easier-to-deploy, easier-to-manage and more affordable
virtual desktop model.http://www.accelacomm.com/jaw/sfnl/114/51426474/
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] ARM debugging - where to start?

2011-09-06 Thread Joe Michael
Hi,

I have an ARM based Genesi Smarttop unit which runs Ubuntu 10.10 and it
has Gambas version 2. When Gambas starts up gbx2 runs, consumes all
resources
in a big loop. If I start with it in command line, I get no output -
zip. No clues what 
could be going on. I left a message in their forum
http://www.powerdeveloper.org/forums/viewtopic.php?t=2042
but no response for some weeks now.

So it looks like I have an excuse to go from being a big fan of Gambas
to an even
bigger fan and help debug  :-)

Bearing in mind this is ARM platform, and I don't know first thing about
gamabas
development, what is the first things I should do?
Please be explicit with syntax for use of commands and parameters to be
sent
to get some debug messages and results, as I won't be able to
second guess what is being suggested.

I am familiar with C (skill rating 9/10), C++ (4/10), using gambas
(8/10).


Thanks.

JM




__
This message has been checked for viruses and spam by Corpex using
the ArmourPlate Anti Virus and Anti Spam Scanning Service.
To find out more and see our email archiving service see
http://www.armourplate.com or call Corpex on UK 0845 050 1898.
--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Font in the add breakpoint textbox

2011-03-13 Thread Michael
I can't find this textbox. I have a Toggle Breakpoint menu and a Tooltip 
but no text box. AM I missing something?

Michael


On 13/03/11 22:22, richard terry wrote:
 Meaning to ask this for a while - the font in this text box is quite small on
 my machine - is it my machine or is it set that small?

 Regards

 Richard

 --
 Colocation vs. Managed Hosting
 A question and answer guide to determining the best fit
 for your organization - today and in the future.
 http://p.sf.net/sfu/internap-sfd2d
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] displaying mysql query result into gridview

2011-03-11 Thread Michael
Nugroho,
Sorry, I just cut and pasted some existing code. You can delete the 
reference to

LoadChargeCombos. This is a local routine to populate some combo boxes.
The rest of your code should work fine.

Best Wishes
Michael


On 12/03/11 13:35, Nugroho Al Gopar wrote:
 Hi Michael

 I've try to use your script replied to me in my program. But I need few
 explanations.
 1. Where should I put the code? It is something like bellow?
 
 ' Gambas class file

 PRIVATE SUB PopulateCharges()
DIM rsCharges AS Result
DIM intRow AS Integer = 0
DIM strType AS String = 

sql.getSQL  'for connect to database
rsCharges = sql.$hConn.Exec(SELECT * FROM makul) 'executing query
IF rsCharges.Available THEN
rsCharges.MoveFirst
GridView1.Rows.Count = rsCharges.Count
FOR EACH rsCharges
GridView1[intRow, 0].Text = rsCharges!unique_id
GridView1[intRow, 1].Text = rsCharges!charge_source
GridView1[intRow, 2].Text = rsCharges!charge_type
  'rsCharges!charge_display
INC intRow
NEXT
sql.UpdateStatus(rsCharges.Count   Charge records returned
 )
   LoadChargeCombos(rsCharges)
   GridView1.Row = intRow - 1
   ENDIF
   CATCH
   Message.Error(Error.Class.Name  :   Error.Where  : 
   Error.Text)
 END

 PUBLIC SUB Form_Open()

PopulateCharges()

 END

 
 2. LoadChargeCombos is detected as unknown identifier in my program. Is
 it a procedure you have. If it is, please let me know the script.

 Thanks.


 --
 Colocation vs. Managed Hosting
 A question and answer guide to determining the best fit
 for your organization - today and in the future.
 http://p.sf.net/sfu/internap-sfd2d
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] displaying mysql query result into gridview

2011-03-09 Thread Michael
NUgroho,
Here is code from one of my projects:
Private Sub PopulateCharges()
 Dim intRow As Integer = 0
 Dim strType As String = 

 If rsCharges.Available Then
 rsCharges.MoveFirst
 grdCharge.Rows.Count = rsCharges.Count
 For Each rsCharges
 grdCharge[intRow, 0].Text = rsCharges!unique_id
 grdCharge[intRow, 1].Text = rsCharges!charge_source
 grdCharge[intRow, 2].Text = rsCharges!charge_type
 grdCharge[intRow, 3].Text = rsCharges!charge_start
 grdCharge[intRow, 4].Text = rsCharges!charge_end
 grdCharge[intRow, 5].Text = 
rsCharges!charge_display
 Inc intRow
 Next
 modMain.UpdateStatus(rsCharges.Count   Charge records 
returned)
 LoadChargeCombos(rsCharges)
 grdCharge.Row = intRow - 1
 Endif
 Catch
 Message.Error(Error.Class.Name  :   Error.Where  :  
 Error.Text)
End

I assume you have got your recordset (rsCharges) from the Db. You ned to 
check how many rows are need in the grid and set this. Then populate 
each row and column as above.

Regrads
Michael Davies


On 10/03/11 15:36, Nugroho Al Gopar wrote:
 I have learn how to connect mysql through gambas and make simple query
 like select * from table.

 My problem is, i can not display the results inti gridview or table
 view. I've try many codes style, include the code written in ebook
 titled gambas-beginner-guide, but none is works. I put the code in my
 attachment. they are two different projects.

 I would like to display data from mysql table named makul. Here is the
 structure:
 kode int(2) auto_increment not null primary key,
 nama varhcar(50),
 sks int(2)

 the table has 5 records.

 Please help me solve the problem. I use this for my graduation.

 regard,

 Nugroho


 --
 Colocation vs. Managed Hosting
 A question and answer guide to determining the best fit
 for your organization - today and in the future.
 http://p.sf.net/sfu/internap-sfd2d


 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user

--
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] dumb date question

2011-02-28 Thread Michael
If dt1  dt2 then
do something
end if

Dates are stored as numbers. The most recent date will be the largest 
number.

Regards
Michael


On 01/03/11 14:10, richard terry wrote:
 I never can figure out the simple things

 If I have 2 dates and want to find if one is more recent than the other, what
 would be the syntax?

 Regards

 Richard

 --
 Free Software Download: Index, Search  Analyze Logs and other IT data in
 Real-Time with Splunk. Collect, index and harness all the fast moving IT data
 generated by your applications, servers and devices whether physical, virtual
 or in the cloud. Deliver compliance at lower cost and gain new business
 insights. http://p.sf.net/sfu/splunk-dev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
Free Software Download: Index, Search  Analyze Logs and other IT data in 
Real-Time with Splunk. Collect, index and harness all the fast moving IT data 
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business 
insights. http://p.sf.net/sfu/splunk-dev2dev 
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] gb.db.form driver missing

2011-02-16 Thread Michael
Tobias,
I am presuming this form is your startup class, in which case you are 
trying to utilise the Db Connector before your resources are fully 
loaded. It might not happen if you use this code in a form lower in the 
hierarchy.
Personally I keep all Db access in a separate class called data which 
handles all communication with the database. I then start my apps with a 
Main module not a form. The Main module will load resources (such as 
Db Connector), test the Db connection, check password etc, and only then 
load the first form in the hierarchy.
Hope this helps.

Again, a personal preference, but my top level form is always just to 
hold a menu and a status bar. Any actions are being handled by creating 
sub-forms for each menu. This pretty well ensures that the main form is 
loaded before any errors are generated and it gives you a template to 
create a main menu form for any future projects.

Regards
Michael


On 17/02/11 07:43, tobias wrote:
 good evening,
 i'm testing gb.db.form for some time now and got some confusing (in fact
 it is not that confusing, i can imagine the situation): i have a simple
 form form-datasource-databrowser
 and my code is as follows:

 PUBLIC hConn AS NEW Connection

 PUBLIC SUB Form_Open()

 hConn.Type = ...
 hConn.Name = ...
 hConn.Host = ...
 hConn.Open()

 END

 and this results in an error driver missing even before Form_Open() is
 raised, right? if i change the code to initialize the connection in
 Form_Open() everything works... i don't know if it is much trouble to
 change this behavior and i don't think it is neccessary but i haven't
 found anything about this. i think to make a notice or something in the
 Database example would save people some time of figuring this out?

 regards,
 tobi

 --
 The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
 Pinpoint memory and threading errors before they happen.
 Find and fix more than 250 security defects in the development cycle.
 Locate bottlenecks in serial and parallel code that limit performance.
 http://p.sf.net/sfu/intel-dev2devfeb
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] svn automation scripts

2011-01-30 Thread Michael
John,
here is a list of commands which somebody gave me as a newbie. It just 
gets the updates not the whole source code.

sudo -i
cd trunk
svn update
./reconf
./configure -C
make

Regards
Michael


On 31/01/11 13:57, John Spikowski wrote:
 List,

 I'm a little late to the party but excited by how much progress Gambas
 has made since my first introduction around 1.7.

 I'm also rather new to using svn as a tool to keep in sync with the dev
 team of such a large project. What is a reasonable method of updating
 your local trunk and doing another recompile?

 Is there a way to minimize the build time involved other than the -C for
 configure?

 In a perfect world, I would like to have a script that checks to see if
 there have been any updates and if so continue with an auto build of
 Gambas 3. I would also like to have a log of any warnings so I don't
 have to read through pages of redirected compiler output searching for
 them.

 If you have something like this already built and willing to share, it
 would save me from recreating another wheel.

 John


 --
 Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
 Finally, a world-class log management solution at an even better price-free!
 Download using promo code Free_Logger_4_Dev2Dev. Offer expires
 February 28th, so secure your free ArcSight Logger TODAY!
 http://p.sf.net/sfu/arcsight-sfd2d
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] ListView with spaces help

2011-01-29 Thread Michael
SInce a SHELL command must exclude spaces then put it into your listview 
without spaces. If you want to include spaces for readability then 
remove them when you pass to SHELL:
ListView.Current.text.Replace( , )

Regards
Michael


On 30/01/11 06:17, Nicolas Koch wrote:
 I have a populated ListView and I want to run commands from the list, but
 the list items with spaces won't work in SHELL or EXEC.

 Message.Info(ListView.Current.Text) will return the list item with spaces as
 it should ie. this is test

 however when I go to

 EXEC [ListView.Current.Text]
 or
 SHELL ListView.Current.Text

 only this will show up in SHELL or EXEC and not this is test


 How do I get ListView.Current.Text to keep the spaces when I EXEC or SHELL?



 code:

 PUBLIC SUB Run_Click()

Message.Info(ListView.Current.Text)

*' EXEC [ListView.Current.Text]*

SHELL (ListView.Current.Text)

 END


--
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Further news on valuebox bugs in Gambas3

2011-01-21 Thread Michael
Interesting. I could not reproduce in a separate project so I had to 
investigate further. I did file comparisons on the 2 projects and 
discovered that if you set the value of Expand to TRUE then the 
calendar appears. Set it to FALSE and it disappears.
I'm not sure if this is an intended feature or a bonus but it is 
certainly handy and worth documenting. This option was just what I was 
looking for.

Regards
Michael


On 22/01/11 02:32, Benoît Minisini wrote:
 Thanks Benoit,
 This is a great improvement. There is only 1 point I don't understand. I
 enclose 2 screenshots. DateBox2.png shows 2 value boxes in an hbox and
 they have a calendar option. If I cut the datebox and paste it outside
 the hbox then the calendar disappears.
 DateBox1.png shows a value box(Payment date) set to type Date in a
 vbox and it does not display a calendar. If I move it to a panel it
 still does not show a calendar.
 It means the interface lacks consistency.

 Regards
 Michael

 gb.gtk bugs for sure... Can you send me a project with these forms?


--
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires 
February 28th, so secure your free ArcSight Logger TODAY! 
http://p.sf.net/sfu/arcsight-sfd2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Difference in SpinBox behavior between gb.gtk gb.qt

2011-01-06 Thread Michael
Vikram,
As a workaround you could check the Spinbox.Keydown event and ignore 
keys if they take the value above 100

Regards
Michael


On 06/01/11 17:51, vikram wrote:
 Hi,

 The SpinBox control when used in an application using the gb.gtk component 
 allows the user to input values that are larger than it's MaxValue property. 
 Say the MaxValue for a SpinBox is 100, the user can enter 999 and click the 
 button to move to the next form, the SpinBox now automatically changes the 
 value to 100. This is good because junk values won't get saved, but the 
 problem is that there is no way of extracting the value with SpinBox.Value to 
 show the user an error message that the value he wanted(999) is not valid!

 If on the other hand the application uses the gb.qt component the user cannot 
 enter any value greater than 100, the SpinBox control wouldn't let him! Is 
 there anyway the same can be achieved in applications using the gb.gtk 
 component?

 Regards,
 Vikram Nair







 --
 Learn how Oracle Real Application Clusters (RAC) One Node allows customers
 to consolidate database storage, standardize their database environment, and,
 should the need arise, upgrade to a full multi-node Oracle RAC database
 without downtime or disruption
 http://p.sf.net/sfu/oracle-sfdevnl


 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user
--
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] New MaskBox control

2011-01-06 Thread Michael
Thanks Jussi,
This solves all my problems. The MaskBox works fine and the problem I 
had with setting page orientation is solved.
I never knew you had to delete the old installation, I thought the MAKE 
command would overwrite old files. I got my install scripts from the 
internet and nobody thought to mention that the old version needed to be 
deleted first.
Thanks again;-)

Regards
Michael


On 06/01/11 23:43, Jussi Lahtinen wrote:
 Did you delete old installation?

 My compilation script:

 #!/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
 ./reconf-all  ./configure -C  make  sudo make install
 sudo -k

 Jussi



 On Thu, Jan 6, 2011 at 04:36, Michaelmdavi...@tpg.com.au  wrote:

 Benoit,
 Great Idea. I have installed version 3447 and confirmed this with svn
 -info but I cannot find the MaskBox in the toolbox. This may be my lack
 of Linux. I have installed with:
 cd trunk
 svn update
 ./reconf
 ./configure -C
 make

 When I look at the properties of file /usr/local/bin/gbx3 it has a
 modified date of 2nd Dec 2010. Is this correct? Is there a step in the
 installation that I have missed?

 Regards
 Michael


--
Gaining the trust of online customers is vital for the success of any company
that requires sensitive data to be transmitted over the Web.   Learn how to 
best implement a security strategy that keeps consumers' information secure 
and instills the confidence they need to proceed with transactions.
http://p.sf.net/sfu/oracle-sfdevnl 
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] New MaskBox control

2011-01-05 Thread Michael
Benoit,
Great Idea. I have installed version 3447 and confirmed this with svn 
-info but I cannot find the MaskBox in the toolbox. This may be my lack 
of Linux. I have installed with:
cd trunk
svn update
./reconf
./configure -C
make

When I look at the properties of file /usr/local/bin/gbx3 it has a 
modified date of 2nd Dec 2010. Is this correct? Is there a step in the 
installation that I have missed?

Regards
Michael


On 06/01/11 04:12, Benoît Minisini wrote:
 Hi,

 As an intermediate goal before rewriting the ValueBox control, I have
 implemented a MaskBox control, that is a TextBox with a mask.

 How does it work ?

 By setting the mask property, you define which characters are non-editable
 separators, and which characters can be entered by the user

 At the moment, the following mask characters are implemented:

 '9' : any digit.
 '0' : any digit, with '0' as default
 '6' : any hexdecimal character
 'A' : any letter ('A'-'Z' and 'a'-'z')
 '?' : any character.

 Every other character is a separator. If you want to use a mask character as
 separator, use the '\' escape character.

 Examples:

   To enter a date, set Mask to 00/00/.
   To enter an IP address,set Mask to 999.999.999.999
   To enter a french currency, set Mask to 999 999 990,00 €

 Make remarks and enjoy it!

 Regards,


--
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] Further news on valuebox bugs in Gambas3

2010-12-31 Thread Michael
I reported bugs when a date valuebox is housed in a Vbox. I then moved 
all my controls to a Panel and got the same problems if the 
Panel.Arrangement was set to Vertical.
I then moved all Valueboxes to a Frame and got no problems. Obviously 
the Frame does not have an Arrangement property.

One further clue. When overcoming the problems, by using a Frame or by 
setting .Arrangement to NONE in Vbox or Panel, the datePicker disappears 
from the ValueBox.

Hope this helps.

-- 
Regards
Michael


--
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] More on Print bugs.

2010-12-31 Thread Michael
Benoit,
I have investigated print problems further and posted following question 
on Ubuntu One website. It would appear to be a Ubuntu problem not a 
Gambas problem.

There are many different Print dialogs but one is very common and is 
used by Gimp, Shutter, Evloution and Simple Scan. In all these apps the 
Page Size and Orientation are disabled. The same dialog in Firefox, 
Thunderbird and GEdit works OK. I program in Gambas3 which uses this 
dialog in conjunction with the GTK+ library and it also has these 
options disabled. If I use the QT4 library then a different print dialog 
is displayed with no problems. Anybody else notice this problem and 
found a solution?

-- 
Regards
Michael


--
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Porting Gambas 2 projects to Gambas 3

2010-12-29 Thread Michael
When going to this link I get This documentation page does not exist in 
version 2.0.

Regards
Michael


On 25/12/10 01:07, Fabien Bodard wrote:
 the good link is : http://gambasdoc.org/help/doc/gb2togb3




--
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas 3 advancement

2010-12-29 Thread Michael
I have done more experimentation with a date Valuebox. If Expand is 
set to false then no major problem but if the Valuebox is housed in a 
container which resizes it's children and Expand is set to True then 
the text is not visible.
You can make it visible by having a large Height value and you will 
see the text bottom aligned. If you now reduce the height of the 
container in live mode then the text will remain visible.

Regards
Michael


On 20/12/10 03:58, Benoît Minisini wrote:
 Hi,

 I have currently the feeling that I have to correctly fix the ValueBox
 problem (the way it is implemented, and more generally the way compound
 controls raise events), and then I will able to make a release candidate of
 Gambas 3.

 Tell me the important things I forgot, because I am sure I have forgotten
 things.

 Not the small bugs, but the features that may change the language syntax or
 the interface of some components.

 Thanks in advance!


--
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas3 Printing

2010-12-29 Thread Michael
Benoit,
Have you managed to look at the GTK+ printer dialog problems?
With further testing I set the orientation to Landscape in code and 
the paper was correctly oriented. IE The long edge was horizontal but 
the Paint.Width and Paint.Height did not change so the printing was 
truncated in width to 210mm (on A4 paper).
Also if I set my printer defaults to Landscape this did not affect the 
printer dialog. Orientation was still Portrait and disabled. Other 
defaults, such as quality or Double Sided, could be changed in 
printer setup and correctly reflected in the Gambas printer dialog.

Regards
Michael


On 05/12/10 03:06, Benoît Minisini wrote:
 Hi Fabien,
 I've got printing to work ok but positioning objects on the page is
 difficult compared to Gambas2. The Paint.Width and Paint.Height values
 seem to bear no relation to pixels or mm. On A4 paper I get values of
 559 and 760 approx. What units are used here? (My printer resolution is
 300) Also in the hPrinter.Configure() dialog I cannot set all the printer
 options, specifically 'Orientation' is disabled. I set it in code with
 hPrinter.Orientation = Printer.Landscape but the Paint component still
 outputs in Portrait mode.
 Would appreciate any assistance.
 Regards
 Michael

 The Printing example comes from Gambas 2. I removed it as it does not work
 anymore with Gambas 3. If Timothy wants to port it to Gambas 3, he's welcome!

 You should do all your drawings relatively to Paint.Width and Paint.Height,
 whatever their values. See it as a number of pixels, even if it is not
 necessarily true. They are floating point values, so they don't have to be
 true pixels.

 The unit of an horizontal pixel is the width of the paper divided by
 Paint.Width. For an A4 paper on Portrait mode, it's 21 cm / Paint.Width.

 The unit of a vertical pixel is the height of the paper divided by
 Paint.Height. For an A4 paper on Portrait mode, it's 29,7 cm / Paint.Height.

 I will fix one GTK warning in next revision. But I have another one that is
 not triggered by Gambas, but by a GTK+ internal library named libappmenu.so.
 I don't know what it is.

 As you, when calling the GTK+ printer configuration dialog, I cannot change
 the orientation and the paper size. I don't know why! I must investigate...

 And there is another bug in gb.qt4 printing: the font size is not resolution
 independant, whereas it should be the contrary according the documentation
 (i.e. a 50 points font is very small, as if its height is actually 50
 pixels.). I must investigate too...

 Regards,


--
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] What has happened to ValueBox

2010-12-18 Thread Michael
Benoit,
Here is more information to help you rewrite the valuebox. I had a 
ValueBox set to date and it was in a VBox. If I set the Expand 
property to TRUE then I could never see the text. If I set Expand to 
False then it was ok. I experimented with resizing the form and found 
that the text was disappearing off the bottom. It appears not to like a 
ValueBox.Height  24.
Also if I set Expand to False the DatePicker did not appear on the 
ValueBox even though the ValueBox.Width was quite large. If I enlarged 
the form it appeared. Then I closed the form to it's original size and 
the DatePicker remained visible.
If it was possible it would be nice to have a property to hide the 
DatePicker. I personally find these a nuisance in a production 
environment. Users can type a date much quicker. The ValueBox in Gambas 
2 was perfect in this regard.

Regarding your suggestion to use the LAST.Parent to get the object name. 
I am attaching a screenshot of the properties of the LAST Valuebox. You 
will see it shows name as TextBox and Parent as Panel. I shall wait 
for the revised version.
ValueBox.png

Regards
Michael


On 18/12/10 04:24, Benoît Minisini wrote:
 Benoit,
 On the line Dim txtTemp as Valuebox = LAST I get an error Expecting
 valuebox got textbox But the last control was a valuebox.
 It works if I change the code to Dim txtTemp as Textbox even though it
 is not a textbox firing the event.
 OK I see!

 The ValueBox of Gambas 2 inherits TextBox, and so when it raises events, LAST
 is always a ValueBox.

 The current ValueBox of Gambas 3 is actually a compound control (it inherits
 UserControl), with a edit control inside that can be a TextBox or another
 control. Events raised by the edit control are propagated as if the ValueBox
 raise it. But then LAST is the read TextBox, not the ValueBox.

 Moreover, the code of that ValueBox is somewhat dirty. So I plan to rewrite it
 differently, and makes it inheriting TextBox again, or find a way to propagate
 events and keep LAST to be the ValueBox.

 Sorry for the inconvenience. It will disappear when the ValueBox will be
 rewritten.

 As a workaround, you can check the type of LAST. And when it is a TextBox,
 take its parent to get the ValueBox.

 Regards,

 Then I cannot read the name that I assigned to the valuebox.
 txtTemp.Name just returns Textbox.

 I tried replacing the valuebox with a DateBox but this appears to have a
 bug. I can set the value of the DateBox in code and it displays
 correctly. I can pick a value from the DatePicker and it displays
 properly. But it does not have a .Text property to read so I read the
 .Value property and it always returns 00:00:00
 Maybe another bug then. I will investigate.

 Regards,

--
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] What has happened to ValueBox

2010-12-17 Thread Michael
In Gambas 2 I had a number of Value Boxes which I assigned to Group 
Value. Then I would identify the calling box in code as follows:
Public Sub Value_GotFocus()
 dim txtTemp as valueBox = LAST
 SELECT CASE txtTemp.Name 'Returns name of calling Value Box
various actions

In Gambas 3 I got an error because the Value boxes are recognised as 
plain text boxes not as Value boxes. I changed my code (Dim txtTemp as 
Textbox) but when reading the LAST.Name it returns TextBox. It is 
returning the type not the name I assigned to the textbox.

The group feature was great for preventing repetitive code but this 
functionality appears to have gone. I must write similar code for each 
TextBox_GotFocus event.

Regards
Michael


On 17/12/10 18:58, wally wrote:
 On Thursday 16 December 2010 22:42:14 Benoît Minisini wrote:
 On Thursday 16 December 2010 20:15:21 Fabien Bodard wrote:
 I hope this can help you.

 This is in few lines how to make a real time graph in gambas
 Fabian,

 thank you very much, i'll study this code tomorrow.

 Would be nice if you may confirm the different behavior of
 DrawingArea.Resize in GB2 and GB3.


 wally

 Can you make a little project that shows the problem? The same progressing
 graph, with just arbitrary data for example. It will highly help to fix
 things
 if things should be fixed.

 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

 Benoit,

 i sent already, but maybe attachments has been rejected.

 The code below creates 1 circle. After resizing in GB3 i got
 4 circles. Doing same in GB2 just a resize of the area is performed
 and the primarly created circle persists.

 Public Sub btn_test_Click()

   'Drawing Area set to 100, 80
   ' DrawingArea.cache - True
   '- -  200, 160

Draw.Begin(DrawingArea1)
  Draw.Circle(50, 40, 30)
Draw.End

DrawingArea1.Resize(200, 160)

myPicture = DrawingArea1.Screenshot()
myPicture.Save(ProjPath/ circles.png)

 End







 --
 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

--
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] What has happened to ValueBox

2010-12-17 Thread Michael
Benoit,
On the line Dim txtTemp as Valuebox = LAST I get an error Expecting 
valuebox got textbox But the last control was a valuebox.
It works if I change the code to Dim txtTemp as Textbox even though it 
is not a textbox firing the event.

Then I cannot read the name that I assigned to the valuebox. 
txtTemp.Name just returns Textbox.

I tried replacing the valuebox with a DateBox but this appears to have a 
bug. I can set the value of the DateBox in code and it displays 
correctly. I can pick a value from the DatePicker and it displays 
properly. But it does not have a .Text property to read so I read the 
.Value property and it always returns 00:00:00

Using gtk+ and Ubuntu 10.10 64bit and Gambas 3363. The code i use worked 
fine in Gambas2.

Here is a small extract of the code as it works in Gambas2:
Public Sub Value_LostFocus()
 Dim txtTemp As ValueBox = Last'MUST CHANGE TO TextBox in 
Gambas3
 txtTemp.Background = Color.White

 Select Case txtTemp.Name 'Gambas 3 returns textbox
 Case txtDaysGas

Regards
Michael


On 17/12/10 23:41, Benoît Minisini wrote:
 In Gambas 2 I had a number of Value Boxes which I assigned to Group
 Value. Then I would identify the calling box in code as follows:
 Public Sub Value_GotFocus()
   dim txtTemp as valueBox = LAST
   SELECT CASE txtTemp.Name 'Returns name of calling Value Box
 various actions

 In Gambas 3 I got an error because the Value boxes are recognised as
 plain text boxes not as Value boxes. I changed my code (Dim txtTemp as
 Textbox) but when reading the LAST.Name it returns TextBox. It is
 returning the type not the name I assigned to the textbox.

 The group feature was great for preventing repetitive code but this
 functionality appears to have gone. I must write similar code for each
 TextBox_GotFocus event.

 Regards
 Michael

 ValueBox exists in Gambas 3, so I don't understand what error you are talking
 about. ValueBox are not recognized as plain text boxes, whatever that
 means...

 Can you explain better what happens to you?


--
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] What has happened to ValueBox

2010-12-17 Thread Michael
Thanks. I'll be off air for 2 weeks due to moving house. I look forward 
to getting latest version in 2011.

Regards
Michael


On 18/12/10 04:24, Benoît Minisini wrote:
 Benoit,
 On the line Dim txtTemp as Valuebox = LAST I get an error Expecting
 valuebox got textbox But the last control was a valuebox.
 It works if I change the code to Dim txtTemp as Textbox even though it
 is not a textbox firing the event.
 OK I see!

 The ValueBox of Gambas 2 inherits TextBox, and so when it raises events, LAST
 is always a ValueBox.

 The current ValueBox of Gambas 3 is actually a compound control (it inherits
 UserControl), with a edit control inside that can be a TextBox or another
 control. Events raised by the edit control are propagated as if the ValueBox
 raise it. But then LAST is the read TextBox, not the ValueBox.

 Moreover, the code of that ValueBox is somewhat dirty. So I plan to rewrite it
 differently, and makes it inheriting TextBox again, or find a way to propagate
 events and keep LAST to be the ValueBox.

 Sorry for the inconvenience. It will disappear when the ValueBox will be
 rewritten.

 As a workaround, you can check the type of LAST. And when it is a TextBox,
 take its parent to get the ValueBox.

 Regards,

 Then I cannot read the name that I assigned to the valuebox.
 txtTemp.Name just returns Textbox.

 I tried replacing the valuebox with a DateBox but this appears to have a
 bug. I can set the value of the DateBox in code and it displays
 correctly. I can pick a value from the DatePicker and it displays
 properly. But it does not have a .Text property to read so I read the
 .Value property and it always returns 00:00:00
 Maybe another bug then. I will investigate.

 Regards,


--
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] Gambas 3 Printing

2010-12-15 Thread Michael
This exploits my newness to Linux. How do I find out this version. I did 
a file search and found a lot of gtk-2.0 folders under /etc/ and under 
/python. Does this help. I am also using Ubuntu 10.10 64bit.
Is GTK an acronym for Gnome? MyGnome version is 2.32.0

Regards
Michael


On 16/12/10 09:06, Benoît Minisini wrote:
 Benoit
 Test project attached. I have included  a screenshot of my Print Dialog.
 Indeed. It is disabled on your machine. But it works perfectly there.

 It was interesting doing a small test project. In my main project, which
 uses basically the same code, the Font property is not respected and
 all printing is done in Ubuntu font. Also the Text Align.Right or
 Align.Center properties have no effect unless the Height property is
 specified.
 This is by design. Alignment only works inside a rectangle. Maybe I could
 modify the routine to work as you expected.

 In the test project I did not encounter these problems so I
 need to revisit the Paint methods.
 However the Orientation problem persists.
 Did you tell me which version of GTK+ you are using?

 Does someone else has the problem ?


--
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] Gambas 3 Printing

2010-12-13 Thread Michael
Benoit
Is there any movement on this printing issue yet? Either by fixing the 
print dialog or allowing setting in code?

Regards
Michael


On 10/12/10 13:41, Michael wrote:
 Benoit,
 I am using Rev.3349 and I can set Paper Type and Paper Source but still
 cannot set Output Tray, Paper Size and Orientation. This applies to the
 GTK+ library. I can set Orientation under QT4 because that uses a
 completely different dialog but it introduces different problems(
 Paint.Begin(hPrinter) causes error. device is already being drawn).
 The GTK+ library uses the same print dialog as Mozilla Firefox and all
 the options are enabled when using Firefox.
 I am using Ubuntu Maverick 10.10

 Regards
 Michael


--
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] Gambas 3 Printing

2010-12-13 Thread Michael
Thanks Benoit,
I've checked all the Ubuntu forums without success but it seems to be 
unique to Gambas.I still have a few things to try but I am busy moving 
house so shall return to it after Xmas.
Her is my output from svn info
URL: https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk
Repository Root: https://gambas.svn.sourceforge.net/svnroot/gambas
Repository UUID: 96304659-1d19-0410-acd0-aead272a8bd5
Revision: 3363
Node Kind: directory
Schedule: normal
Last Changed Author: gambas
Last Changed Rev: 3363
Last Changed Date: 2010-12-14 12:18:41 +1100 (Tue, 14 Dec 2010)

Regards
Michael


On 14/12/10 11:36, Benoît Minisini wrote:
 Benoit
 Is there any movement on this printing issue yet? Either by fixing the
 print dialog or allowing setting in code?

 Regards
 Michael

 Well, it works on my machine, so I don't understand why it doesn't on yours...
 Are you sure that you use the last commit?


--
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] What is the use of Tag property

2010-12-12 Thread Michael
Select Case is not an alternative to a click event. In the example I 
gave you would use the following pseudo code:
SUB btnEdit_Click()
ME.Tag = edit
Populate text boxes with current data and enable them to be edited

SUB btnNew_Click
ME.Tag = new
Clear all text boxes and enable them to accept data.

SUB btnSave_Click
SELECT CASE ME.Tag
 CASE edit'
 Update database with edited information
 CASE new
 Insert new record into database.
END SELECT
ME.Tag=

In my example the TAG property is set to indicate the status of the 
application. If the user tried to close the form you would be aware that 
data was being changed and you could ask the user if they wanted to save 
the data before closing.
I hope this is clear.

Regards
Michael


On 12/12/10 19:32, Demosthenes Koptsis wrote:
 Ok i see.

 i used to use buttons event click for each one button and it is a bit
 strange to understand it.

 So if i understand right instead of click event you use a SELECT CASE
 for tag property?



 On Sun, 2010-12-12 at 10:22 +1100, Michael wrote:
 If you want a practical example. I have a data form with Edit, Add and
 Save buttons. When I click Edit or Add I set the tag property of the
 form; it can be anything add edit or 1 and 2. When the Save
 button is clicked I then know which action to take. It's use is purely
 at the developer's discretion. In a sense it works as a global variable
 but is better because nobody likes globals.

 Regards
 Michael


 On 12/12/10 01:35, Demosthenes Koptsis wrote:
 PROPERTY Tag AS Variant

 Returns or sets the control tag.

 This property is intended for the programmer and is never used by the
 component. It can contain any Variant value.
 

 ok but what is the use of this property?


 --
 Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
 new data types, scalar functions, improved concurrency, built-in packages,
 OCI, SQL*Plus, data movement tools, best practices and more.
 http://p.sf.net/sfu/oracle-sfdev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user

--
Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
new data types, scalar functions, improved concurrency, built-in packages, 
OCI, SQL*Plus, data movement tools, best practices and more.
http://p.sf.net/sfu/oracle-sfdev2dev 
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] stop event and gtk

2010-12-11 Thread Michael
Not sure what you mean by $bLang. In my Close button I set the 
Form.Tag to any value and then test for this in the form_close event. If 
the user closes from the Form Header the tag is not set and I can use a 
message box to confirm the closure. The Stop Event works ok. I am using 
Ubuntu 10.10 64 bit.

Regards
Michael


On 12/12/10 00:28, Emanuele Sottocorno wrote:
 Hi,
 having the need to avoid the user closes the form before filling all
 fields, I try to intercept the click on the Close Button on Form Title
 with the following sub:

 Public Sub Form_Close()
If (Not $bLang) Then Stop Event
 End

 under GTK the Form_Close event isn't stopped.
 Gambas3 rev 3355
 Ubuntu 10.04 x86_64

 Tanks for help,
 Emanuele


 --
 Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
 new data types, scalar functions, improved concurrency, built-in packages,
 OCI, SQL*Plus, data movement tools, best practices and more.
 http://p.sf.net/sfu/oracle-sfdev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
new data types, scalar functions, improved concurrency, built-in packages, 
OCI, SQL*Plus, data movement tools, best practices and more.
http://p.sf.net/sfu/oracle-sfdev2dev 
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] What is the use of Tag property

2010-12-11 Thread Michael
If you want a practical example. I have a data form with Edit, Add and 
Save buttons. When I click Edit or Add I set the tag property of the 
form; it can be anything add edit or 1 and 2. When the Save 
button is clicked I then know which action to take. It's use is purely 
at the developer's discretion. In a sense it works as a global variable 
but is better because nobody likes globals.

Regards
Michael


On 12/12/10 01:35, Demosthenes Koptsis wrote:
 PROPERTY Tag AS Variant

 Returns or sets the control tag.

 This property is intended for the programmer and is never used by the
 component. It can contain any Variant value.
 

 ok but what is the use of this property?



--
Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
new data types, scalar functions, improved concurrency, built-in packages, 
OCI, SQL*Plus, data movement tools, best practices and more.
http://p.sf.net/sfu/oracle-sfdev2dev 
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas 3 GTK+ Keystroke Problem

2010-12-09 Thread Michael
Problem fixed. For those interested I had at some time allocated CTRL-O 
as a shortcut key for a menu. I changed my mind and unchecked the CTRL 
option and thought this was all I needed to do. In fact I had left just 
'o' as a shortcut key so it was intercepted by the menu system and not 
passed to the textbox. I found it by creating a new form and copying all 
my controls from the offending form and it worked. Then I used a good 
old command line 'comm' to compare the files and spotted this 
difference. Embarrassing!
Regards
Mike

On 09/12/10 18:09, Michael wrote:
 In 30 years of programming I have just found the most peculiar problem.
 I have an app with several text boxes. None of the text boxes will
 accept the character 'o'. They will accept 'SHIFT-O' but they will not
 accept an upper case O if the the caps lock key is active. Here are a
 few facts:
 1. All the text boxes are standard, visible, enabled and NOT readonly.
 2. They will accept all other keystrokes
 3. The same app in Gambas 2 has no problems.
 4. If I change my library from GTK+ to QT4 there is no problem.
 5. My 'o' key works fine in all other applications.
 6. If I start a new Gambas 3 app and add a text box then it will accept
 the 'o'.
 7. Problem is in IDE and runtime.
 8. If I monitor _KeyRelease it correctly reports Key.Code 79 but nothing
 appears in text box.
 9. If I add code to key_release such as txtBox.Text = txtBox.Text
 Key.Text then it will work but this is impractical.
 I know this must sound ridiculous but any ideas :)
 PS Also just tested activating Caps Lock and using SHIFT-o. It works, so
 it is a work around to get a lower case in the textbox.
 Regards
 Michael


 --
 This SF Dev2Dev email is sponsored by:

 WikiLeaks The End of the Free Internet
 http://p.sf.net/sfu/therealnews-com
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user



--
This SF Dev2Dev email is sponsored by:

WikiLeaks The End of the Free Internet
http://p.sf.net/sfu/therealnews-com
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas 3 Printing

2010-12-09 Thread Michael
Benoit,
I am using Rev.3349 and I can set Paper Type and Paper Source but still 
cannot set Output Tray, Paper Size and Orientation. This applies to the 
GTK+ library. I can set Orientation under QT4 because that uses a 
completely different dialog but it introduces different problems( 
Paint.Begin(hPrinter) causes error. device is already being drawn).
The GTK+ library uses the same print dialog as Mozilla Firefox and all 
the options are enabled when using Firefox.
I am using Ubuntu Maverick 10.10

Regards
Michael


On 09/12/10 21:24, Benoît Minisini wrote:
 Thanks Benoit,
 I have upgraded my print routines to run in V.3. The beauty of Gambas is
 the ability to work around any problems.
 My only outstanding problem is the inability to set the Paper
 Orientation in Printer.Configure or to code it with
 hPrinter.Orientation = Printer.Landscape.
 It should work now, since last sunday, revision #3344.

 Regards,

--
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] Gambas 3 Display problems

2010-12-08 Thread Michael
Using GB.GTK+ Library on Ubuntu maverick, I notice odd display behaviour:
1. Set a panel to default foreground, and text  on components is black 
in the IDE, as expected. Run the app and all text is grey.
2. As item 1 but select foreground color as System.TextForeGround and 
same problem.
3. As item 2 but select foreground color as Free 00 and all text 
is black in IDE and live.
4. Select a font as Ubuntu -1 and it appears as 10pt as  expected in the 
IDE. Run the app and it is about 14pt.
5. As item 4 but check the Size box and select a size of 10. It 
appears in the IDE, and Live, correctly as 10pt.
6. Set a Panel border to Etched and it appears correctly in IDE but, 
when run, it appears as plain. Same applies to Raised and Sunken.

I have used Panel as an example but the problems apply to other 
components such as labels and text boxes. All the problems can be worked 
around but it seems a backward step from the Gambas 2 IDE
Regards
Michael


--
What happens now with your Lotus Notes apps - do you make another costly 
upgrade, or settle for being marooned without product support? Time to move
off Lotus Notes and onto the cloud with Force.com, apps are easier to build,
use, and manage than apps on traditional platforms. Sign up for the Lotus 
Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas 3 Printing

2010-12-08 Thread Michael
Thanks Benoit,
I have upgraded my print routines to run in V.3. The beauty of Gambas is 
the ability to work around any problems.
My only outstanding problem is the inability to set the Paper 
Orientation in Printer.Configure or to code it with
hPrinter.Orientation = Printer.Landscape.
I look forward to a fix when available.
Regards
Michael

On 09/12/10 02:16, Benoît Minisini wrote:
 Can anybody please clarify how to generate a new page when printing in
 Gambas 3. I know you have have the Printer.Count value but it appears
 you need to know the number of pages to set this value before printing.
 You cannot loop through data and say INC hPrinter.Count. It will only
 print the initial count value.
 Similarly, I set the Count value high and then, when my data was
 exhausted, I tried reducing the Count to the current .hPrinter.Page
 value but this doesn't help.
 In Gambas 2 you could just issue a .newpage command when your 'y' value
 got too big.
 Regards
 Michael

 Yes. You must now tell how many pages you will print before printing. In other
 words, you must layour your document first, and then print it.

 Regards,

--
This SF Dev2Dev email is sponsored by:

WikiLeaks The End of the Free Internet
http://p.sf.net/sfu/therealnews-com
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] Gambas 3 GTK+ Keystroke Problem

2010-12-08 Thread Michael
In 30 years of programming I have just found the most peculiar problem. 
I have an app with several text boxes. None of the text boxes will 
accept the character 'o'. They will accept 'SHIFT-O' but they will not 
accept an upper case O if the the caps lock key is active. Here are a 
few facts:
1. All the text boxes are standard, visible, enabled and NOT readonly.
2. They will accept all other keystrokes
3. The same app in Gambas 2 has no problems.
4. If I change my library from GTK+ to QT4 there is no problem.
5. My 'o' key works fine in all other applications.
6. If I start a new Gambas 3 app and add a text box then it will accept 
the 'o'.
7. Problem is in IDE and runtime.
8. If I monitor _KeyRelease it correctly reports Key.Code 79 but nothing 
appears in text box.
9. If I add code to key_release such as txtBox.Text = txtBox.Text  
Key.Text then it will work but this is impractical.
I know this must sound ridiculous but any ideas :)
PS Also just tested activating Caps Lock and using SHIFT-o. It works, so 
it is a work around to get a lower case in the textbox.
Regards
Michael


--
This SF Dev2Dev email is sponsored by:

WikiLeaks The End of the Free Internet
http://p.sf.net/sfu/therealnews-com
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] Gambas 3 Printing

2010-12-07 Thread Michael
Can anybody please clarify how to generate a new page when printing in 
Gambas 3. I know you have have the Printer.Count value but it appears 
you need to know the number of pages to set this value before printing. 
You cannot loop through data and say INC hPrinter.Count. It will only 
print the initial count value.
Similarly, I set the Count value high and then, when my data was 
exhausted, I tried reducing the Count to the current .hPrinter.Page 
value but this doesn't help.
In Gambas 2 you could just issue a .newpage command when your 'y' value 
got too big.
Regards
Michael

--
What happens now with your Lotus Notes apps - do you make another costly 
upgrade, or settle for being marooned without product support? Time to move
off Lotus Notes and onto the cloud with Force.com, apps are easier to build,
use, and manage than apps on traditional platforms. Sign up for the Lotus 
Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas3 Printing

2010-12-04 Thread Michael
Hi Fabien,
I've got printing to work ok but positioning objects on the page is 
difficult compared to Gambas2. The Paint.Width and Paint.Height values 
seem to bear no relation to pixels or mm. On A4 paper I get values of 
559 and 760 approx. What units are used here? (My printer resolution is 300)
Also in the hPrinter.Configure() dialog I cannot set all the printer 
options, specifically 'Orientation' is disabled. I set it in code with 
hPrinter.Orientation = Printer.Landscape but the Paint component still 
outputs in Portrait mode.
Would appreciate any assistance.
Regards
Michael

On 04/12/10 01:19, Fabien Bodard wrote:
 Private hPrint As New Printer As Printer
 Public Sub Form_Open()

If Not hPrint.Configure() Then
  hPrint.Print

Endif

 End


 Public Sub Printer_Begin()

hPrint.Count = 1

 End


 Public Sub Printer_Draw()
Paint.Font.Size = 12

Paint.Text(Hello, 30, 50)
Paint.fill
 End

 Public Sub Printer_End()




 End



 Tou need to learn more about the paint class :)

 first create a path and then draw around or fill it (stroke/fill)

 look at the paint example

 --
 Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
 Tap into the largest installed PC base  get more eyes on your game by
 optimizing for Intel(R) Graphics Technology. Get started today with the
 Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
 http://p.sf.net/sfu/intelisp-dev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user



--
What happens now with your Lotus Notes apps - do you make another costly 
upgrade, or settle for being marooned without product support? Time to move
off Lotus Notes and onto the cloud with Force.com, apps are easier to build,
use, and manage than apps on traditional platforms. Sign up for the Lotus 
Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] First look at Gambas 3

2010-12-04 Thread Michael
Hi Benoit,
Sorry to bother you again. I have installed QtConfig and found I could 
change my default 'Background' color, which I did to HD3DFEB. This then 
appeared in my Gambas3 color dialog but the behaviour is very different 
with QT4 and GTK components. This explains my earlier problem with 
different color palettes for Gambas 2 and 3. I am guessing that QT 
configures itself to the system palette at the time of installation and 
does not reconfigure when your theme is changed. Hence the need for 
QTConfig.
The other thing I discovered is that, if you change the system colors in 
the QT color dialog then they only work for QT components. GTK 
components will use the OS color scheme unless you specify a Custom 
color in the color dialog.
SO I understand how it works and can work around any problems.
Perhaps, as a newcomer to Gambas, you can explain why we have GTK and QT 
libraries as they seem to duplicate each other. Is it just personal 
choice? I used QT in Gambas 2 as I needed the Printer object but I 
switched to GTK in Gambas3.
Regards
Michael

On 05/12/10 03:21, Benoît Minisini wrote:

 All font size +1,-1,+2... are relative to the default font size, which may
 be not the same between Gambas 2 (that uses Qt3) and Gambas 3 (that uses Qt4).
 To check that, you must configure your Qt library with the qtconfig program.
 The way to install and run it depends on the distribution.

--
What happens now with your Lotus Notes apps - do you make another costly 
upgrade, or settle for being marooned without product support? Time to move
off Lotus Notes and onto the cloud with Force.com, apps are easier to build,
use, and manage than apps on traditional platforms. Sign up for the Lotus 
Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] First look at Gambas 3

2010-12-03 Thread Michael
Thanks Rolf,
I did consider that but why would it change from Gambas 2 and make 
upgrading so tiresome? Also with the change in colors I mentioned, I 
thought this might be because I had a basically blue desktop theme when 
I installed Gambas2 but a different desktop theme when I installed 
Gambas3. THis is the only reason I can think of but it seems illogical 
that Gambas would read your theme when installed and never update it. I 
await Benoit's comments with much interest.
Regards
Michael

On 03/12/10 19:41, Rolf-Werner Eilert wrote:
 Just reading by...

 resolution. My system is 1680*1050 resolution and G2 reports
 Desktop.height as 1050. G3 reports desktop height as 1002! The desktop
 Maybe Gambas deducts the height for the... gosh what was its name...
 kicker or whatever... control bar at the lower screen edge? :-)

 Regards

 Rolf

 --
 Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
 Tap into the largest installed PC base  get more eyes on your game by
 optimizing for Intel(R) Graphics Technology. Get started today with the
 Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
 http://p.sf.net/sfu/intelisp-dev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user



--
Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
Tap into the largest installed PC base  get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] First look at Gambas 3

2010-12-03 Thread Michael
Benoit,
Here is an important piece of additional information. If I change my 
project components from gb.qt4 to gb.gtk then the error #11 disappears.
Also my desktop height is correctly reported as 1050 when using GTK. 
Also the font of a GTK frame does not automatically go bold. I was using 
QT in Gambas 2 for it's printer and draw library but I can switch to GTK 
in Gambas3 as soon as I work out how to use the new print facilities.
Regards
Michael

On 03/12/10 14:53, Michael wrote:
 Benoit,
 The output from Valgrind is attached. I added the leak-check option to 
 give you more information. The application was just automatically 
 generated by Gambas 3 with Fform to which I added 1 menu item with no 
 action code. The same bug appears in an app I ported from gambas2.

 On unrelated matters re: Porting from Gambas 2 to Gambas 3. I have the 
 following problems.
 1. The color options offered in Gambas 3 are different to Gambas 2. 
 All my pale blue forms are now pink.
 2. I used font Ubuntu +1 for QT text boxes in G2. In Gambas 3 the same 
 font appears huge. I had to change it to ubuntu -1.  In a Frame 
 control the font is always bold in G3 but in G2 I could set it to 
 'normal' without problem.
 3. All the forms copied from G2 were reduced in size. This was 
 probably caused by the Desktop.Height which I use to format forms 
 based on video resolution. My system is 1680*1050 resolution and G2 
 reports Desktop.height as 1050. G3 reports desktop height as 1002! The 
 desktop width is reported correctly. Have you changed the method of 
 measuring desktop.height?

 It seems upgrading from Gambas 2 to 3 is not a trivial exercise.

 Thanks for your help
 Michael

 On 03/12/10 10:43, Benoît Minisini wrote:
 Thanks Benoit,
 This enabled me to run in the IDE. I still have other mods to do as the
 components do not fit on the form but I will work on this.
 The error#11 did not happen with the V2.0 project. I started Gambas 3,
 select File/New Project/QT4.
 Get a project with FMain.  Press F5 and runs ok. CLick the X to close
 the form and get error #11 plus the warning I mentioned previously.

 Regards
 Mike

 Please, can you run your project with the valgrind tool to know where it
 crashes exactly?

 1) Gambas 3 must be compiled with debugging information enabled, 
 which should
 be the case by default.

 2) Open a terminal

 3) cd to the directory of the project that crashes

 4) Run the following command:

 $ valgrind --tool=memcheck --track-origins=yes --num-callers=50 gbx3

 5) Send me the output of valgrind.

 Of course, the valgrind tool must have been installed.

 Thanks in advance.

 Regards,


 --
 Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
 Tap into the largest installed PC base  get more eyes on your game by
 optimizing for Intel(R) Graphics Technology. Get started today with the
 Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
 http://p.sf.net/sfu/intelisp-dev2dev


 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user
--
Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
Tap into the largest installed PC base  get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] Gambas3 Printing

2010-12-03 Thread Michael
Does anybody have any experience of printing with Gambas3?
My sample code is below and the result is:
Calling .Configure fires the _End event.
Then the _Begin, _Paginate and _Draw events all fire.
Then I get an error (Test:4193): Gtk-CRITICAL **: 
IA__gtk_print_context_get_cairo_context: assertion `GTK_IS_PRINT_CONTEXT 
(context)' failed
Then a blank page is printed.
I have tried the sample Print app supplied with Gambas 3 but it was 
written for Gambas1. I'm surprised it even loaded. I cannot find much 
help on the net.
Would appreciate any help.
(Running on Ubuntu 10.10 with gb.gtk and gb.Cairo components).
Regards
Michael

Public myP As New Printer As myP
Public Sub Menu2_Click()
Dim blnOk As Boolean
If Not myP.Configure() Then
  blnok = myP.Print()
 Paint.Begin(myP)
 Endif
 Catch
 Message.Error(Error.Text)
End
Public Sub myP_Begin()
 myP.count = 1
End
Public Sub myP_Draw()
 Paint.Brush = Paint.Color(Color.Black)
 Paint.Font.Name = sans serif
 Paint.Font.Size = 16
 Paint.Text(hello, 300, 300, 600,, Align.Right)
 Paint.End
End
Public Sub myp_End()
Debug PRINT END
End
Public Sub myp_Paginate()
 Debug Paginate
End


--
Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
Tap into the largest installed PC base  get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas3 Printing

2010-12-03 Thread Michael
Thanks Fabien,
I am getting there slowly. Can print in a small test app but in a real 
world app I just get blank pages. One of the problems I overcame was the 
different units used by the printer and Paint routines. In Gambas2 the 
printer and Draw objects both used pixels. Now we seem to have a mixture 
of pixels and mm so a lot of conversion is necessary.
I'll keep trying. SHould I call .Fill after every .Text or should I call 
.Fill only after all the text has been written?
Regards
Michael

On 04/12/10 01:19, Fabien Bodard wrote:
 Private hPrint As New Printer As Printer
 Public Sub Form_Open()

If Not hPrint.Configure() Then
  hPrint.Print

Endif

 End


 Public Sub Printer_Begin()

hPrint.Count = 1

 End


 Public Sub Printer_Draw()
Paint.Font.Size = 12

Paint.Text(Hello, 30, 50)
Paint.fill
 End

 Public Sub Printer_End()




 End



 Tou need to learn more about the paint class :)

 first create a path and then draw around or fill it (stroke/fill)

 look at the paint example

 --
 Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
 Tap into the largest installed PC base  get more eyes on your game by
 optimizing for Intel(R) Graphics Technology. Get started today with the
 Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
 http://p.sf.net/sfu/intelisp-dev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user



--
What happens now with your Lotus Notes apps - do you make another costly 
upgrade, or settle for being marooned without product support? Time to move
off Lotus Notes and onto the cloud with Force.com, apps are easier to build,
use, and manage than apps on traditional platforms. Sign up for the Lotus 
Notes Migration Kit to learn more. http://p.sf.net/sfu/salesforce-d2d
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] First look at Gambas 3

2010-12-02 Thread Michael
I have been successfully running Gambas 2.2.1 and have just successfuly 
installed V3. using:
$ svn checkout 
https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/

I loaded a V2 project into V3 and it wouldn't run.Error was Bad form 
file version in class
I modified all my form files to replace the header with # Gambas Form 
File 3.0 but I still get the same message.

I tried creating a new project and this runs OK but with a warning 
warning: unable to load Qt translation: en_AU.UTF-8. When I close the 
form running in the IDE I get the familiar The program has stopped 
unexpectedly by raising signal #11.. It happens whether or not the 
project is marked as translatable.

Is there any way to import a V2 project into V3?
The second problem may not be so serious. If I compile the project it 
runs ok with no error messages.
Any help appreciated.
Mike

--
Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
Tap into the largest installed PC base  get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] First look at Gambas 3

2010-12-02 Thread Michael
Thanks Benoit,
This enabled me to run in the IDE. I still have other mods to do as the 
components do not fit on the form but I will work on this.
The error#11 did not happen with the V2.0 project. I started Gambas 3, 
select File/New Project/QT4.
Get a project with FMain.  Press F5 and runs ok. CLick the X to close 
the form and get error #11 plus the warning I mentioned previously.

Regards
Mike

On 02/12/10 23:13, Benoît Minisini wrote:
 I have been successfully running Gambas 2.2.1 and have just successfuly
 installed V3. using:
 $ svn checkout
 https://gambas.svn.sourceforge.net/svnroot/gambas/gambas/trunk/

 I loaded a V2 project into V3 and it wouldn't run.Error was Bad form
 file version in class
 I modified all my form files to replace the header with # Gambas Form
 File 3.0 but I still get the same message.

 Just after loading the Gmabas 2 project into Gambas 3, you must run update
 all forms in the tools menu. Not automatic yet...

 Then recompile, and if you get the signal #11 again, send me your Gambas 2
 project.

 Regards,


--
Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
Tap into the largest installed PC base  get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Removing / Modifying IsXXXX() functions in Gambas 3

2010-11-24 Thread Michael
Benoit,
The IsXXX functions confused me because when testing IsNumber(123) I 
got an error similar to Expected number got a string. It seems you 
needed to know the type before testing for it. I therefore do not use 
it. However I believe new versions of software should be backward 
compatible so I suggest giving the new functions a slightly different 
name. EG: IsNumeric.
Regards
Mike
On 24/11/10 22:08, Benoît Minisini wrote:
 Hi,

 I'm currently thinking about modifying/removing all Is() functions in
 Gambas 3.

 They mainly test the datatype of their expression. So, either the datatype is
 known at compile time, and there should be no need of testing it ; either you
 are using a Variant, and you can use TypeOf() to get the datatype of the
 value.

 I will replace them by some functions that will test if a value can be
 converted safely from a string by using localization. This is what most users
 expected from these functions.

 For exemple, in french localization:

   IsDate(13/2/20) -  True
   IsNumber(3,34) -  True
   IsInteger(3,34) -  False
   IsNumber(3.34) -  False
   
 Internally, they will use Val() and see if the conversion works.

 I will kept most of the name, so there will be a big incompatibility between
 Gambas 2, current Gambas 3, and final Gambas 3.

 What do you think about that?

 Who is using the Is() functions, and in which context?


--
Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
Tap into the largest installed PC base  get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Gambas 2 and Databound controls

2010-11-22 Thread Michael
Barnett,
Declare your connection as Public in Form1 (or in a module) and then 
refer to it from any other form as Form1.MyConnection.
In your Project/Properties/Options you may need to ensure that Module 
Symbols and Form Controls are set to public.
Regards
Mike

On 23/11/10 14:47, Barnett Winton wrote:
 Hi all,

 Could someone outline the steps required when calling a form with
 Datasource ( table specified) from a parent form.

 I am using Gambas 2.20 and sqlite3. OS is PCLinuxOS 2010.

 Form 1 provides for table selection and then calls a table specific Form
 ( Form 2)

 As there is no specific DB Connection info in Form 2, when Form 2 is
 called ( FModesEntry.Showmodal ) I get a DB error message from Form 1
 saying unknown table :  for the selected table.

 The example DB app passes the DB connection and the Result object (
 which contains the table records ) to a second form which is a Viewing Form.

 I want to set up the DB connection so I can access the table in a second
 form.

 I am guessing that the DB connection needs to be set up in Form 1, but
 How ??.

 Regards,
 Barnett Winton

 --
 Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
 Tap into the largest installed PC base  get more eyes on your game by
 optimizing for Intel(R) Graphics Technology. Get started today with the
 Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
 http://p.sf.net/sfu/intelisp-dev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
Increase Visibility of Your 3D Game App  Earn a Chance To Win $500!
Tap into the largest installed PC base  get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


[Gambas-user] SUb Routines with a return value

2010-11-19 Thread Michael
I have been using popup menus for the first time and got the following 
from the Gambas help.
PUBLIC SUB Action_Activate(key AS String) AS Boolean

I assumed this was an error as only functions have a return value so I 
changed it Public Function
Then on my line mnuPopup.Popup() it got an error no return value.

Then I modified the line to PUBLIC SUB... with no as Boolean. and 
got the same error. However it all works perfectly when written as a SUB 
with a return value. Is this intended?

One more question? Can Gambas 3 be installed alongside Gambas 2 on 
Ubuntu Maverick?

Thanks
Mike



--
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/msIE9-sfdev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] SUb Routines with a return value

2010-11-19 Thread Michael
Thanks Fabien
Mike

On 20/11/10 00:07, Fabien Bodard wrote:
 action_activate is an event handler not a funtion... that's why it's a sub

 in gambas SUB/FUNCTION are all synonyme of PROCEDURE

 chose between each is just made by convention ... but for events it's a sub !




 2010/11/19 Michaelmdavi...@tpg.com.au:
 I have been using popup menus for the first time and got the following
 from the Gambas help.
 PUBLIC SUB Action_Activate(key AS String) AS Boolean

 I assumed this was an error as only functions have a return value so I
 changed it Public Function
 Then on my line mnuPopup.Popup() it got an error no return value.

 Then I modified the line to PUBLIC SUB... with no as Boolean. and
 got the same error. However it all works perfectly when written as a SUB
 with a return value. Is this intended?

 One more question? Can Gambas 3 be installed alongside Gambas 2 on
 Ubuntu Maverick?

 Thanks
 Mike



 --
 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/msIE9-sfdev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
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/msIE9-sfdev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] SUb Routines with a return value

2010-11-19 Thread Michael
Fabien,
I didn't include the whole code. The MnuPopup.Popup is in a Click_Event 
of a grid because I want a popup menu not a permanent menu item. It 
works fine now.
I look forward to Gambas 3 release.
Regards
Mike

On 20/11/10 07:04, Fabien Bodard wrote:
 2010/11/19 Mattimath.e...@t-online.de:
 I don't understand exactly what you want to do, and why you have
 mnuPopup.Popup() inside the event handler sub Action_Activate. And why
 mnuPopup.Popup() anyway?
 i've don't say anything about that but generally a

 public sub myMenu_Click()

 end

 is enouth

 action is a system to manage groups of items


 Popup menus are easily made like

 PUBLIC SUB Form_MouseDown() 'or something else MouseDown()
   IF Mouse.Right THEN mnuTest.Popup
 END

 now mnuTest shows,
 and if some element of mnuTest is clicked, then

 PUBLIC SUB mnuAction_Click()
   Message.Info(hello)
 END

 Generally, you have to write sub/function AS something only if you want to
 return something to the code that called it. If you don't, PUBLIC SUB xy() 
 is
 enough.

 Yes, and Gambas 2 and 3 can live together on the same machine.


 Am 19.11.2010 13:33, schrieb Michael:
 I have been using popup menus for the first time and got the following
 from the Gambas help.
 PUBLIC SUB Action_Activate(key AS String) AS Boolean

 I assumed this was an error as only functions have a return value so I
 changed it Public Function
 Then on my line mnuPopup.Popup() it got an error no return value.

 Then I modified the line to PUBLIC SUB... with no as Boolean. and
 got the same error. However it all works perfectly when written as a SUB
 with a return value. Is this intended?

 One more question? Can Gambas 3 be installed alongside Gambas 2 on
 Ubuntu Maverick?

 Thanks
 Mike



 --
 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/msIE9-sfdev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user

 --
 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/msIE9-sfdev2dev
 ___
 Gambas-user mailing list
 Gambas-user@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/gambas-user




--
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/msIE9-sfdev2dev
___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user


Re: [Gambas-user] Problem with data types

2010-11-14 Thread Michael
Thanks Benoit,
The help page for gb.mysql says it is not available for Gambas2 but it 
doesn't matter as one of the beauties of Gambas, it is always possible 
to find a way  around problems.
When can we expect V3 generally available?
Regards
Mike

On 14/11/10 22:05, Benoît Minisini wrote:
 I am porting all my vb.net apps to gambas and I am very happy with the
 results, particularly the gb.db component. However it does have some
 limitations:
 1. I need to determine the type of database columns using
 irsData.Fields[intCounter].Type. This works fine for strings, floats,
 integers and dates  but many MySql data types such as 'Decimal' are seen
 as db.String(9).
 2. I thought I would test if it was really a string by using the
 ResultField.Length property which should return zero for non-strings but
 it returned 19 for a Decimal(18,0) field in my database.

 I overcame the problem by changing all my MySql decimal fields to floats
 and it works fine. However there may be other MySql types which I have
 not tested and which may have a similar problem. Are there any plans to
 update gb.db to handle the many data types now available in most databases?

 Regards
 Mike

 Yes and no.

 SQL datatypes are mapped to Gambas datatypes, so you don't see them.

 Moreover, the gb.db component aims at being independent of the database
 backend. And as SQL is not really a standard, datatypes are different between
 MySQL, PostgreSQL, SQLite..., and so it is impossible to manage them in an
 independant way.

 You will get more information about datatype mapping there:

   http://gambasdoc.org/help/doc/db-type-mapping

 On the other hand, David Villalobos Cambronero has wrote a component named
 gb.mysql that allows you to access all specific MySQL features. But I have
 never used it, so he will help you better than me about that.

 Regards,


--
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] Problem with data types

2010-11-13 Thread Michael
I am porting all my vb.net apps to gambas and I am very happy with the 
results, particularly the gb.db component. However it does have some 
limitations:
1. I need to determine the type of database columns using 
irsData.Fields[intCounter].Type. This works fine for strings, floats, 
integers and dates  but many MySql data types such as 'Decimal' are seen 
as db.String(9).
2. I thought I would test if it was really a string by using the 
ResultField.Length property which should return zero for non-strings but 
it returned 19 for a Decimal(18,0) field in my database.

I overcame the problem by changing all my MySql decimal fields to floats 
and it works fine. However there may be other MySql types which I have 
not tested and which may have a similar problem. Are there any plans to 
update gb.db to handle the many data types now available in most databases?

Regards
Mike

--
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] Gridview Select Multiple rows.

2010-11-05 Thread Michael
Thanks,
I will give this a try.
Michael

On 05/11/10 18:09, user wrote:
 Example with ListView control lswResults

 ---
 ' Gambas class file
 PRIVATE sFileArray AS String[] = []
 PRIVATE iKeyArray AS Integer[] = [0]
 PRIVATE bKeyControlPressed AS Boolean = FALSE
 PRIVATE bSellectAllPressed AS Boolean = FALSE



 PUBLIC SUB Form_Open()
sFileArray.Clear 'reset private array
iKeyArray.Clear  'reset private array
 END



 PUBLIC SUB btnSelectAll_Click()
bSellectAllPressed = TRUE
lswResults.SelectAll
 END


 PUBLIC SUB lswResults_KeyRelease()

 IF Key.Control = TRUE THEN
bKeyControlPressed = FALSE
 ENDIF


 END

 PUBLIC SUB lswResults_KeyPress()

 IF Key.Control = TRUE THEN
bKeyControlPressed = TRUE
 ENDIF

 END



 PUBLIC SUB lswResults_Select()

DIM iKey AS Integer = 0
DIM sElement AS String = 
DIM sFile AS String[] = []
DIM sRow AS String = 
DIM iCounter AS Integer

sFile.Clear
sRow = Replace$(lswResults.Current.Text,   , \n) 'format string
sFile = Split(sRow, \n) 'split row and take only path, reject virus
 description

' PRINT lswResults.Current.Text
' PRINT sFile[0]


 'HERE IS WHAT YOU LOOK FOR ---
'if user select with CTRL
 IF bKeyControlPressed = TRUE THEN
'check if in sFileArray there is a current selection
IF sFileArray.Count  0 THEN
'if there is one user clicked unselect
  IF sFileArray.Exist(sFile[0]) THEN
'delete entry of current selected item from sFileArray and from
 iKeyArray
  iKey = sFileArray.Find(sFile[0]) 'find key
  sFileArray.Delete(iKey) 'delete selection according found key
  iKey = iKeyArray.Find(lswResults.Current.Key) 'find key for second
 array
  iKeyArray.Delete(iKey) 'delete selection according found key
 'lswResults.Current.Selected = FALSE
  ELSE
  'if there is not, add the new selection
  sFileArray.Add(sFile[0])
  iKeyArray.Add(lswResults.Current.Key)
  ENDIF
ELSE 'add into Arrays for first time, sFileArray.Count=0
  sFileArray.Add(sFile[0])
  iKeyArray.Add(lswResults.Current.Key)
ENDIF
 ELSE IF bSellectAllPressed = TRUE THEN 'if user pressed btnSelectAll
   sFile.Clear 'clear array
   sFileArray.Clear
   iKeyArray.Clear

   lswResults.MoveFirst 'add all items of listview into arrays
   FOR iCounter = 0 TO lswResults.Count - 1
sRow = Replace$(lswResults[lswResults.Item.Key].Text,   , \n)
 'format string
sFile = Split(sRow, \n) 'split row and take only path, reject virus
 description
sFileArray.Add(sFile[0])
iKeyArray.Add(lswResults[lswResults.Item.Key].Key)
lswResults.MoveNext
   NEXT
   bSellectAllPressed = FALSE

 ELSE 'user makes single clicks
sFileArray.Clear
iKeyArray.Clear

sFileArray.Add(sFile[0])
iKeyArray.Add(lswResults.Current.Key)

 ENDIF
 '


 ' PRINT --
 ' FOR EACH sElement IN sFileArray
 ' PRINT sElement
 ' NEXT

 END


 On Fri, 2010-11-05 at 15:09 +1100, Michael wrote:
 I'm a newbie to Gambas and very impressed. Managed to solve all my
 queries and port apps from VB. However I have one problem that has me beat:)
 I have a GridView with Mode = Multiple and can select multiple rows;
 either sequentially or at random. So far so good as similar to VB.
 I want to loop through the selected items and take some action on each
 item. eg: Delete the row.
 I cannot find a way to read the selected row. The Gridview.Row property
 only returns the last selected row.
 Typically my grid may contain 1000 rows and I use this function to
 delete old records. It would be tedious one at a time. I could get
 around it by asking the user to enter a cutoff date or range of row
 numbers to delete but this raises the question What is the point of
 having a Multiple mode attribute?
 Thanks
 Mike

 --
 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


 --
 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] Gridview Select Multiple rows.

2010-11-05 Thread Michael
Sorry, this does not work. It only applies to the ListView. I do use a 
ListView elsewhere and the easiest way is simply to loop through all 
items with the .movenext function and check for If lvw.current.selected 
or lvw.item.selected. Then add the Key to the array of items to process.

Unfortunately the GridView has no .item property. It has a .current 
property but this does not have a .selected property.

I think I will add an extra hidden column to my grid to hold a 
'Selected' flag. I can use some of your example to track the CONTROL and 
SHIFT keys to reset these flags as appropriate.
Regards
Michael
On 05/11/10 18:09, user wrote:
 Example with ListView control lswResults

 ---
 ' Gambas class file
 PRIVATE sFileArray AS String[] = []
 PRIVATE iKeyArray AS Integer[] = [0]
 PRIVATE bKeyControlPressed AS Boolean = FALSE
 PRIVATE bSellectAllPressed AS Boolean = FALSE



 PUBLIC SUB Form_Open()
sFileArray.Clear 'reset private array
iKeyArray.Clear  'reset private array
 END



 PUBLIC SUB btnSelectAll_Click()
bSellectAllPressed = TRUE
lswResults.SelectAll
 END


 PUBLIC SUB lswResults_KeyRelease()

 IF Key.Control = TRUE THEN
bKeyControlPressed = FALSE
 ENDIF


 END

 PUBLIC SUB lswResults_KeyPress()

 IF Key.Control = TRUE THEN
bKeyControlPressed = TRUE
 ENDIF

 END



 PUBLIC SUB lswResults_Select()

DIM iKey AS Integer = 0
DIM sElement AS String = 
DIM sFile AS String[] = []
DIM sRow AS String = 
DIM iCounter AS Integer

sFile.Clear
sRow = Replace$(lswResults.Current.Text,   , \n) 'format string
sFile = Split(sRow, \n) 'split row and take only path, reject virus
 description

' PRINT lswResults.Current.Text
' PRINT sFile[0]


 'HERE IS WHAT YOU LOOK FOR ---
'if user select with CTRL
 IF bKeyControlPressed = TRUE THEN
'check if in sFileArray there is a current selection
IF sFileArray.Count  0 THEN
'if there is one user clicked unselect
  IF sFileArray.Exist(sFile[0]) THEN
'delete entry of current selected item from sFileArray and from
 iKeyArray
  iKey = sFileArray.Find(sFile[0]) 'find key
  sFileArray.Delete(iKey) 'delete selection according found key
  iKey = iKeyArray.Find(lswResults.Current.Key) 'find key for second
 array
  iKeyArray.Delete(iKey) 'delete selection according found key
 'lswResults.Current.Selected = FALSE
  ELSE
  'if there is not, add the new selection
  sFileArray.Add(sFile[0])
  iKeyArray.Add(lswResults.Current.Key)
  ENDIF
ELSE 'add into Arrays for first time, sFileArray.Count=0
  sFileArray.Add(sFile[0])
  iKeyArray.Add(lswResults.Current.Key)
ENDIF
 ELSE IF bSellectAllPressed = TRUE THEN 'if user pressed btnSelectAll
   sFile.Clear 'clear array
   sFileArray.Clear
   iKeyArray.Clear

   lswResults.MoveFirst 'add all items of listview into arrays
   FOR iCounter = 0 TO lswResults.Count - 1
sRow = Replace$(lswResults[lswResults.Item.Key].Text,   , \n)
 'format string
sFile = Split(sRow, \n) 'split row and take only path, reject virus
 description
sFileArray.Add(sFile[0])
iKeyArray.Add(lswResults[lswResults.Item.Key].Key)
lswResults.MoveNext
   NEXT
   bSellectAllPressed = FALSE

 ELSE 'user makes single clicks
sFileArray.Clear
iKeyArray.Clear

sFileArray.Add(sFile[0])
iKeyArray.Add(lswResults.Current.Key)

 ENDIF
 '


 ' PRINT --
 ' FOR EACH sElement IN sFileArray
 ' PRINT sElement
 ' NEXT

 END


 On Fri, 2010-11-05 at 15:09 +1100, Michael wrote:
 I'm a newbie to Gambas and very impressed. Managed to solve all my
 queries and port apps from VB. However I have one problem that has me beat:)
 I have a GridView with Mode = Multiple and can select multiple rows;
 either sequentially or at random. So far so good as similar to VB.
 I want to loop through the selected items and take some action on each
 item. eg: Delete the row.
 I cannot find a way to read the selected row. The Gridview.Row property
 only returns the last selected row.
 Typically my grid may contain 1000 rows and I use this function to
 delete old records. It would be tedious one at a time. I could get
 around it by asking the user to enter a cutoff date or range of row
 numbers to delete but this raises the question What is the point of
 having a Multiple mode attribute?
 Thanks
 Mike

 --
 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

Re: [Gambas-user] Gridview Select Multiple rows.

2010-11-05 Thread Michael
Thanks Fabien,
I found it eventually but don't you feel silly when it's staring you in 
the face
Michael

On 06/11/10 00:27, Fabien Bodard wrote:
 Le 5 novembre 2010 13:26, Benoît Minisini
 gam...@users.sourceforge.net  a écrit :
 Sorry, this does not work. It only applies to the ListView. I do use a
 ListView elsewhere and the easiest way is simply to loop through all
 items with the .movenext function and check for If lvw.current.selected
 or lvw.item.selected. Then add the Key to the array of items to process.

 Unfortunately the GridView has no .item property. It has a .current
 property but this does not have a .selected property.

 I think I will add an extra hidden column to my grid to hold a
 'Selected' flag. I can use some of your example to track the CONTROL and
 SHIFT keys to reset these flags as appropriate.
 Regards
 Michael

 You need something like that:

 For iInd = 0 to TheGridView.Rows.Count - 1
   If TheGridView.Rows[iInd].Selected Then
 ...
   Endif
 Next

 Regards,

 --
 Benoît Minisini

 http://gambasdoc.org/help/comp/gb.qt4/.gridviewrows?v3

 It is not in the doc, Benoit :), otherwise I would not say all this nonsense

 --
 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




--
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] Gridview Select Multiple rows.

2010-11-04 Thread Michael
I'm a newbie to Gambas and very impressed. Managed to solve all my 
queries and port apps from VB. However I have one problem that has me beat:)
I have a GridView with Mode = Multiple and can select multiple rows; 
either sequentially or at random. So far so good as similar to VB.
I want to loop through the selected items and take some action on each 
item. eg: Delete the row.
I cannot find a way to read the selected row. The Gridview.Row property 
only returns the last selected row.
Typically my grid may contain 1000 rows and I use this function to 
delete old records. It would be tedious one at a time. I could get 
around it by asking the user to enter a cutoff date or range of row 
numbers to delete but this raises the question What is the point of 
having a Multiple mode attribute?
Thanks
Mike

--
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] Embedded XTerm

2010-05-19 Thread Michael Asher
To preface this, I'm not a developer by any stretch of the imagination

I'm looking to use the embedder class to embed a xterm into a form.

My main purpose for my project is to have something for managing my
SSH/telnet/serial sessions from a single application, similar to
SecureCRT or Putty.

Xterm allows me to specify the WM_CLASS item as it is opened (xterm
-class ...). I would like to provide a 'random' class value for each
xterm, should I get to the point where I have multiple forms/xterms,
etc.

I am able to launch the xterm, but the Desktop.FindWindow always
provides me with a zero count. Can I use a variable as the
Application as String portion in Desktop.FindWindow?

Below is from the module that is supposed to take the user input and
make the SSH or telnet connection. I've included the part that is
giving me issues.


Public Sub quickConnect_Click()
 Dim XtermClass As Integer
 Dim XTermClassStr As String
 Dim DoEmbedIntArray As Integer[]
 Dim DoEmbedInt As Integer
 Randomize 123 ' Not sure I need this, but it provides class name
consistency for now.

If chooseProtocol.Index = 1 Then
 XtermClass = Int(Rnd(1, 10))
 XTermClassStr = Str(XtermClass)

 Debug XtermClass
 Debug XTermClassStr
 Shell xterm -class   XtermClass   -e ssh   ipAddress.Text  
-p   choosePort.Text ' Provide XTERM with a CLASS Value so that we
can then find it and embed into the application.
 Wait 1
 Me.Delete
 DoEmbedIntArray = Desktop.FindWindow(, XTermClassStr, )
 Debug DoEmbedIntArray.Count

Endif

If chooseProtocol.Index = 2 Then
 Shell xterm -e telnet   ipAddress.Text  :  choosePort.Text
 Me.Delete
Endif

End


I appreciate any pointers or help you can provide.
Thanks!
-Michael

--

___
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user