Re: [dabo-users] No Dabo application starts

2014-10-01 Thread john

On 10/01/2014 08:48 AM, Sibylle Koczian wrote:

Hello,

when I try to start a Dabo application I get this:

sib@gespenst-lubuntu:~/src/dabo-master/ide$ ./Editor.py
Traceback (most recent call last):
  File "./Editor.py", line 1134, in 
main()
  File "./Editor.py", line 1121, in main
app.setup()
  File "/home/sib/src/dabo-master/dabo/dApp.py", line 339, in setup
self.uiApp = dabo.ui.getUiApp(self, self.UIAppClass, 
callback=None, forceNew=True)
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/__init__.py", line 275, 
in getUiApp

ret = uiAppClass(app, callback)
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/uiApp.py", line 115, in 
__init__

wx.App.__init__(self, 0, *args)
  File 
"/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/_core.py", 
line 7981, in __init__

self._BootstrapApp()
  File 
"/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/_core.py", 
line 7555, in _BootstrapApp

return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/uiApp.py", line 191, in 
OnInit

if not self.checkForUpdates():
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/uiApp.py", line 213, in 
checkForUpdates

checkResult = self.dApp._checkForUpdates(force=force)
  File "/home/sib/src/dabo-master/dabo/dApp.py", line 587, in 
_checkForUpdates

dabo.log.error(_("Could not connect to the Dabo servers: %s") % e)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 
42: ordinal not in range(128)


Same message with my own application (unchanged for months, last known 
to work end of August, not used since then) or with DaboDemo. So I 
can't give the usual version information. But it's dabo-0.9.14.tar.gz 
on Lubuntu 14.04 (no updates to this after the last successful use of 
Dabo).


What would I have to change to work without any check for updates?

Thank you for help,
Sibylle
___

Normally when is see this message it is because the password in the 
cionnection file is wrong or corrupt.  I would open the file with 
CxnEditor.py and reset the password.

Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/542c2d13.5020...@jfcomputer.com


Re: [dabo-users] No Dabo application starts

2014-10-01 Thread john

On 10/01/2014 11:38 AM, Sibylle Koczian wrote:

Am 01.10.2014 18:34, schrieb john:

On 10/01/2014 08:48 AM, Sibylle Koczian wrote:

Hello,

when I try to start a Dabo application I get this:

sib@gespenst-lubuntu:~/src/dabo-master/ide$ ./Editor.py
Traceback (most recent call last):
  File "./Editor.py", line 1134, in 
main()
  File "./Editor.py", line 1121, in main
app.setup()
  File "/home/sib/src/dabo-master/dabo/dApp.py", line 339, in setup
self.uiApp = dabo.ui.getUiApp(self, self.UIAppClass,
callback=None, forceNew=True)
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/__init__.py", line 275,
in getUiApp
ret = uiAppClass(app, callback)
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/uiApp.py", line 115, in
__init__
wx.App.__init__(self, 0, *args)
  File
"/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/_core.py",
line 7981, in __init__
self._BootstrapApp()
  File
"/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/_core.py",
line 7555, in _BootstrapApp
return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/uiApp.py", line 191, in
OnInit
if not self.checkForUpdates():
  File "/home/sib/src/dabo-master/dabo/ui/uiwx/uiApp.py", line 213, in
checkForUpdates
checkResult = self.dApp._checkForUpdates(force=force)
  File "/home/sib/src/dabo-master/dabo/dApp.py", line 587, in
_checkForUpdates
dabo.log.error(_("Could not connect to the Dabo servers: %s") % e)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position
42: ordinal not in range(128)

Same message with my own application (unchanged for months, last known
to work end of August, not used since then) or with DaboDemo. So I
can't give the usual version information. But it's dabo-0.9.14.tar.gz
on Lubuntu 14.04 (no updates to this after the last successful use of
Dabo).




Normally when is see this message it is because the password in the
cionnection file is wrong or corrupt.  I would open the file with
CxnEditor.py and reset the password.


True, I've had that too, but I think the message wasn't quite the 
same. Only this time I can't start CxnEditor.py either - same message. 
And I don't think that Editor.py needs a connection file at all.


Thank you,
Sibylle




Can I assume you have changed the _checkForUpdates to False to insure 
that the app is not attempting to connect to Dabo?


Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/542c4b85.6040...@jfcomputer.com


Re: [dabo-users] No Dabo application starts

2014-10-08 Thread john

On 10/08/2014 04:45 AM, Werner wrote:

Hi Sibylle,

On 10/8/2014 12:47, Sibylle Koczian wrote:

Hello, Werner,

many thanks for the instructions!

Am 06.10.2014 10:26, schrieb Werner:

I think you are on Windows, if correct I would suggest TortoiseGit:
https://code.google.com/p/tortoisegit/wiki/Download

I'm using Dabo only on Linux (virtual machines in a Windows Host), so 
I suppose I'll need another Git client? Any other differences?
I don't often use Linux, just recently got going on it - again. When 
looking for TG on Linux I came across:

http://www.syntevo.com/smartgit/

I started using it just the other day - it looks pretty good and looks 
like it handles also HG and SVN.


Werner

Although, most Linux distro's have git as a download and on Linux that's 
what I have been using (no expert believe me) I checked your link out.  
Are you by chance using syntevo?  I wonder if you find it easy to use.  
I always have trouble recalling what the commands are to get simple 
commits etc. done.  I don't use git (other than downloads) enough to be 
proficient.  But of course that's true of SVN too.


So I guess I  want to know if you think it's worth the money and is it 
easy to use.


Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54354989.7060...@jfcomputer.com


Re: [dabo-users] Dabo with Phoenix and Python 3.x

2015-01-20 Thread john
At the moment Phoenix is not been ready for prime time.  Therefore, we 
are in the middle of updating Dabo to support wxPython 3.x using python 
2.7.x.  It's actually done if you are on Linux or Mac. Windows however 
still has a few issues.  I suspect we will soon have something in the 
next two weeks.


Johnf
On 01/20/2015 12:56 PM, Douglas Rist wrote:

Hello:

I searched through the archives, but found little.

Is anyone successfully using Dabo with wxPython Phoenix and Python 3.x?

Alternately, is there any progress on the pyQT bindings?

Thank you,
Douglas

---
This email has been checked for viruses by Avast antivirus software.
http://www.avast.com

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/54bec11b.7090...@hevanet.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54bec58f.4010...@jfcomputer.com


[dabo-users] update on wxPython 3.0

2015-01-27 Thread john

Hi folks,

The good news is wxPython 3.0 is working with Linux and Mac.  There are 
few minor issues such as the splash screen (on the Mac), dLine - but in 
general working. Also, Dabo is much faster on Linux than in the past. 
BTW Neil Flowers has been doing most of the work and of course some work 
was done by Werner.


The bad news is on the windows side.  Lot's of issues.  Last night we 
were able to get ClassDesigner to work on windows which is a major 
step.  Not all of the features were tested but it does open and will 
create a form.  dGrid demo does not work correctly - but I believe 
that's the fault of the test class rather than an issue with dGrid.  So 
we are getting there.


About 1.5 weeks ago I thought we could finish in two weeks.  Well, we 
lost a week due to other commitments.  Let's hope we can get more done 
this week.  Let us get more of the issues fixed on windows and we will 
commit.


Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54c7ac91.6010...@jfcomputer.com


Re: [dabo-users] Phoenix - Py3 - ReportDesigner

2015-02-03 Thread john

Yes there is a fix that Neil came up with - his notes:

Resolved the locale problem by moving it from dApp's __init__ to uiApp's 
OnInit, because wx3 requires using wx.Locale which can't be initialized 
until after the app is set up. This should resolve the problem on osx 
and windows


I'll send a new copy.

Johnf


On 02/03/2015 03:45 AM, Werner wrote:

Hi,

I am doing a bit of work on my app again to try to get it working with 
Phoenix.  With the report designer I see this error:


File "d:\devMine\twcbv5\twcbsrc\controllers\fDaboDesign.py", line 231, 
in 

  main()
File "d:\devMine\twcbv5\twcbsrc\controllers\fDaboDesign.py", line 158, 
in main

  app.Icon = uiutils.getImageResource('twcb-64.png', True, True)
File "d:\devMine\twcbv5\twcbsrc\libui\uiutils.py", line 212, in 
getImageResource

  bmpTmp = wx.Image(imgFile, wx.BITMAP_TYPE_ANY)

wx._core.wxAssertionError: C++ assertion "strcmp(setlocale(LC_ALL, 
NULL), "C") == 0" failed at ..\..\src\common\intl.cpp(1449) in 
wxLocale::GetInfo(): You probably called setlocale() directly instead 
of using wxLocale and now there is a mismatch between C/C++ and 
Windows locale.
Things are going to break, please only change locale by creating 
wxLocale objects to avoid this!


I think this is caused by a relative recent change in wxWidget.

John did you by any chance find a solution for this in your work?

Werner
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d0b4f7.8060...@gmx.ch




--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d0d4c7.6090...@jfcomputer.com


Re: [dabo-users] Phoenix - Py3 - ReportDesigner

2015-02-04 Thread john


On 02/04/2015 05:30 AM, Ed Leafe wrote:

On Feb 3, 2015, at 8:47 PM, Neil Flowers  wrote:

Here’s the relevant snippet from uiApp.OnInit:

def OnInit(self):
app = self.dApp
# As of wx3, locale must be set using wx.Locale; this can only 
be created after the wx.App's initialization, so locale
# is moved here (also note setting locale is no longer 
toolkit-agnostic, so other toolkit bindings would need to handle it internally)
if dabo.loadUserLocale:
self.locale = wx.Locale(wx.LANGUAGE_DEFAULT)

This seemed to be fine when placed in __init__ as well, so that’s another 
option. I didn’t even see the locale issue manifest until I started testing on 
Windows, but the above should work on any platform.

Would this cause a problem if the user has set a locale to something other than 
the wx default?


-- Ed Leafe
That's a good question because I don't know what we mean by locale.
Being the dumb American and having never had to run any other setting 
than 'en' I have been wondering what we really want. Is it the OS 
setting or is it something else like the language or country codes.  At 
the moment I think it's not going to matter once we get to python 3.x 
but that does not help at the moment.


Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d22b90.5090...@jfcomputer.com


Re: [dabo-users] Phoenix - Py3 - ReportDesigner

2015-02-04 Thread john


On 02/04/2015 07:57 AM, Paul McNett wrote:
One thing that may bite us is if the existing locale is garbage 
collected but then the new language isn't supported, perhaps (not sure 
here) we should just use whatever the existing locale is instead of 
defaulting to wx's default. 

But then wxPython still requires that it be setup

Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d25294.6010...@jfcomputer.com


[dabo-users] makeGridEditor is in uiwx/__init__

2015-02-05 Thread john

Hi all,
makeGridEditor is a method in uiwx/__init__ - can anyone explain why 
it's there?  It appears that it is called from only uiwx/dGrid.py when 
setting up the dGrid test.  The way I understand to create a CellRederer 
does not match the code in makeGridEditor.  I not saying I know 
everything about CellRederers but to be honest I don't understand it.  
There is no method clone, or draw.  I do not see where it inherits from 
either PyGridCellRenderer or GridCellRenderer.


Does anyone use the makeGridEdior in their code?  I ask because I'd like 
to remove it.


Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d3b505.9010...@jfcomputer.com


Re: [dabo-users] makeGridEditor is in uiwx/__init__

2015-02-06 Thread john


On 02/06/2015 01:14 PM, Paul McNett wrote:

On 2/5/15 10:23 AM, john wrote:

Hi all,
makeGridEditor is a method in uiwx/__init__ - can anyone explain why
it's there?  It appears that it is called from only uiwx/dGrid.py when
setting up the dGrid test.  The way I understand to create a CellRederer
does not match the code in makeGridEditor.  I not saying I know
everything about CellRederers but to be honest I don't understand it.
There is no method clone, or draw.  I do not see where it inherits from
either PyGridCellRenderer or GridCellRenderer.

Does anyone use the makeGridEdior in their code?  I ask because I'd like
to remove it.


Once very long ago I had this vision to make VFP-like grids where you 
could populate them with dTextBoxes, dCheckboxes, dWhatevers, or your 
own subclasses of them.


I wanted to implement this, and then take away keyword args to dColumn 
that wouldn't be necessary anymore (data format, type, etc.) as well 
as functionality that dGrid could now just delegate to the control 
(getting/setting the Value, etc.).


makeGridEditor() got us 80% there. I tried a few times to get it into 
dGrid but people complained about some problems that it caused (can't 
remember now the specifics).


Alas, it's cruft now and so should be removed, unless people are 
relying on it (in theory they could use it how I describe above for 
their own classes).


Paul

Thanks for the info Paul.  I left it in - but of course it does not 
work.  To be honest I too don't see the need - wxPython provides a very 
rich set of cell renderers and for those few that need a special 
renderer it's not to hard to create.


Beyond the above, I could not determine how it worked - for example in 
the clone method you have '1/0' which of course will cause an error but 
clone is never called which was a complete surprise.  The inheritance 
also work in some funny way that I did not understand. Of course it's 
moot at this point unless someone wants to revisit at a later time.


Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d533cb.3000...@jfcomputer.com


[dabo-users] wxPython is almost ready

2015-02-06 Thread john

Hi all,
At this point I believe Dabo 2 (what do you think of calling it version 
2 and reserve version 3 for python 3) using wxPython 3.x is working on 
windows.  Linux is still having trouble with ReportDesigner.py but I 
believe Neil will have a look at that soon. Of course we will need more 
testing but it runs all my forms.  Many of my forms are complex - 
meaning using most of Dabo's features.  So I feel it's ready.  Linux is 
also running all my reports and forms. I just can't use ReportDesigner 
to design any new reports.


Neil will be doing the commit because he did most of the work and should 
receive any credit due (of course along with Werner).


If anybody has a form or two that they will allow me to test - that 
would be helpful - just forward a copy to me.


Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d53685.2050...@jfcomputer.com


Re: [dabo-users] makeGridEditor is in uiwx/__init__

2015-02-06 Thread john


On 02/06/2015 01:41 PM, Paul McNett wrote:

On 2/6/15 1:36 PM, john wrote:


Beyond the above, I could not determine how it worked - for example in
the clone method you have '1/0' which of course will cause an error but
clone is never called which was a complete surprise.  The inheritance
also work in some funny way that I did not understand. Of course it's
moot at this point unless someone wants to revisit at a later time.


Take it out. I put 1/0 in places to prove/disprove that the code is 
being called (shortcut to cause an exception). The fact that it is 
there means I wanted to document that the code was never called (I 
think the wxPython docs claimed it would be called, or something).


Seriously, take it out. Think of the time we wasted just talking about 
it. Dabo needs to be simplified. Seriously.


Paul



OK will do.
Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d536b9.4000...@jfcomputer.com


Re: [dabo-users] wxPython is almost ready

2015-02-06 Thread john


On 02/06/2015 02:02 PM, Ed Leafe wrote:

On Feb 6, 2015, at 3:47 PM, john  wrote:


At this point I believe Dabo 2 (what do you think of calling it version 2 and 
reserve version 3 for python 3)

Heh, we still haven't reached Dabo 1 yet, believe it or not...

-- Ed Leafe


Yes, I'm aware. It's just that I didn't want others to get confused with 
the stable version of Dabo that uses wxPython 2.8.x.
But windows and Mac are covered at wxpython.org but Linux is looking a 
little rough at the moment.  So maybe it's not a big deal?

Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d53f7f.7080...@jfcomputer.com


Re: [dabo-users] wxPython is almost ready

2015-02-09 Thread john


On 02/09/2015 08:24 AM, Ed Leafe wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 02/06/2015 04:25 PM, Paul McNett wrote:


So we never will have had a version 1. I like it!


Sounds good to me. Version 2 for current Python 2.x only, and version 3
for 3.x support.


- -- Ed Leafe


Great - when Neil is ready to commit (I believe that to be soon) we will 
call it Dabo 2 - beta.


Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/54d8e3d6.3030...@jfcomputer.com


[dabo-users] toolbar background color

2015-04-08 Thread john

Hi,
I'm trying to change the background color of a dToolbar.  The toolbar is 
unique in that when I attempt to set the background color using
toolbar.SetBackgroundColour('yellow') the method either does nothing or 
returns a traceback



TypeError: in method 'Window_SetOwnBackgroundColour', expected argument 
1 of type 'wxWindow *'



There is something unique with the toolbars!  A toolbar is really not 
part of the form.


First question:  Where is the color set for the dToolbar?

Second:  Where is the main form setting the color?

Johnf




--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/5525354b.9070...@jfcomputer.com


Re: [dabo-users] toolbar background color

2015-04-08 Thread john
Testing directly with wxPython reveals this is NOT a Dabo issue. Using 
code to add a toolbar reveals that I can not change the background color 
completely only the border of the added object/s (does not work with 
buttons - could be due to the lack of a border with buttons).

Again toolbars are unique.
Johnf

On 04/08/2015 07:03 AM, john wrote:

Hi,
I'm trying to change the background color of a dToolbar.  The toolbar 
is unique in that when I attempt to set the background color using
toolbar.SetBackgroundColour('yellow') the method either does nothing 
or returns a traceback



TypeError: in method 'Window_SetOwnBackgroundColour', expected 
argument 1 of type 'wxWindow *'



There is something unique with the toolbars!  A toolbar is really not 
part of the form.


First question:  Where is the color set for the dToolbar?

Second:  Where is the main form setting the color?

Johnf






--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/55253926.8060...@jfcomputer.com


Re: [dabo-users] toolbar background color

2015-04-08 Thread john



On 04/08/2015 07:41 AM, Paul McNett wrote:

On 4/8/15 7:20 AM, john wrote:

Testing directly with wxPython reveals this is NOT a Dabo issue. Using
code to add a toolbar reveals that I can not change the background color
completely only the border of the added object/s (does not work with
buttons - could be due to the lack of a border with buttons).
Again toolbars are unique.


Here's what I remember, the toolbar needs to be instantiated with the 
color you want, and I think we handled the reinstantiation for you in 
dabo. Have you tried mytoolbar.BackColor=(23,43,5)?


Paul


Thanks for responding.  I have tried several ways including yours. I 
think this has something to do with wxPython and not Dabo.
Try the below code (it only takes a second) and note that yellow appears 
around the textbox but not around the rest of the panel/frame of the 
toolbar.


import wx

ID_TIMER = 1
ID_EXIT  = 2
ID_ABOUT = 3
ID_BUTTON = 4

class Isabelle(wx.Frame):
def __init__(self, parent, id, title):
wx.Frame.__init__(self, parent, id, title)

self.timer = wx.Timer(self, ID_TIMER)
self.blick = 0

file = wx.Menu()
file.Append(ID_EXIT, '&Quit\tCtrl+Q', 'Quit Isabelle')

help = wx.Menu()
help.Append(ID_ABOUT, '&About', 'O Programe')


menubar = wx.MenuBar()
menubar.Append(file, '&File')
menubar.Append(help, '&Help')
self.SetMenuBar(menubar)

toolbar = wx.ToolBar(self, -1)
toolbar.SetBackgroundColour('yellow')
self.tc = wx.TextCtrl(toolbar, -1, size=(100, -1))
btn = wx.Button(toolbar, ID_BUTTON, 'Ok', size=(40, 28))

toolbar.AddControl(self.tc)
toolbar.AddSeparator()
toolbar.AddControl(btn)
toolbar.Realize()
self.SetToolBar(toolbar)

self.Bind(wx.EVT_BUTTON, self.OnLaunchCommandOk, id=ID_BUTTON)
self.Bind(wx.EVT_MENU, self.OnAbout, id=ID_ABOUT)
self.Bind(wx.EVT_MENU, self.OnExit, id=ID_EXIT)
self.Bind(wx.EVT_TIMER, self.OnTimer, id=ID_TIMER)

self.panel = wx.Panel(self, -1, (0, 0), (500 , 300))
self.panel.SetBackgroundColour('GRAY')
self.sizer=wx.BoxSizer(wx.VERTICAL)
self.sizer.Add(self.panel, 1, wx.EXPAND)
self.SetSizer(self.sizer)
self.statusbar = self.CreateStatusBar()
self.statusbar.SetStatusText('Welcome to Isabelle')
self.Centre()
self.Show(True)

def OnExit(self, event):
dlg = wx.MessageDialog(self, 'Are you sure to quit Isabelle?',
   'Please Confirm', wx.YES_NO | 
wx.NO_DEFAULT | wx.ICON_QUESTION)

if dlg.ShowModal() == wx.ID_YES:
self.Close(True)


def OnAbout(self, event):
dlg = wx.MessageDialog(self, 'Isabelle\t\n' '2004\t', 'About',
   wx.OK | wx.ICON_INFORMATION)
dlg.ShowModal()
dlg.Destroy()


def OnLaunchCommandOk(self, event):
input = self.tc.GetValue()
if input == '/bye':
self.OnExit(self)
elif input == '/about':
self.OnAbout(self)
elif input == '/bell':
wx.Bell()
else:
self.statusbar.SetBackgroundColour('RED')
self.statusbar.SetStatusText('Unknown Command')
self.statusbar.Refresh()
self.timer.Start(50)

self.tc.Clear()

def OnTimer(self, event):
self.blick = self.blick + 1
if self.blick == 25:
self.statusbar.SetBackgroundColour('#E0E2EB')
self.statusbar.Refresh()
self.timer.Stop()
self.blick = 0

app = wx.App()
Isabelle(None, -1, 'Isabelle')
app.MainLoop()

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/552540ab.7010...@jfcomputer.com


Re: [dabo-users] Consultation on the evolution of Dabo

2015-10-01 Thread john

On 10/01/2015 05:55 AM, Werner wrote:

Hi Carlos,

On 10/1/2015 14:14, Carlos Miguel FARIAS wrote:

Given the availability of wxpython start phoenix, which allows working
with python 3.x.
What are the chances that Dabo is transformed these versions ?
We could collaborate in this process ?
I have done some work on that (using Python 3.4, note there is no 
build yet for 3.5), but lately there has been no progress as some 
problems need to be resolved in wxPython Phoenix (i.e. Robin Dunn). 
IIRC the biggest issue has to do with the wx.grid.


The repo see the branch "phoenix-2ndtry" here:
https://github.com/dabodev/dabo/tree/phoenix-2ndtry

Check out the messages on dabo-dev with a subject containing "phoenix" 
and the same on wxPython-dev, sorry there is no condensed list of 
things outstanding.


In the code there are some "TODO: Phoenix" remarks, but I don't 
guarantee that I noted it all(:


Robin hasn't done a lot lately, at least no public commits, but I 
understand that he is working on things.


Regards
Werner
___

Carlos there is a version supporting Python 3.x (check out git) using 
python 2.x.  But without Phoenix being in some sort of stable (even if 
it has bugs) condition I doubt Dabo can move forward. Believe me I want 
it too.  We have been waiting a long time for Phoenix to be delivered.


That said, the latest version (I call it Dabo2) has been stable for me.  
Dabo2 is not really ready for Phoenix and python 3.x but I have been 
able to run small apps using python 3.4 (thanks to Werner's code).  Of 
course it requires making changes to the base code but it can be done.


The big thing about Dabo is the interface it has with data.  The simple 
way it allows you to work with databases and the user interaction with 
that data.  Once we get Phoenix I'm sure Dabo will move forward to 
python 3.x because I know others would like to use it.


BTW Werner's short comment about the wx.Grid being a problem is NOT a 
simple one to fix and it is compounded by the fact Phoenix is not stable.


That said, yes we are willing to help and if you could look at the code 
and help - all would be grateful.


Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/560d36ca.8040...@jfcomputer.com


[dabo-users] Tkinter

2015-12-11 Thread john

Hi,
I'm wondering if anyone has started playing with adding Tkinker to 
Dabo.  With ttk it's not as ugly as it once was and it might be a way to 
move to python3.


Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/566b193d.90...@jfcomputer.com


Re: [dabo-users] Tkinter

2015-12-13 Thread john
That's a little sad!  We need to move Dabo forward but without Phoenix 
we are in a long term holding pattern.  I did notice that someone was 
working with the Phoenix grid and Python 3 but I only saw a few postings.


Johnf

On 12/13/2015 07:32 AM, Ed Leafe wrote:

On Dec 11, 2015, at 12:43 PM, john  wrote:


I'm wondering if anyone has started playing with adding Tkinker to Dabo.  With 
ttk it's not as ugly as it once was and it might be a way to move to python3.

Unfortunately, the event model of Tkinter (and any other GUI toolkit) is 
completely different than wx, and would require a complete re-write of the 
entire ui library. When we created Dabo, probably 95% of the effort was in 
integrating with wx, so I seriously doubt that this would be anything less than 
a major undertaking.

-- Ed Leafe







--- StripMime Report -- processed MIME parts ---
multipart/signed
   text/plain (text body -- kept)
   application/pgp-signature
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/5b6c44d6-f166-4d5e-8d71-1d2c88501...@leafe.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/566dbd8c.1080...@jfcomputer.com


Re: [dabo-users] [ADMIN] Moving servers

2016-01-04 Thread john

thanks
Johnf

On 01/03/2016 02:47 PM, Ed Leafe wrote:

First off, Happy New Year!

I'm nearly finished the process of moving all my website stuff to newer 
servers, so at sometime in the coming week I'll be redirecting the DNS to point 
to them. I'll send out another email before I flip the switch, as things may be 
off for a short while.

One thing I'm having a little trouble with is moving all the email list info 
over to the new servers. I can export all the subscription addresses, so you'll 
still get the email from the list, but if you have any custom settings, those 
may need to be reset. I'll work on this to see if I can come up with a 
migration plan, but in any event I'll let you know what's going on.

-- Ed Leafe







--- StripMime Report -- processed MIME parts ---
multipart/signed
   text/plain (text body -- kept)
   application/pgp-signature
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/27059a1f-e73d-4140-97b1-7d5780a81...@leafe.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/568a82c3.5060...@jfcomputer.com


Re: [dabo-users] [ADMIN] Moving leafe.com and dabodev.com servers

2016-01-08 Thread john

Thanks for the work you are doing!
Johnf

On 01/08/2016 07:29 AM, Ed Leafe wrote:

So things might be a little flaky and perhaps unavailable over the next few 
hours as the DNS changes percolate through the interwebs. I'll be sending out 
emails once I seem to be out of the woods.


-- Ed Leafe







--- StripMime Report -- processed MIME parts ---
multipart/signed
   text/plain (text body -- kept)
   application/pgp-signature
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/e2e94934-87a9-4ecb-bb48-e9ce1303c...@leafe.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/568fd7df.3050...@jfcomputer.com


[dabo-users] DCalendar error

2016-02-11 Thread john

Hi folks,

I'm getting the below error but it's funny because sometimes it works.  
The error is associated with a dDateTextBox and uses the extended 
Calendar as in:


dabo.ui.dDateTextBox(self, RegID ='list_start_dateID',Value = startDay, 
ExtendedCalendar = True))

The error occurs with Dabo2 and Dabo-Phoenix.

On versions of OS windows 7 and 10, and Linux using python 2.7.x, 
wxPython 3.0.x  I'm getting the following traceback:


This is the windows 10 version but is the same on Linux.
Traceback (most recent call last):
  File "h:\dabo2\dabo\ui\uiwx\dPemMixin.py", line 598, in __onWxKeyChar
self.raiseEvent(dEvents.KeyChar, evt)
  File "h:\dabo2\dabo\ui\uiwx\dPemMixin.py", line 1086, in raiseEvent
super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args, **kwargs)
  File "h:\dabo2\dabo\lib\eventMixin.py", line 81, in raiseEvent
bindingFunction(event)
  File "h:\dabo2\dabo\ui\uiwx\dDateTextBox.py", line 201, in __onChar
self.adjustDate(key, ctrl, shift)
  File "h:\dabo2\dabo\ui\uiwx\dDateTextBox.py", line 334, in adjustDate
self.showCalendar()
  File "h:\dabo2\dabo\ui\uiwx\dDateTextBox.py", line 150, in showCalendar
cp = self._CalendarPanel
  File "h:\dabo2\dabo\ui\uiwx\dDateTextBox.py", line 449, in _getCalendarPanel
extended=self.ExtendedCalendar)
  File "h:\dabo2\dabo\ui\uiwx\dDateTextBox.py", line 29, in __init__
super(CalPanel, self).__init__(parent, pos=pos)
  File "h:\dabo2\dabo\ui\uiwx\dPanel.py", line 275, in __init__
attProperties=attProperties, *args, **kwargs)
  File "h:\dabo2\dabo\ui\uiwx\dPanel.py", line 250, in __init__
properties=properties, attProperties=attProperties, *args, **kwargs)
  File "h:\dabo2\dabo\ui\uiwx\dPanel.py", line 40, in __init__
properties=properties, attProperties=attProperties, *args, **kwargs)
  File "h:\dabo2\dabo\ui\uiwx\dPemMixin.py", line 212, in __init__
self._afterInit()
  File "h:\dabo2\dabo\ui\uiwx\dPemMixin.py", line 342, in _afterInit
self.afterInit()
  File "h:\dabo2\dabo\ui\uiwx\dDateTextBox.py", line 39, in afterInit
self.cal.Date = self.date
  File "h:\dabo2\dabo\ui\uiwx\dCalendar.py", line 228, in _setDate
evt = evtClass(self, self._evtCalDayType)
  File "C:\Python27\lib\site-packages\wx-3.0-msw\wx\calendar.py", line 197, in 
__init__
_calendar.CalendarEvent_swiginit(self,_calendar.new_CalendarEvent(*args, 
**kwargs))
TypeError: Required argument 'type' (pos 3) not found

Anybody know how to fix it?

Johnf





--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/56bcdc53.5060...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-04-26 Thread john

The simple answer is YES.  You will need Dabo2 and not the standard one.
There is a version on github but it a little out of date.  So I just 
send you one.


Johnf

On 04/26/2016 08:46 AM, Sibylle Koczian wrote:

Hello,

I've upgraded my Xubuntu installation from 15.10 to 16.04 yesterday 
and couldn't start the first Dabo application I tried, because 
wxpython wasn't installed any more. There is no package python-wxgt2.? 
any more, only python-wxgtk3.0. So I installed that and got this 
exception:


sib@gespenst-xubuntu:~/src/dabo/demo$ ./DaboDemo.py
Traceback (most recent call last):
  File "./DaboDemo.py", line 24, in 
main()
  File "./DaboDemo.py", line 20, in main
app.start()
  File "/home/sib/src/dabo/dabo/dApp.py", line 388, in start
self.setup()
  File "/home/sib/src/dabo/dabo/dApp.py", line 340, in setup
self.initUIApp()
  File "/home/sib/src/dabo/dabo/dApp.py", line 380, in initUIApp
self.uiApp.setup()
  File "/home/sib/src/dabo/dabo/ui/uiwx/uiApp.py", line 433, in setup
frm = self.dApp.MainForm = dabo.ui.createForm(mfc)
  File "/home/sib/src/dabo/dabo/ui/uiwx/__init__.py", line 1356, in 
createForm

frm = cls(*args, **kwargs)
  File "/tmp/tmp7FMZLl.py", line 18, in __init__
super(dForm_23131, self).__init__(parent=parent, 
attProperties=attProperties, *args, **kwargs)

  File "/home/sib/src/dabo/dabo/ui/uiwx/dForm.py", line 1044, in __init__
*args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dForm.py", line 40, in __init__
attProperties=attProperties, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dFormMixin.py", line 76, in 
__init__

attProperties=attProperties, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dPemMixin.py", line 202, in 
__init__

self._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dForm.py", line 58, in _afterInit
super(BaseForm, self)._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dFormMixin.py", line 96, in 
_afterInit

self.MenuBar = mbc()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenuBar.py", line 21, in 
__init__
pm.dPemMixin.__init__(self, preClass, None, properties, *args, 
**kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dPemMixin.py", line 202, in 
__init__

self._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dBaseMenuBar.py", line 184, in 
_afterInit

self.fileMenu = self.appendMenu(FileMenu(self, MenuID="base_file"))
  File "/home/sib/src/dabo/dabo/ui/uiwx/dBaseMenuBar.py", line 26, in 
__init__

super(FileMenu, self).__init__(*args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 47, in __init__
attProperties=attProperties, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dPemMixin.py", line 202, in 
__init__

self._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dBaseMenuBar.py", line 43, in 
_afterInit

help=_("Open up a debug output window"))
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 255, in append
menutype=menutype, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 238, in 
_createMenuItem
item = _actualCreation(caption, help, picture, menutype, *args, 
**kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 232, in 
_actualCreation

_item.Caption = caption
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenuItem.py", line 95, in 
_setCaption

self._redefine()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenuItem.py", line 72, in 
_redefine

self.SetBitmap(self.Icon)
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk2/wx/_core.py", 
line 12543, in SetBitmap

return _core_.MenuItem_SetBitmap(*args, **kwargs)
wx._core.PyAssertionError: C++ assertion "Assert failure" failed at 
../src/gtk/menu.cpp(724) in SetBitmap(): only normal menu items can 
have bitmaps

sib@gespenst-xubuntu:~/src/dabo/demo$

Is it possible to run Dabo using wxPython 3 (which still calls itself 
"classic", so it's not the Phoenix version for Python 3)?


Greetings,
Sibylle

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/711e94b2-3bff-a402-88db-712bd395d...@t-online.de


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/571f8e70.2050...@jfcomputer.com


Re: [dabo-users] dabo2

2016-04-27 Thread john

H -
The problem of debugging the DaboDemo.py is the code is running code 
that is dynamic.  I'll look into to it but it maybe some time from now.


Johnf

On 04/27/2016 09:01 AM, Sibylle Koczian wrote:

Hello,

Am 26.04.2016 um 17:56 schrieb john:

Hi,
I'm not sure what if anything I might have that is not strictly dabo in
this file - but I didn't want you to have to wait for a response.

Johnf


Same exception as with the original Dabo. I don't quite understand 
that, because the date of your dMenu.py, dMenuItem.py is much later 
than the date of that "classic" wxgtk3.0 I've got in my Ubuntu machine.


It's not really urgent, because I've Dabo on a second virtual machine 
running Debian Jessie which still comes with wxgtk2.8.


I'm sending this to the list again, perhaps somebody will know more.

Greetings,
Sibylle
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/c5c719f1-0b71-970d-883e-fc7a30806...@t-online.de


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/5720ecf0.2000...@jfcomputer.com


Re: [dabo-users] dabo2

2016-04-27 Thread john
Would you please provide what version wxPython you are using 
(wx.__version__).  BTW running 3.0.2.0 (the latest version I know about) 
I get no errors on windows or openSUSE Leap 42. So everything I have is 
working with a few minor issues that I do not see when programming real 
apps.


Johnf

On 04/27/2016 09:01 AM, Sibylle Koczian wrote:

Hello,

Am 26.04.2016 um 17:56 schrieb john:

Hi,
I'm not sure what if anything I might have that is not strictly dabo in
this file - but I didn't want you to have to wait for a response.

Johnf


Same exception as with the original Dabo. I don't quite understand 
that, because the date of your dMenu.py, dMenuItem.py is much later 
than the date of that "classic" wxgtk3.0 I've got in my Ubuntu machine.


It's not really urgent, because I've Dabo on a second virtual machine 
running Debian Jessie which still comes with wxgtk2.8.


I'm sending this to the list again, perhaps somebody will know more.

Greetings,
Sibylle
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/c5c719f1-0b71-970d-883e-fc7a30806...@t-online.de


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/5720f13b.7000...@jfcomputer.com


Re: [dabo-users] dabo2

2016-04-28 Thread john

Of course.
Johnf

On 04/28/2016 01:38 AM, Angelo Moscati wrote:

Can we also receive the updated dabo2?

Thanks,
Angelo
On Apr 27, 2016 8:05 PM, "john"  wrote:


Would you please provide what version wxPython you are using
(wx.__version__).  BTW running 3.0.2.0 (the latest version I know about) I
get no errors on windows or openSUSE Leap 42. So everything I have is
working with a few minor issues that I do not see when programming real
apps.

Johnf

On 04/27/2016 09:01 AM, Sibylle Koczian wrote:


Hello,

Am 26.04.2016 um 17:56 schrieb john:


Hi,
I'm not sure what if anything I might have that is not strictly dabo in
this file - but I didn't want you to have to wait for a response.

Johnf


Same exception as with the original Dabo. I don't quite understand that,
because the date of your dMenu.py, dMenuItem.py is much later than the date
of that "classic" wxgtk3.0 I've got in my Ubuntu machine.

It's not really urgent, because I've Dabo on a second virtual machine
running Debian Jessie which still comes with wxgtk2.8.

I'm sending this to the list again, perhaps somebody will know more.

Greetings,
Sibylle
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance:
http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message:
http://leafe.com/archives/byMID/c5c719f1-0b71-970d-883e-fc7a30806...@t-online.de


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance:
http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message:
http://leafe.com/archives/byMID/5720f13b.7000...@jfcomputer.com



--- StripMime Report -- processed MIME parts ---
multipart/alternative
   text/plain (text body -- kept)
   text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/caf_xfgwvg_zgrol4swv2bmos4ljjfkxpwh9mjugafr2nrdp...@mail.gmail.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/57221004.9030...@jfcomputer.com


[dabo-users] dabo 2 but no git branch

2016-04-28 Thread john

Hi Everyone,

Let me explain why I haven't created a branch for Dabo2 (btw that is not 
completely true).


Werner and I (also Neil Flowers) started working toward creating a 
version of Dabo that would work with python 3 and wxPython Phoenix. I'll 
guess and say that was way over a year ago.  There are at least three 
branches on github covering that work.  I can't recall their names at 
the moment but they are there.  But as we all know Phoenix development 
just stopped.  Phoenix was never completed.
Good News - I believe as of yesterday development will restart with 
Andrea (the author of the many AGW features/controls in wxPython 3.x) as 
the captain.  Let's hope.  So as a result Dabo 3 development(that's what 
I call it) just stopped too.  All that work is available on GitHub.


About 16 months ago wxPython 3.x became stable but still used python 2.  
Soon after Neil Flowers and I started work on supporting wxPython 3.x.  
We started with the work that was done to support Phoenix.  Neil 
submitted the work (it's on github) and is available to anyone.  Of 
course I had my copy of the work and I started using it for my daily 
client work.  I found many issues at first but I fixed them to work for 
me.  That my friends is why I did not commit the work.  You see, I took 
short cuts - ones that I knew that would be not right for the general 
use of Dabo.  In fact I'm sort of sure that a few things I coded will 
not work in the Mac world.  I don't have a Mac so I can't really be 
sure.  Also international concerns were just tossed out the window.  My 
work is done in the USA and I didn't want to see a bug because of 
unicode.  So unicode sort went bye bye.



So you are saying that I should commit anyway in my own branch.  The 
bottom line is I did not want to commit and have some programmer think 
the junk I did was any sort of reflection of the good work of the Dabo 
team.  I still feel that way.  I also know that the work Neil and I did 
does work for most of Dabo.  I think the report designer doesn't work on 
Linux and many other issues are there too. It also has a lot of the code 
supporting Phoenix (if Phoenix do this else do something ).  But it's 
available and is just an OK starting point.  In fact some of my Dabo 2 
still has those issues.  But I did not need the report designer working 
under Linux (I hand code the xml anyway for reports) and if I did need 
the report designer I have a windows VM available.


I have given my code to others - but I believe they understand what they 
are getting - and I'm willing to provide my code if you ask. But I truly 
believe you are better off using the code Neil and I developed.  So I'm 
not going to create a new branch with my code.


Thanks,

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/574a.3000...@jfcomputer.com


Re: [dabo-users] your Dabo emails

2016-04-28 Thread john
I have tested on all of the windows VM's I have including xp,vista,7, 
and 10.


Yes you are correct that this is an issue with the standard dabo menu 
(file, edit, etc..).  I'm sort of concerned because the error is from 
core.py and I have been stopped there in the past -I'm not any sort c 
guy.  But sooner or later I have a work around.


Can you run the wxPython demo?  Find something that creates a top menu 
(I think MDIWindows does).  Even running the demo creates a top menu.


As a short cut you might want to comment out the SetBitmap statement.  
Just to see if it works.  The standard menu does not use bitmaps.


Ubuntu 1604 is to new (just two days right?) for me to do any testing. I 
normally wait a month or two.

Johnf

On 04/28/2016 07:55 AM, Sibylle Koczian wrote:

Hello,

Am 27.04.2016 um 21:26 schrieb john:

Hi,

First you are able to post. Are I wouldn't typing this.  For the rest of
it you will have to contact Ed (I'd do it directly because he doesn't
check the emails as often as in the past).



I got a mail by Ed with information from the logs, and I sent this to 
my ISP. Hopefully they will tell me what's the matter. If not I'll 
change over to my second email account with another provider.



As far as you problem I looking into the issue.

Would you please provide what version wxPython you are using
(wx.__version__).  BTW I'm running 3.0.2.0 (the latest version I know
about) I get no errors on windows or openSUSE Leap 42. So everything I
have is working with a few minor issues that I do not see when
programming real apps.

My guess is you have a different version.



No, it's 3.0.2.0. The funny thing is: I get exactly the same exception 
with my old dabo version (0.9.14) and with the version you sent me. It 
seems the calls to dMenuItem.py are the same and they lead to the 
PyAssertionError from wx._core. And I get this in the Python shell 
with these commands:


import dabo
dabo.ui.loadUI("wx")
app = dabo.dApp()
app.start()

So it's not my application. It begins to look like an Ubuntu problem; 
I'll try with Windows. What Windows version are you using?


Thank you for your help,
Sibylle



___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/57223a9b.40...@jfcomputer.com


Re: [dabo-users] Dabo2 on Ubuntu 16.04

2016-05-01 Thread john
So we know that the wxPython demo is running on your Linux - that's 
good.  That at least says we can get Dabo working as long as we figure 
out what's is happening.
It been my experience that the error message sometimes points us in the 
wrong direction.  I'm guessing this might be one of those cases.


On windows 10 you suggested that some of your programs are running - is 
that right?  Or are you talking about Dabo Demo?  Can you provide a 
small script that does not work?  Also what is not working - I mean does 
the program start but runs incorrectly or some other thing is 
happening?  If the Dabo Demo at least starts that means it's getting 
past your error with the menu.


I will have a little time coming this week and I will try to download 
ubuntu and see if I can repeat your error.


Oh one more thing - make sure you are running .py and not .pyc for the 
testing.


Johnf





On 05/01/2016 06:45 AM, Sibylle Koczian wrote:

Hello,

as I'm getting mails from the list again, I'm sending to the list.

Am 28.04.2016 um 18:30 schrieb john:

I have tested on all of the windows VM's I have including xp,vista,7,
and 10.

I've tried the dabo2 I got from you on windows 10: some things work, 
some don't, without any changes (SetBitmap not commented out from 
dMenuItem.py). I don't yet know what works and what doesn't. The 
wxPython demo runs.



Yes you are correct that this is an issue with the standard dabo menu
(file, edit, etc..).  I'm sort of concerned because the error is from
core.py and I have been stopped there in the past -I'm not any sort c
guy.  But sooner or later I have a work around.

Can you run the wxPython demo?  Find something that creates a top menu
(I think MDIWindows does).  Even running the demo creates a top menu.


Exactly. And it works and shows icons (bitmaps or other formats?).


As a short cut you might want to comment out the SetBitmap statement.
Just to see if it works.  The standard menu does not use bitmaps.

That helps, now I can start some of my applications, but not all of 
them. At least one application that is unusable on Windows works on 
the Linux machine. Something definitely not working right is the 
ClassDesigner.


What sort of tests would be helpful?


Ubuntu 1604 is to new (just two days right?) for me to do any testing. I
normally wait a month or two.
Quite true, this time I was very quick with the upgrade. But I've 
always got Debian besides - or I would wait too. Most of the time I'm 
using the Debian machine anyway.


Thank you for your help,
Sibylle


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/c992960c-48bb-1b9d-4310-3d9407867...@t-online.de


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572625c2.5070...@jfcomputer.com


Re: [dabo-users] dabo 2

2016-05-03 Thread john

The Dabo "stable" version only supports wxPython 2.8.

That is the real answer - only wxPython 2.8.x is supported.  I believe 
the stable version is the working version on github.  I could be wrong 
as I haven't played with the working version for sometime.


But we all know that wxPython 2.8 is very much outdated.  In fact 
wxPython 3.0.2.0 has been out for almost 17 months.  So why hasn't Dabo 
moved forward?


The answer is because of wxPython Phoenix.  When Phoenix was announced 
it was assumed that Dabo would move to Phoenix and python 3.x when 
Phoenix was stable - never happened.  I think it's been over two years 
since there has been any real work done on Phoenix.


Because of the time delay Neil Flowers and I decided we would try to get 
wxPython 3.x running with Dabo.  And the work is in a github branch of 
Dabo called dabo2

https://github.com/dabodev/dabo/tree/dabo2

It works with wxPython 3.x - that said - it is NOT a stable version!  If 
you believe you have need of wxPython 3.x use the dabo2 branch.


My code contains a few changes that I needed and I doubt will be helpful 
for the general public and it is doubtful that those changes are cross 
platform.  And I do NOT feel comfortable putting my code on github for 
the world to access.


Johnf

On 05/03/2016 12:05 PM, Angelo Moscati wrote:

Another question.
You said "may have many missing features that the stable version may 
have".
Can you tell me in which branch is developed the stable version? I see 
in GitHub a master branch as well as working branch which it has the 
latest commit from you.


Thanks,
Angelo

On Tue, May 3, 2016 at 9:58 PM, Angelo Moscati <mailto:mosc...@gmail.com>> wrote:


Thanks

On Thu, Apr 28, 2016 at 4:36 PM, john mailto:jo...@jfcomputer.com>> wrote:

Please realize this is my version of Dabo to support the use
of wxPython 3.x.  It works but is not complete and may have
many missing features that the stable version may have.

I have been using it for my work and it has worked well on
windows and Linux.  That said, Sibylle reported a major bug on
the latest Ubuntu.

Also the folder may contain some unneeded files and plain junk.

Johnf







--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/5729753e.6040...@jfcomputer.com


Re: [dabo-users] dabo 2 but no git branch

2016-05-04 Thread john
Paul, there is no other way to say this - I believe the code is junk!  I 
don't want to give code to world that I consider to be junk.  Yes it 
works but I'm not very proud that I took short cuts. I just needed it to 
work for me.


Johnf

On 05/04/2016 11:02 AM, Paul McNett wrote:

On 4/28/16 7:46 AM, john wrote:

I have given my code to others - but I believe they understand what they
are getting - and I'm willing to provide my code if you ask. But I truly
believe you are better off using the code Neil and I developed. So I'm
not going to create a new branch with my code.


I think the correct thing for you to do John is to share your dabo 
fork with the world on github. Kudos for charging on!


Paul

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/572a3933.3050...@mcnettware.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572a3ad0.1010...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-04 Thread john
I installed Ubuntu 16.04 (a VM) today and I got the same error message.  
This will take a while to figure out.  But I'm starting.


BTW Ubuntu drives me crazy with SUDO stuff.

Johnf

On 04/26/2016 08:46 AM, Sibylle Koczian wrote:

Hello,

I've upgraded my Xubuntu installation from 15.10 to 16.04 yesterday 
and couldn't start the first Dabo application I tried, because 
wxpython wasn't installed any more. There is no package python-wxgt2.? 
any more, only python-wxgtk3.0. So I installed that and got this 
exception:


sib@gespenst-xubuntu:~/src/dabo/demo$ ./DaboDemo.py
Traceback (most recent call last):
  File "./DaboDemo.py", line 24, in 
main()
  File "./DaboDemo.py", line 20, in main
app.start()
  File "/home/sib/src/dabo/dabo/dApp.py", line 388, in start
self.setup()
  File "/home/sib/src/dabo/dabo/dApp.py", line 340, in setup
self.initUIApp()
  File "/home/sib/src/dabo/dabo/dApp.py", line 380, in initUIApp
self.uiApp.setup()
  File "/home/sib/src/dabo/dabo/ui/uiwx/uiApp.py", line 433, in setup
frm = self.dApp.MainForm = dabo.ui.createForm(mfc)
  File "/home/sib/src/dabo/dabo/ui/uiwx/__init__.py", line 1356, in 
createForm

frm = cls(*args, **kwargs)
  File "/tmp/tmp7FMZLl.py", line 18, in __init__
super(dForm_23131, self).__init__(parent=parent, 
attProperties=attProperties, *args, **kwargs)

  File "/home/sib/src/dabo/dabo/ui/uiwx/dForm.py", line 1044, in __init__
*args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dForm.py", line 40, in __init__
attProperties=attProperties, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dFormMixin.py", line 76, in 
__init__

attProperties=attProperties, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dPemMixin.py", line 202, in 
__init__

self._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dForm.py", line 58, in _afterInit
super(BaseForm, self)._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dFormMixin.py", line 96, in 
_afterInit

self.MenuBar = mbc()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenuBar.py", line 21, in 
__init__
pm.dPemMixin.__init__(self, preClass, None, properties, *args, 
**kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dPemMixin.py", line 202, in 
__init__

self._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dBaseMenuBar.py", line 184, in 
_afterInit

self.fileMenu = self.appendMenu(FileMenu(self, MenuID="base_file"))
  File "/home/sib/src/dabo/dabo/ui/uiwx/dBaseMenuBar.py", line 26, in 
__init__

super(FileMenu, self).__init__(*args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 47, in __init__
attProperties=attProperties, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dPemMixin.py", line 202, in 
__init__

self._afterInit()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dBaseMenuBar.py", line 43, in 
_afterInit

help=_("Open up a debug output window"))
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 255, in append
menutype=menutype, *args, **kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 238, in 
_createMenuItem
item = _actualCreation(caption, help, picture, menutype, *args, 
**kwargs)
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenu.py", line 232, in 
_actualCreation

_item.Caption = caption
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenuItem.py", line 95, in 
_setCaption

self._redefine()
  File "/home/sib/src/dabo/dabo/ui/uiwx/dMenuItem.py", line 72, in 
_redefine

self.SetBitmap(self.Icon)
  File "/usr/lib/python2.7/dist-packages/wx-3.0-gtk2/wx/_core.py", 
line 12543, in SetBitmap

return _core_.MenuItem_SetBitmap(*args, **kwargs)
wx._core.PyAssertionError: C++ assertion "Assert failure" failed at 
../src/gtk/menu.cpp(724) in SetBitmap(): only normal menu items can 
have bitmaps

sib@gespenst-xubuntu:~/src/dabo/demo$

Is it possible to run Dabo using wxPython 3 (which still calls itself 
"classic", so it's not the Phoenix version for Python 3)?


Greetings,
Sibylle

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/711e94b2-3bff-a402-88db-712bd395d...@t-online.de


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572a7aa0.50...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-04 Thread john

On 04/26/2016 08:46 AM, Sibylle Koczian wrote:


wx._core.PyAssertionError: C++ assertion "Assert failure" failed at 
../src/gtk/menu.cpp(724) in SetBitmap(): only normal menu items can 
have bitmaps

sib@gespenst-xubuntu:~/src/dabo/demo$

Is it possible to run Dabo using wxPython 3 (which still calls itself 
"classic", so it's not the Phoenix version for Python 3)?




Ok I'm in trouble at this point.
I know that your issue is related to the 'menutype= "check" ' in 
dBaseMenuBar.py.  But if I change the menuitems to just normal items the 
window will open but it will not display any menus??? (see below)  I 
also noticed that the path to the icons that dBaseMenuBar.py did not 
include 'icons'in the path.  But that didn't really help.  But I believe 
I could fix the issue - but I doubt that it's the real issue.


So what I did find is that the menu would appear when I forced the 
window to full screen and clicked on the top title bar (but without 
icons).  I'm guessing this is an issue with Ubuntu and NOT Dabo and not 
wxPython because I get exact the same issue when opening wxPython 
demo.py.  When demo.py opens with anything less than full screen the 
menu does not appear. When I open dBaseMneu.py with anything other than 
full screen the menu does not appear (this is after I removed the 
menutype as check).  IOW the menu will appear if I force the 
frame/window to full screen but you have to click on the title bar.


I really don't know Ubuntu at all.  Maybe this is some setting that has 
to be changed - sort of like how windows can hide the bottom icon bar.


I haven't move to Ubuntu  because I don't like Unity.  And now I have 
one more reason!


So Sibylle, maybe you can tell me how to change the way Unity works to 
allow the menu to appear anytime the window is open?


Johnf







--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572aa32e.2000...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-04 Thread john

You might want to check out this:
http://askubuntu.com/questions/762137/applications-menu-missing-from-menu-bar

Johnf

On 05/04/2016 06:34 PM, john wrote:

On 04/26/2016 08:46 AM, Sibylle Koczian wrote:


wx._core.PyAssertionError: C++ assertion "Assert failure" failed at 
../src/gtk/menu.cpp(724) in SetBitmap(): only normal menu items can 
have bitmaps

sib@gespenst-xubuntu:~/src/dabo/demo$

Is it possible to run Dabo using wxPython 3 (which still calls itself 
"classic", so it's not the Phoenix version for Python 3)?




Ok I'm in trouble at this point.
I know that your issue is related to the 'menutype= "check" ' in 
dBaseMenuBar.py.  But if I change the menuitems to just normal items 
the window will open but it will not display any menus??? (see below)  
I also noticed that the path to the icons that dBaseMenuBar.py did not 
include 'icons'in the path.  But that didn't really help.  But I 
believe I could fix the issue - but I doubt that it's the real issue.


So what I did find is that the menu would appear when I forced the 
window to full screen and clicked on the top title bar (but without 
icons).  I'm guessing this is an issue with Ubuntu and NOT Dabo and 
not wxPython because I get exact the same issue when opening wxPython 
demo.py.  When demo.py opens with anything less than full screen the 
menu does not appear. When I open dBaseMneu.py with anything other 
than full screen the menu does not appear (this is after I removed the 
menutype as check).  IOW the menu will appear if I force the 
frame/window to full screen but you have to click on the title bar.


I really don't know Ubuntu at all.  Maybe this is some setting that 
has to be changed - sort of like how windows can hide the bottom icon 
bar.


I haven't move to Ubuntu  because I don't like Unity.  And now I have 
one more reason!


So Sibylle, maybe you can tell me how to change the way Unity works to 
allow the menu to appear anytime the window is open?


Johnf









--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572aa4b7.3080...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-05 Thread john

On 05/05/2016 01:26 AM, Sibylle Koczian wrote:
I think you're right: this seems to be Ubuntu, and moreover not every 
Ubuntu flavour. I wasn't clear enough about my installation: I'm using 
Xubuntu, which is Ubuntu with the XFCE desktop. Never looked at Unity. 
If I comment out the SetBitmaps() call from dMenuItem.py I get the 
menu quite normally, even most of the icons are there. So I'd suspect 
a Unity problem, not Dabo, not wxPython and not even Ubuntu as a 
distribution.


I get other Dabo problems, though, which I'll show as soon as I've got 
a small example.
Oh I tried all of the solutions in the link I provided.  As the link 
suggested it's not just wxPython but almost any GTK program I ran - 
including gedit.


The only issue with just commenting out the SetBitmaps() is you will 
lose function.  The checkbox and the icons are suppose to be there and 
work.  That said, on production code I remove/replace the tools under 
the 'File' menu so I guess you don't really need the icons because the 
hot-key will work.


One other hint - I deleted all of the pyc files.  After restarting and 
completing the re-compile I got a very noticeable increase in 
performance.  I used 'find / -name "*.pyc" -delete.


Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572b493d.2000...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-05 Thread john

On 05/05/2016 07:45 AM, Sibylle Koczian wrote:
At the moment it's only one problem: dForm.next() doesn't work with 
Dabo 2. Example given below.


Of course it doesn't - it's the only one that is called differently 
"next(self)' instead of self.next().  And the routines are recursive.  
I'll check into the problem and see what I can find.  I don't normally 
use next() for anything (actually I don't use any of the move methods) 
in my programs.


Thanks for the code.  BTW I normally pass the Datasource and that might 
a source of the issue - just guessing!


Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572b8eb2.6020...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-05 Thread john

On 05/05/2016 11:19 AM, john wrote:

On 05/05/2016 07:45 AM, Sibylle Koczian wrote:
At the moment it's only one problem: dForm.next() doesn't work with 
Dabo 2. Example given below.


Of course it doesn't - it's the only one that is called differently 
"next(self)' instead of self.next().  And the routines are recursive.  
I'll check into the problem and see what I can find.  I don't normally 
use next() for anything (actually I don't use any of the move methods) 
in my programs.


Thanks for the code.  BTW I normally pass the Datasource and that 
might a source of the issue - just guessing!


Johnf


OK I haven't been able to fix the next().  This is not the first time 
I've had this trouble (had it even with the old Dabo).  If I had to 
guess I would say that neither Sqlite or Postgres dbapi modules 
(sqlite3, psycopg) have a "__iter__" method.  Ed and Paul worked mostly 
with MySQLdb which does have the "__iter__".  They may have thought all 
database modules had it.  But I don't really know. Anyway, that's why I 
think we get the "StopIteration:" exception. Of course this is just a 
guess and I could be completely wrong!


In the past I have always just made my own next() by:
Create my own next method and then do
get the cursor
get the current pk
add one to the pk
movetoPK(pk)

This works for me because all my PK's are integers.  It would not work 
for other types of PK's.


I've written dabo-dev asking how next() is suppose work.  Let's hope 
that they have an answer and maybe a fix.


Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572bf8a1.1020...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-06 Thread john



On 05/05/2016 06:51 PM, john wrote:
If I had to guess I would say that neither Sqlite or Postgres dbapi 
modules (sqlite3, psycopg) have a "__iter__" method. 



I'm sorry I misspoke in the above.  What I mean is that I have not 
discovered a way to expose the__iter__ method to allow my use.  I 
realize that Sqlite and Psycopg2 have the method I just can't get them 
to work.  With MySQL.cursor I can see the __iter__.next method.  It's 
there and easy to see and it works.  With psycopg2 I can't just say 
psycopg.cursor.__iter__.next(). Because it does not work.


Maybe there is some other way to call this or it needs some sort of data?

Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572cad8d.4000...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-06 Thread john

On 05/06/2016 07:43 AM, john wrote:



On 05/05/2016 06:51 PM, john wrote:
If I had to guess I would say that neither Sqlite or Postgres dbapi 
modules (sqlite3, psycopg) have a "__iter__" method. 



I'm sorry I misspoke in the above.  What I mean is that I have not 
discovered a way to expose the__iter__ method to allow my use.  I 
realize that Sqlite and Psycopg2 have the method I just can't get them 
to work.  With MySQL.cursor I can see the __iter__.next method.  It's 
there and easy to see and it works.  With psycopg2 I can't just say 
psycopg.cursor.__iter__.next(). Because it does not work.


Maybe there is some other way to call this or it needs some sort of data?

Johnf


BTW here is the source for __iter__

def__iter__(self):ifself._prefetch:res 
=super(DictCursorBase,self).__iter__()first 
=res.next()ifself._query_executed:self._build_index()ifnotself._prefetch:res 
=super(DictCursorBase,self).__iter__()first =res.next()yieldfirst 
while1:yieldres.next()



Of course it fails at first = res.next()

Johnf


--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572cae63.2090...@jfcomputer.com


Re: [dabo-users] Two column RadioList

2016-05-06 Thread john
I think I would subclass wx.RadioBox.  Take a look at the wxPython demo. 
Also:

http://www.tutorialspoint.com/wxpython/wx_radiobutton_radiobox.htm
In the subclass I'd add self.RegID='somestr' so I can later use the 
value inside Dabo without much trouble.


Every thing that is available in wxPython can be used in Dabo. The only 
issue of course is assigning a value to the control and reading the control.


Dabo did not setup a subclass for RadioBox.  If and when Phoenix is 
released maybe somebody will add a dRadioBox.  If you are interested you 
might want to write a dRadioBox.py.  I think following the dRadioList 
would be a good starting point.


Maybe someone has a better suggestion.

Johnf

On 06/04/2013 10:52 AM, Ricardo Aráoz wrote:

So today is Question Day...

I need to use a dRadioList, but I need it to be split in two columns 
in this way :


opt1 oopt2 o
opt3 oopt4 o
opt5 o.

Now the only example I came by in the DaboDemo is in dGrid but it's a 
short list of choices and only one column. Haven't been able to find 
any mention of columns in the API reference.

Is there a way to do it?

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: 
http://mail.leafe.com/mailman/listinfo/dabo-users

Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/51ae2971.6020...@gmail.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572d0779.3090...@jfcomputer.com


[dabo-users] Having fun!

2016-05-06 Thread john

Hi everyone,

I haven't really used Dabo for sometime - maybe 6 months or more. I 
started a new project - a python CRUD app.  I had forgotten how much fun 
and a pleasure Dabo is to use!


I don't know how many times I have said this - but it's not enough!

THANK YOU ED AND PAUL for Dabo!  :-)

Johnf
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572d0e75.7040...@jfcomputer.com


Re: [dabo-users] Dabo and wxPython ("classic") 3.0

2016-05-07 Thread john

On 05/07/2016 03:46 AM, Sibylle Koczian wrote:

Am 06.05.2016 um 16:46 schrieb john:

On 05/06/2016 07:43 AM, john wrote:

BTW here is the source for __iter__



Which __iter__, in which class?


def__iter__(self):ifself._prefetch:res
=super(DictCursorBase,self).__iter__()first
=res.next()ifself._query_executed:self._build_index()ifnotself._prefetch:res 


=super(DictCursorBase,self).__iter__()first =res.next()yieldfirst
while1:yieldres.next()




This has been badly mangled on the way, as you see. I failed to 
restore the missing indentation at the second "if". Could you try 
again, or tell me where this comes from?


Thank you,
Sibylle

Sorry about that - the code is from psycopg2.extras. Which is the way I 
get a DictCursor.


https://github.com/psycopg/psycopg2/blob/master/lib/extras.py

That's where code is stored.

Johnf

___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/572de7f6.3090...@jfcomputer.com


Re: [dabo-users] Web Update

2016-07-06 Thread john

I agree.  Although, there should be a link to the download that works.
Johnf

On 07/06/2016 08:58 AM, Ed Leafe wrote:

I’d like to get an idea as to how many people are relying on web update to 
update their Dabo code. The reason is that I’m thinking of retiring the server 
that handles web update, and wanted to make sure that it isn’t going to be too 
impactful.

I’ve looked through the logs, and it seems that there are very few hits to the 
web update API. So unless there is some strong case for continuing to support 
web update, I think it’s time to get rid of the service.


-- Ed Leafe





___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/0d7151a8-abb0-41c4-8f31-8f23fafe0...@leafe.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/577d2e21.6020...@jfcomputer.com


Re: [dabo-users] Web Update

2016-07-06 Thread john

Interesting - the links seem to be working.

Johnf

On 07/06/2016 09:30 AM, Ed Leafe wrote:

On Jul 6, 2016, at 11:13 AM, john  wrote:

Although, there should be a link to the download that works.

I assume that this implies that there is a download link that *doesn’t* work. 
Care to be more specific?


-- Ed Leafe





___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/4515717b-75d5-46ae-9125-e21cdcd56...@leafe.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/577d4d76.6020...@jfcomputer.com


Re: [dabo-users] Tab-Index of UI-Objects?

2017-01-11 Thread john

How did you create the UI form?  Did you use the class designer?

Or did you manually create each of the controls - something like:

dabo.ui.dTextBox(self, RegID="CaseID",Width=225, DataSource = 
'public.esenroll', DataField = 'caseno')


Normally, the order or tab order is set to match top to bottom and left 
to right within a panel (and of course a sizer can also influence the 
order).  There is one property 'TabStop' True or False that is available.


That said, take a look at dDialog.py around line 365:
for pos, btn in enumerate(buttons[1:]):
btn.MoveAfterInTabOrder(buttons[pos-1])

The above is used for the class->_addControls.

Johnf
On 01/11/2017 08:26 AM, Max Voß wrote:

Hello,

is it possible to set a kind of tab-index in a dabo-Form?

I have got a dPage-Object with a lot of dTextBoxes, dDropDownLists and
so on but they appear in a different order on the Page than I want to
step through them with the tabulator-key. The "tab-index" seems to
depend only on the position on the Page. At least I have not found a
corresponding property in the Object Inspector. Or did I just miss it?

Thanks in advance for your anwsers,

greetings Max


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/1484151990.2212.22.ca...@optik-stahr.de


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/2b1596bb-dc87-f4ed-c942-258e11b88...@jfcomputer.com


Re: [dabo-users] ReportWriter under Windows 10

2017-01-11 Thread john
I'm not sure what is happening here because I can not repeat the error 
on my windows 10,8, or 7 VM.  Did you look at the 'self.HomeDirctory' 
value (or the value of 'val')?.  Maybe you have something in the 
string?  Any chance you have unicode?


I just realized I'm using Dabo 2.0.0  - and you are going ask me how to 
get it!  I have long forgotten the git command to retrieve it.


Contact me directly and I can forward my copy.  Before you do. What 
version of reportlab are you using - I'm using ReportLab 2.7.


Johnf


On 01/10/2017 06:12 PM, Steve Rose wrote:

I've been using dReportWriter successfully in Windows 7 for years.
However, using the same program(s) in Windows 10, I am getting the
following traceback:

Traceback (most recent call last):
   File
"C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dControlMixin.py",
line 27, in _onWxHit
 self.raiseEvent(dEvents.Hit, evt, *args, **kwargs)
   File
"C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dPemMixin.py",
line 1045, in raiseEvent
 super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args,
**kwargs)
   File
"C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\lib\eventMixin.py",
line 81, in raiseEvent
 bindingFunction(event)
   File "C:\aaa\DaboCode\CalBirds\SelectCounty1.py", line 145, in buttonGoHit
 rw.ReportFormFile =
  "C:/aaa/DaboCode/Calbirds/CountyMissingSpeciesReport2.rfxml"
   File
"C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\lib\reportWriter.py",
line 2950, in _setReportFormFile
 self.HomeDirectory = os.path.join(os.path.split(val)[:-1])[0]
   File "C:\Python27\lib\ntpath.py", line 93, in join
 return result_drive + result_path
TypeError: cannot concatenate 'str' and 'tuple' objects

---
I have no idea how to troubleshoot this.  Any hints appreciated.

Python 2.7.12 on Win 32
Dabo 0.9.4

Steve Rose


ᐧ


--- StripMime Report -- processed MIME parts ---
multipart/alternative
   text/plain (text body -- kept)
   text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/CADJJcm63fqoVX1sEbszOjs2Z4nYWd3is=joxobbzmjydnnc...@mail.gmail.com


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/6582cabd-5333-4287-7796-2f5ee7e50...@jfcomputer.com


Re: [dabo-users] Tab-Index of UI-Objects?

2017-01-13 Thread john
Personally I don't use Class Designer or a .cdxml file.  I find it very 
easy to manually create the form.  I guess I started doing because in 
the beginning the Class Designer was not easy to work with - especially 
try to add a new control or to move one.


So today I just move the control's code to the order I want and location 
required by the task.


I too like the dGridSizer.  I use it all the time and it has helped me 
with spacing, sizing, and positions of the controls within a panel.


Today the only issue I have with Dabo is the fact that wxPython does not 
have a stable version that supports python 3.x.  Of course that's not 
Dabo's fault.


To be honest I believe I will soon will be moving on to Electron (uses 
html,css,JavaScript, Chrome, NodeJS to create the ui for a desktop app).



Johnf


On 01/13/2017 01:26 AM, Max Voß wrote:

Hi Johnf, thanks for your reply.

In my last message I completely messed up the indeces, so please it
ignore it, it will only confuse you here is the correct version.

Am Mittwoch, den 11.01.2017, 08:48 -0800 schrieb john:

How did you create the UI form?  Did you use the class designer?

Or did you manually create each of the controls - something like:

dabo.ui.dTextBox(self, RegID="CaseID",Width=225, DataSource =
'public.esenroll', DataField = 'caseno')


Well, I have chosen a third way. I manualy created a .cdxml-File
(without the class designer, since my Form is huge and I don't like what
it does to my .cdxml) that looks like this: (I stripped it down to the
essentials for readability)

...









...

...

This results in the TabOrder sph_r,sph_l,cyl_r,cyl_l,...
But I want sph_r,cyl_r,ach_r,...,sph_l,cyl_l,...


Normally, the order or tab order is set to match top to bottom and left
to right within a panel (and of course a sizer can also influence the
order).

Ok, maybe I can rearange my textfields and put all *_r fields in one
dSizer and *_l fields in a second one. - To bad I really liked the
dGridSizer.


  There is one property 'TabStop' True or False that is available.

That I have found, but it is no use to me in my situation, since I want
TabStop but just a different order.


That said, take a look at dDialog.py around line 365:
  for pos, btn in enumerate(buttons[1:]):
  btn.MoveAfterInTabOrder(buttons[pos-1])

The above is used for the class->_addControls.

Johnf
On 01/11/2017 08:26 AM, Max Voß wrote:

Hello,

is it possible to set a kind of tab-index in a dabo-Form?

I have got a dPage-Object with a lot of dTextBoxes, dDropDownLists and
so on but they appear in a different order on the Page than I want to
step through them with the tabulator-key. The "tab-index" seems to
depend only on the position on the Page. At least I have not found a
corresponding property in the Object Inspector. Or did I just miss it?

Thanks in advance for your anwsers,

greetings Max






___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/6bb440d3-c863-4968-f573-12a4ad9cb...@jfcomputer.com


Re: [dabo-users] Tab-Index of UI-Objects?

2017-01-13 Thread john
I'm not leaving Django.  I have had great success with Django.  I see no 
reason to leave Django.  Django works with almost anything I've come 
across - that includes Angular, React, etc..  BTW check out 'vue'.


I am moving to Electron for desktop applications - only.  Don't get me 
wrong Dabo is more than functional.  It's just that Dabo's UI is based 
on wxPython and wxPython is preventing Dabo from moving forward and the 
use of python 3.x.  Python 2.7.x is fine but most folks are moving 
forward to 3.x.  Also wxPython (even Phoenix) is not adding any bells 
and whistles where as CSS is allowing so many in the web world.


Honestly, I'm not to sure about Electron's future.  It is using Chrome 
and I know that is not going away anytime soon.  But I have to be 
concerned that Google might drop support due to lack of general interest 
in desktop apps.  I was at first concerned with the size of an Electron 
app.  But I realized that as I added pages the size did not change 
much.  Performance is good if not better than Dabo on the desktop.  So 
there is a lot to like.



As far as NodeJS - well I like the fact that it is well supported by the 
community - but so is Django.  I don't believe NodeJS's asynchronous I/O 
is faster than Django when comes to serving data - at least not for 
small websites.  So I wouldn't leave Django for NodeJS.



Johnf


On 01/13/2017 08:17 AM, Henning Hraban Ramm wrote:

Am 2017-01-13 um 17:01 schrieb john :


To be honest I believe I will soon will be moving on to Electron (uses 
html,css,JavaScript, Chrome, NodeJS to create the ui for a desktop app).

I hear you – for web apps I’m leaving my beloved Python/Django behind for 
Meteor/Angular (i.e. also node.js).

Greetlings, Hraban
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/7745db9c-617a-43ba-b85c-7e46d832a...@fiee.net


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/4b4f07e6-c7cb-16ef-c67a-a4c2559b9...@jfcomputer.com


Re: [dabo-users] Leaving dabo/Python

2017-01-13 Thread john
The issue of deployment is real - for sure.  But I have used a both just 
creating an exe and install all on a server.  I have found the best for 
me was to install all the python stuff on the client and the rest on a 
server.  The last allows for one place to make changes.


Dabo's doc's have not helped me much.  Most of what I have learned came 
from Ed Leaf and Paul McNett and this forum.  Also I had a background 
with FoxPro and Dabo is patterned after Fox.


Johnf

On 01/13/2017 09:11 AM, Henning Hraban Ramm wrote:

As far as NodeJS - well I like the fact that it is well supported by the 
community - but so is Django.  I don't believe NodeJS's asynchronous I/O is 
faster than Django when comes to serving data - at least not for small 
websites.  So I wouldn't leave Django for NodeJS.

Django is good for many projects, and I guess I’ll continue using it for 
websites, since my workflow is comfortable enough.

But for "desktopy" web apps, where most of the coding is in JS on the Client UI 
anyway, Meteor/Angular/React seems to be the better framework. I’m still at the beginning 
of my node.js journey, but I hit too many blocks while trying to do my current project in 
Django. And using dabo, i.e. installing an app on every user’s computer, would be a 
promise for a support desaster.
I used dabo only ever as a convenient UI framework, never really needed the 
3-tier setup. I could stay on Python 2.7, but I found the availability of 
dabo’s documentation too unreliable.

Greetlings, Hraban
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/4181d4f8-1fc5-42d3-a800-5cc4dcddb...@fiee.net


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/1fcf91f5-45cf-4d32-531c-b7a8a7000...@jfcomputer.com


Re: [dabo-users] Wiki Updated

2020-05-17 Thread john

Wow - thank you very much.

Have you taken a look at wxPython 4.1.x?  There are a bunch of changes 
that will need changes in Dabo.


Johnf



On 5/17/20 9:27 AM, Ed Leafe wrote:

A few years ago when I updated the dabodev.com website, I switched from the 
original wiki software (ZWiki, running on Zope), to MediaWIki. I planned on 
migrating the old pages to the new format, but life got in the way.

A few weeks ago a relative newcomer to Dabo, Dragan Nedeljković, asked me 
about the wiki. I had the old files I had exported from ZWiki, but bit rot had 
set in, and the files were not readable. I thought all was lost, but then I 
remembered the Internet Archive! I searched it for the old wiki, and sure 
enough, the old pages live on in the Archive! None of the images were saved, 
though, so the pretty pictures are lost.

So for the past two weeks I’ve been using my free time (I got Corona’d from my 
job back in March) to convert the old pages to the new format. It’s nowhere 
near complete, but I have completed the “Framework Documentation” section, 
which contains most of the useful information we had in the archive.

https://wiki.dabodev.com/index.php?title=Framework_Documentation

I hope that this is useful to someone!


-- Ed Leafe






___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: https://leafe.com/archives
This message: 
https://leafe.com/archives/byMID/d5359498-c64a-4682-ba77-1851ccddc...@leafe.com




--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: https://leafe.com/archives
This message: 
https://leafe.com/archives/byMID/5f283744-5b48-98a8-ec43-1b9edaa24...@jfcomputer.com


Re: [dabo-users] Wiki Updated

2020-05-18 Thread john

Things I am aware of:

My guess is there is nothing available as far as a list of changes.

I am unable to install 4.1.x on my OpenSuse 15.1 - but it does install 
on ubuntu 18.


I got the menu to work on window by adding "dMenuItem = 
dabo.import_ui_name('dMenuItem')" to dPemMixin.py -> _restoreFontZoom() 
seems to work on windows 10, python 3.7.x and stopped the crashing.


dGrid (in many places) I changed
"self.SetSelectionMode(wx.grid.Grid.wxGridSelectCells)"
"self.SetSelectionMode(wx.grid.Grid.wxGridSelectRows)"
to
 "self.SetSelectionMode(wx.grid.Grid.GridSelectCells)"

"self.SetSelectionMode(wx.grid.Grid.GridSelectRows)"

That's all I currently know about.  I'm still looking.

Johnf





On 5/18/20 6:52 AM, Ed Leafe wrote:

On May 17, 2020, at 20:16, john  wrote:

Have you taken a look at wxPython 4.1.x?  There are a bunch of changes that 
will need changes in Dabo.

I have 4.1.0 installed, but haven’t had time to play with Dabo very much. I 
noticed that the demo no longer works, and anything involving menus seems to 
abend unpredictably.

Is there a list of the changes somewhere?

-- Ed Leafe






___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: https://leafe.com/archives
This message: 
https://leafe.com/archives/byMID/5b368b49-6544-401f-b6ae-ce625797b...@leafe.com




--- StripMime Report -- processed MIME parts ---
multipart/alternative
 text/plain (text body -- kept)
 text/html
---
___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: https://mail.leafe.com/mailman/listinfo/dabo-users
Searchable Archives: https://leafe.com/archives
This message: 
https://leafe.com/archives/byMID/dd584760-ec56-a01e-07d6-fceaa602b...@jfcomputer.com


Re: [dabo-users] Late to the party...

2020-06-07 Thread john

Hi,

I'm sorry but did you post what version of wxPython and Python you are 
using?


I have been working on a couple of the issues you are having and believe 
I have fixed some of them in my dabo3-4.1 branch.

for alignment I came up with this:

if self.GetOrientation() == wx.VERTICAL and layout != 'x':
    return self.insert(len(self.Children), obj, layout=layout, 
proportion=proportion,
 alignment=alignment, halign=halign,border=border, 
borderSides=borderSides)

    elif self.GetOrientation() == wx.HORIZONTAL and layout != 'x':
    return self.insert(len(self.Children), obj, layout=layout, 
proportion=proportion,

    alignment=alignment, valign=valign, border=border,
    borderSides=borderSides)
    else:
    return self.insert(len(self.Children), obj, layout=layout, 
proportion=proportion, border=border, borderSides=borderSides)


I'm not sure that it work for all of the possible settings - it is 
working for the stuff I use.


ClassDesigner is sort of working for me on Linux (didn't try on windows 
yet).  That said, I never really used ClassDesigner for much.  I believe 
I have all the demo's working (or at least opening) that normally work 
for GTK.


Also I don't see an attachment??? that you referred too.

If you are interested I would love someone to work with on the new 
version of wxPython 4.1 and Dabo3.


I have a project that I work on and it is working normally.  It has many 
other issues - like unable to use the current version of ReportLab.


Johnf


On 6/7/20 8:24 AM, Dragan Nedeljković wrote:

Дана 8.5.20. у 03:25, Ed Leafe пише:
On May 7, 2020, at 04:46, Dragan Nedeljković  
wrote:
Are you using the dabo3 branch of the code? I got a lot of things 
working under Python3, but just didn’t have the time to fix it all.
Ah... right, just went back to Git and found that what I have is the 
master branch. Downloaded dabo3, much fresher.


Will dive into it when we finish celebrating the end of curfew :)
I dug up the old export of the wiki, and was disappointed to find 
that there was no way to extract the information from it. I spent a 
few hours trying several approaches, but kept getting failures, 
usually due to binary incompatibility.


Then it hit me: the internet archive! So I went digging, and sure 
enough, the wiki lives on there! So when you finally are ready to 
play around with it, look here for the wiki documentation:


http://web.archive.org/web/20110811180826/http://wiki.dabodev.com/FrontPage 



OK, that worked and actually helped a lot. I have the first form in 
the app already doing something. Now implementing the rest of the 
stuff will be fun in the following months.


As to your suggestion to fix a few things... see attached. Search for 
#2020, I marked my comments. Nothing much, just changes I had to make 
to make it work with current version of wx and Python (it doesn't like 
"is '' ", it suggests to make it "== '' "; several combinations of 
alignment flags in the sizer are now a no-no, check dSizerMixin.py). I 
built my form in code, without any attempts at alignment, and it just 
worked.


But the alignment issue affected the ClassDesigner.py (and a few 
others, not connection maker, that one works), because the asserts 
triggered can't be turned off, they are deep inside the wx's c++ code. 
The remaining issue is this:


*ndragan@zmycheck12u*:*~/radna/py/dabo*$ python3.8 -i 
ide/ClassDesigner.py


(ClassDesigner.py:24978): Gtk-*CRITICAL*  **:16:53:54.306: 
gtk_widget_set_size_request: assertion 'height >= -1' failed


(ClassDesigner.py:24978): Gtk-*CRITICAL*  **:16:53:54.307: 
gtk_widget_set_size_request: assertion 'height >= -1' failed


(ClassDesigner.py:24978): Gtk-*CRITICAL*  **:16:53:54.307: 
gtk_widget_set_size_request: assertion 'height >= -1' failed


(ClassDesigner.py:24978): Gtk-*CRITICAL*  **:16:53:54.407: 
gtk_widget_set_size_request: assertion 'height >= -1' failed


(ClassDesigner.py:24978): Gtk-*CRITICAL*  **:16:53:54.407: 
gtk_widget_set_size_request: assertion 'height >= -1' failed

Segmentation fault (језгрени избачај)

The trouble here is that gtk doesn't give you any clue where it 
happened, gives you only the almost useless timestamp. This happens 
when I try to resize the class designer. Before I get it to open, it 
has two complaints about "Unknown image data format" when I click OK 
in the first dialog. Then I get two more lines:


(ClassDesigner.py:25654): Gtk-*WARNING*  **:17:21:42.187: Negative 
content width -33 (allocation 1, extents 17x17) while allocating 
gadget (node button, owner GtkButton)


(ClassDesigner.py:25654): Gtk-*WARNING*  **:17:21:42.187: Negative 
content height -9 (allocation 1, extents 5x5) while allocating gadget 
(node button, owner GtkButton)


and then whatever I do - go through the menu or resize or whatever, it 
quits with the segmentation fault.


Don't know whether any of this will help much, but there it is. Sorry 
for the depth of the 

Re: [dabo-users] OpenRPT

2009-07-03 Thread John
On Friday 03 July 2009 02:43:30 am Alan Bourke wrote:
> Does anyone have any comments or experience with OpenRPT? Not in a Dabo
> context obviously, in a general Python context.
>
> TIA.

I looked into finding a replacement to reportWriter and OpenRPT was one of 
many.  I found that reportWriter did most of everything needed for reporting 
directly from dabo.  I decided that it was better investing in reportWriter 
(Paul fixed a paragraph issue) then presenting a different interface to the 
user to a report writer such as OpenRPT and making the install have much more 
complex.


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907031018.11376.jfabi...@yolo.com


Re: [dabo-users] OpenRPT

2009-07-06 Thread John
On Monday 06 July 2009 09:29:09 am Dan Means wrote:
>  but a nice generic Crystal type app would be ideal.


Maybe I'm just getting old but I hated Crystal.  Way over the top.  After 
spending hundreds of dollars and maybe hundred hours setting up drill down 
etc.   I never had a client that ever said "wow" or even anything close.  I 
even asked a major client if they enjoyed the click and drill down.  I got "I 
don't use it".

My clients do not care about all that can be done with crystal.  So I gave up 
and just used Fox.  And the same goes for foxfire, stonefield and others.  I 
show them how to create reports and two month later I watch as they use Excel 
to create a new report.  

And today I'm presented with the same situation.  Yea, I could use something 
other than ReportDesigner and reportWriter.  But why?  

Larry has been able to do everything the clients want so far.  Sure there are 
issues but nothing is a deal breaker (Thanks to Paul).  At the moment we have 
email (converted PDF to text and attachment of PDF), Fax, printing, and 
review.  We will soon have SMS text messages too.  

The only thing I'd like to see is better tools to create reports.  I had to 
create a small app to generate test data for the XML's.  Also the 
ReportDesigner is not always stable.



___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907061051.51779.jfabi...@yolo.com


Re: [dabo-users] OpenRPT

2009-07-06 Thread John
On Monday 06 July 2009 01:17:57 pm Ed Leafe wrote:
> On Jul 6, 2009, at 2:32 PM, Alan Bourke wrote:
> > I can't believe there aren't scads of them out there in Linux land
> > already. Maybe they're too hard to write.
>
>   Crystal and similar products came about before the advent of the web
> as the primary development platform. Since the web, very little effort
> is being expended in the non-web fields. I guess if there was a strong
> demand someone would have stepped up, just like if there was a strong
> demand for desktop apps, Dabo would be used by millions.
>
>
> -- Ed Leafe

I realize that where you work it's all about the cloud but desktop apps are 
not dead yet as you suggest.  In fact I would suggest that it is just the 
opposite.  I haven't seen google's office apps replace word, or openoffice.  
In general the accountings systems are not being replaced by web apps.  And 
there are plenty.  Yes they have followers/users but in general no web apps 
are doing the job.  

Everytime I see a web app - it always has short comings.  Even the new 'AIR' 
programs have issues.  Maybe when Web "3" starts we'll start seeing desktop 
apps being replaced.  




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907061354.11918.jfabi...@yolo.com


[dabo-users] event CalendarDateChanged not working?

2009-07-06 Thread John
Below is how I am setting update a dDateTextBox.  Nothing I do seems to fire 
the event I setup.  
startDate = dabo.ui.dDateTextBox(self, Width = 150, RegID = 'classDateID')
startDate.bindEvent(dabo.dEvents.CalendarDateChanged, self.dateChanged)

What I want is if the date is changed the event to fire.  Am I doing something 
wrong?

openSUSE 11.0 (yes I updated)
Python 2.5
wxPython 2.8.9.1

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907061416.31432.jfabi...@yolo.com


Re: [dabo-users] Fwd: how to dis-able dabo.ui.dBitmapButton

2009-07-07 Thread John
On Tuesday 07 July 2009 04:07:09 am Miguel Lopes wrote:
> def toggleVCR(self):
>         btnsToDisable = ('btnFirst', 'btnPrev', 'btnNext', 'btnLast')
>         for id in btnsToDisable:
>             btn = self.getObjectByRegID(id)
>             btn.Enable = not btn.Enable

Shouldn't that be "Enabled" with a 'd'.

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907070620.16563.jfabi...@yolo.com


[dabo-users] dButton and standard wx.Button

2009-07-07 Thread John
It seems that a standard button style (not sure what to call it) is available 
for buttons like 'Add'  (wx.ID_ADD) and many others.  Apparently, passing the 
style is suppose allow the button captions follow the platform theme.  How do 
I pass the style to a dabo.ui.dButton? 


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907071138.29301.jfabi...@yolo.com


Re: [dabo-users] dButton and standard wx.Button

2009-07-07 Thread John
On Tuesday 07 July 2009 11:38:29 am John wrote:
> It seems that a standard button style (not sure what to call it) is
> available for buttons like 'Add'  (wx.ID_ADD) and many others.  Apparently,
> passing the style is suppose allow the button captions follow the platform
> theme.  How do I pass the style to a dabo.ui.dButton?


dabo.ui.dButton(self, id = wx.ID_ADD) works.

John





___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907071430.38375.jfabi...@yolo.com


Re: [dabo-users] Multiple Checkboxes in dGrid and VirtualFields Woes

2009-07-08 Thread John
On Wednesday 08 July 2009 04:46:20 pm Miguel Lopes wrote:
> I'm trying without success to have a grid with two checkboxes.
>
> The first checkbox (contactSelect) allows me to indicate which records
> to select. the second indicates if the record is to be shared
> (contactShare) (just something about the record).
> My problem is that most checkbox clicks somehow affect the other
> checkbox. This happens irrespectively of if I press contactSelect or
> contactShare, and even affects records in different rows.
>
> I can't seem to find a solution for this. Here's my bizobj code. Any ideas?
>
> class ContactBizobj(dabo.biz.dBizobj):
>   def afterInit(self):
>   self.addFrom("contact")
>   self.addField("contact.mobile")
>   self.addField("contact.phone_ext")
>   self.addField("contact.title_id")
>   self.addField("contact.phone")
>   self.addField("contact.contact")
>   self.addField("contact.contact_status_id")
>   self.addField("contact.contact_type_id")
>   self.addField("contact.email")
>   self.addField("contact.job_title")
>   self.addField("contact.contact_id")
>   self.addField("contact.account_id")
>
>   self.addJoin("account", "contact.account_id = 
> account.account_id",
> joinType="LEFT")
>   self.addField("account.account")
>
>   self.DataSource = "contact"
>   self.LinkField = "account_id"
>   self.KeyField = "contact_id"
>   self.NonUpdateFields=["contact_id"]
>   self.FillLinkFromParent = True
>
>   self.VirtualFields.update({'contactSelect': self.contactSelect,
>  
> 'contactShare': self.contactShare})
>
>   def contactSelect(self):
>   if self.Record.contact_id in self.__selectedContactsToAssign:
>   # it's already selected, unselect
>   del 
> self.__selectedContactsToAssign[self.Record.contact_id]
>   return False
>   else:
>   # not selected, select it - "False" means it is not 
> shared
>   self.__selectedContactsToAssign[self.Record.contact_id] 
> = False
>   return True
>
>   def contactShare(self):
>   if self.Record.contact_id in self.__selectedContactsToAssign 
> and \
> self.__selectedContactsToAssign[self.Record.contact_id] == 
> False:
>   # not shared, share it - "True" means it is shared
>   self.__selectedContactsToAssign[self.Record.contact_id] 
> = True
>   return True
>   else:
>   return False
>
>   def validateRecord(self):
>   """Returning anything other than an empty string from
>   this method will prevent the data from being saved.
>   """
>   ret = ""
>   # Add your business rules here.
>   return ret
>
>   def initProperties(self):
>   self.__selectedContactsToAssign={}
>
>
> TIA,
> Miguel

On the surface I don't see anything wrong with the bizobj.  What does the grid 
code look like?  In the grid you should be marking the fields as 'boolean'.  
I have just yesterday coded a grid with two check boxes and it appears to 
work OK.  However, my fields are not virtual fields.




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907081806.33732.jfabi...@yolo.com


Re: [dabo-users] Multiple Checkboxes in dGrid and VirtualFields Woes

2009-07-09 Thread John
On Thursday 09 July 2009 02:09:19 pm Miguel Lopes wrote:
> On Thu, Jul 9, 2009 at 2:06 AM, John wrote:
> > On Wednesday 08 July 2009 04:46:20 pm Miguel Lopes wrote:
> >> I'm trying without success to have a grid with two checkboxes.
> >>
> >> The first checkbox (contactSelect) allows me to indicate which records
> >> to select. the second indicates if the record is to be shared
> >> (contactShare) (just something about the record).
> >> My problem is that most checkbox clicks somehow affect the other
> >> checkbox. This happens irrespectively of if I press contactSelect or
> >> contactShare, and even affects records in different rows.
> >>
> >> I can't seem to find a solution for this. Here's my bizobj code. Any
> >> ideas?
> >>
> >> class ContactBizobj(dabo.biz.dBizobj):
> >>       def afterInit(self):
> >>
> >> ..., ...
> >>
> >>               self.VirtualFields.update({'contactSelect':
> >> self.contactSelect, 'contactShare': self.contactShare})
> >>
> >>       def contactSelect(self):
> >>               if self.Record.contact_id in
> >> self.__selectedContactsToAssign: # it's already selected, unselect
> >>                       del
> >> self.__selectedContactsToAssign[self.Record.contact_id] return False
> >>               else:
> >>                       # not selected, select it - "False" means it is
> >> not shared self.__selectedContactsToAssign[self.Record.contact_id] =
> >> False return True
> >>
> >>       def contactShare(self):
> >>               if self.Record.contact_id in
> >> self.__selectedContactsToAssign and \
> >> self.__selectedContactsToAssign[self.Record.contact_id] == False: # not
> >> shared, share it - "True" means it is shared
> >> self.__selectedContactsToAssign[self.Record.contact_id] = True return
> >> True
> >>               else:
> >>                       return False
> >>
> >> ..., ...
> >>
> >>       def initProperties(self):
> >>               self.__selectedContactsToAssign={}
> >>
> >>
> >> TIA,
> >> Miguel
> >
> > On the surface I don't see anything wrong with the bizobj.  What does the
> > grid code look like?  In the grid you should be marking the fields as
> > 'boolean'. I have just yesterday coded a grid with two check boxes and it
> > appears to work OK.  However, my fields are not virtual fields.
>
> I'm thinking on an alternative UI to accomplish the same goal, but
> nevertheless I cannot spot what is wrong with this.
> My grid code was initially in cdxml, but this coded version has the
> same problem.
>
> class SetOpptyContactsAsDlg(dui.dForm):
>
>def initProperties(self):
>self.CxnName = "mainCnx"
>self.Height = 511
>self.Width = 976
>
>def afterInit(self):
>sz = self.Sizer = dui.dSizer('v')
>
>grid = dui.dGrid(self, RegID="dgSelectContact",
> DataSource="contact", SelectionMode="Row")
>grid.addColumn(Name="title", DataField="title_id",
> DataType="integer", Width=64, Caption=u"Título", Expand=False)
>grid.addColumn(Name="contact", DataField="contact",
> DataType="string", Width=250, Caption=u"Contacto", Expand=False)
>grid.addColumn(Name="contact_status_id",
> DataField="contact_status_id", DataType="integer", Width=90,
> Caption=u"Estado", Expand=False)
>grid.addColumn(Name="account", DataField="account",
> DataType="string", Width=250, Caption=u"Conta", Expand=False)
>grid.addColumn(Name="contactSelect",
> DataField="contactSelect", DataType="bool", Width=83,
> HorizontalAlignment="Center", Caption=u"Selecciona", Expand=False)
>grid.addColumn(Name="contactRole", DataField="contactRole",
> DataType="integer", Width=125, HorizontalAlignment="Center",
> Caption=u"Papel", Expand=False)
>grid.addColumn(Name="contactShare", DataField="contactShare",
> DataType="bool", Width=75, HorizontalAlignment="Center",
> Caption=u"Cruza", Expand=False)
>
>hSz = dui.dSizer('h')
>
>hSz.appendSpacer(20, proportion=1)
>se

Re: [dabo-users] A selector composed of two grids

2009-07-09 Thread John
On Thursday 09 July 2009 02:23:42 pm Miguel Lopes wrote:
> I'm trying to make a record selector.
> The UI is simple:
> A grid on the left with available records (gdAvailableContacts), a
> grid on the right with selected record (gdSelectedContacts). Four
> buttons in the middle, to select a record, to unselect a record, to
> select all, and to unselect all.
>
> The left grid is populated with a bizobj (no problems).
> How should I populate the left grid? I tried an empty dDataSet, but
> it's not possible to add records to it.
>
> I'm not looking to remove records from the left grid, just to add or
> remove records from the right grid. How is this accomplished?
>
> Txs for the help,
> Miguel

I add records to an empty grid all the time.  

untested:
self.rightGrid.DataSet = {}
self.rightGrid.DataSet = tempCursor.getDataSet()
self.rightGrid.update()

or
self.rightGrid.DataSet = self.rightGrid.DataSet +{'someKey":"theValue"}

Johnf






___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907091510.38292.jfabi...@yolo.com


Re: [dabo-users] VFP keypress and keyboard equivalent

2009-07-12 Thread John
On Sunday 12 July 2009 08:31:55 pm tim awa wrote:
> I wanted to trap a particular keystroke while in a grid column and
> replace it with a two keystroke combination.
>
> This is done in VFP by overriding grid.Column1.Text1.Keypress
>
> LPARAMETERS nKeyCode, nShiftAltCtrl
> NODEFAULT
> IF nKeyCode = 123
>KEYBOARD 'Hi'
> ENDIF
>
> How to do this in Dabo?

To capture the keypress you need bind an event:

someControl.bindEvent(dEvents.KeyChar, self._keypress)

The question in my mind is what you need to bind too.  I have not done it but 
I bet  there is some way to bind an event to a cell.

Below is an example of do something with the keys.
def _keypress(self, evt):

from dabo.ui import dKeys as dKeys
if evt.keyCode in 
[dKeys.key_F1,dKeys.key_F2,dKeys.key_F3,dKeys.key_F5,dKeys.key_F6,dKeys.key_F8,dKeys.key_F9,dKeys.key_F10,dKeys.key_F11,dKeys.key_F12]:
return
 if evt.keyCode in [dKeys.key_F7, dKeys.key_F4, dKeys.key_Return]:
thestr= self.Form.lookup(evt)
return 
#print keyChar 
keyChar=evt.keyChar
if (keyChar in """,./<>?;':"[]\\{}|`...@#$%%^&*()_=+"""): 
evt.stop()

johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907122128.05035.jfabi...@yolo.com


Re: [dabo-users] VFP keypress and keyboard equivalent

2009-07-13 Thread John
On Monday 13 July 2009 06:37:24 am tim awa wrote:
> My only interest really is on altering the behavior of the up and down
> arrow keys when the focus is in a grid column. I noticed that the up
> and down keys behave like left and right arrow keys whenever the
> grid's column is in edit mode. There is no issue when the column is in
> read-only mode as the up and down keys allow movement to the next row.

In that case it might be better to sub-class the dabo.ui.dGrid.  Take a look 
at the "_onKeyChar()" method.  Just follow the general layout.

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907130704.12742.jfabi...@yolo.com


Re: [dabo-users] Very Simple dropdownlist

2009-07-14 Thread John
On Tuesday 14 July 2009 05:32:22 pm Carey Gagnon wrote:
> Oktwo days have passed and I still can't figure it out. I need a sample
> to study.
> What I am trying to do is take the step by step tutorial (
> http://docs.google.com/Doc?id=dg79jzmg_3x78zkp) and create a form to add
> new clients. I've gotten this far with success.
>
> Now what I want to do on the form is take the dTextBox for adding the state
> and turn it into a dDropdownList for the states. I want to hard code this
> NOT pull it in from the database.
>
> I've tried numerous things to no avail. I've tried the many pointer Larry
> and Ed gave me and can only manage a drop down properly populated with the
> hard coded values. But when I click the save button
> everything is written to the database except for a value for the stateprov
> field of the clients table.
>
> I guess I'm not under standing which of these tips go into which file. What
> goes into my ClientForm-code.py and what goes into my ClientBizobj.py file?
>
> Prior to my previous statements, spoon feeding take me back to a warm fuzzy
> place.
>
> Thanks in advance
> Carey
>
> On Sun, Jul 12, 2009 at 8:35 PM,  wrote:
> > Carey,
> >
> > Sorry, my carriage returns didn't go thru
> >
> > statesdropdown = dabo.ui.dDropdownList(self,DataSource = ClientBizobj,
> > DataField = "stateprov")
> >
> > choices = []
> > keys = {}
> > for location in locations:
> >choices.append("%s" % (location['state']))
> >keys[location["iid"]] = len(choices) - 1
> >
> > statesdropdown.Choices = choices
> > statesdropdown.Keys = keys
> > statesdropdown.ValueMode = "key"
> >
> > Larry

I think I understand what you are attempting to do.  I assume Larry thought 
you were hand coding your form and not using ClassDesigner.

First edit the form (the one you created following the step-by-step tutorial) 
in ClassDesigner.  Select the textbox next to the 'State:' label and delete 
the dTextBox.  Now replace the dTextBox with a dDropDown.  To get that done 
you right click on the empty spot and select a dDropDown (part of 
the 'Display Controls' list).  Now in the "object info"  window (recall you 
have the dDropDown selected) fill in the 'Choices' property with the values 
of the states by clicking on the 'Edit' button on the bottom 
('CA','TX','WA' - note the commas).  Next fill in the "DataSource" property 
with 'clients' and "DataField" property with 'stateprov'.  That should work 
immediately.  

But there are other ways to get this done.  As you learn more you will be able 
create controls along with everything needed other ways.

Feel free to ask more questions if you have trouble.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907142035.55253.jfabi...@yolo.com


Re: [dabo-users] Joins on datasets

2009-07-15 Thread John
On Wednesday 15 July 2009 09:19:14 am lalo...@charter.net wrote:
> Tim,
>
> Great! When I get into trouble, one of the first things I do is go thru the
> call stack and look at the functions and parameters to try to see what it
> is expecting.  That's how I tracked this one down for ya.
>
> Larry

Tim,
Larry uses an IDE called "wing" which provides easy debugging.  I found it to 
be one of the best ways to debug a Dabo app.  But that's just my opinion.

Johnf





___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907151648.27503.jfabi...@yolo.com


Re: [dabo-users] Troublesome install on Ubuntu

2009-07-15 Thread John
On Wednesday 15 July 2009 09:59:46 am Ed Leafe wrote:
> On Jul 13, 2009, at 8:59 PM, Jim McDonald wrote:
> > Following instructions in Dabo Wiki (including the bits about
> > installing
> > python2.5-dev and putting a dabo.pth file in the 'site-packages'
> > directory), 'setup.py install' errors out with a traceback that ends
> > as
> > follows:
> >
> >   "  File  ' .  .  .  dabo/lib/eventMixin.py' line 6 in 
> > from dabo.dLocalize import _
> > ImportError: cannot import name _ "
> >
> > eventMixin.py and dLocalize.py are the same in my Windows install--
> > which
> > setup effortlessly--as in the Linux install.
> >
> > Any thoughts?
>
>   My guess is that you are doing parts of two completely different ways
> of installing the dabo module. One is to create the .pth file to a
> locally checked-out copy of the code, and the other is to grab the
> installation download and run setup.py to create an egg.
>
>   That's the problem when there is more than one way to do something:
> if you do it both ways, it doesn't work!
>
>   I would remove all the dabo stuff from site-packages to start with a
> clean slate. If you have an 'easy_install.pth' file in site-packages,
> I would open it in a text editor to make sure that it does not have
> any pathing info for a dabo egg.
>
>   Then I would pick one way of using Dabo: a locally checked-out copy
> of the repository, or an egg from the released code. The general rule
> of thumb is that if you plan on working within the framework itself,
> you should have a copy of the repository, and link to that with the
> dabo.pth file. If you don't plan on mucking around inside the
> framework code, and instead want to use Dabo to create applications,
> download the release and install the egg using setup.py.
>
>   Hope that helps!
>
>
> -- Ed Leafe

I believe I reported this issue in the recent past.  If memory serves I 
discovered that the standard use of site-packages did not work when 
installing on 9.04.  I think I ended up placing the dabo.pth file in a 
directory that started with a 'd' or 'D'.  I'm not anywhere near my ubuntu 
laptop so I can not provided the exact location/directory.   But I can say it 
took me sometime to determine where I needed to place the file.  

I hope this helps and does not confuse the issue.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907151654.46907.jfabi...@yolo.com


Re: [dabo-users] Very Simple dropdownlist

2009-07-15 Thread John
On Wednesday 15 July 2009 03:58:23 pm Carey Gagnon wrote:
> John, thanks so much! I knew there had to be a simpler way. Ihad already
> successfully created the drop downlist it was getting it populated without
> a db look up that I was having an issue with. Now it is populating and
> correctly saving everything to the database.
>
> Still one issue however. I am now getting the following error shown in the
> terminal window (I'm running linux) This is only a partial trace back:
>
> File "/usr/lib/python2.5/site-packages/dabo/ui/uiwx/dControlItemMixin.py",
> line 356, in _setStringValue
> raise ValueError(_("String must be present in the choices."))
> ValueError: String must be present in the choices.
>
> Any ideas?
> This is also preventing the form from resetting itself.
>


You might want to add '' to your list.  The problem is when the dropdown 
is first init - it does not have any data - therefore the need to have a null 
value.  In Dabo the null value is converted to the string ''.

But now that you have gotten this far - try the other ways to populate a 
dropdown.  They will offer more control and better results than hard coding 
the 'Choices'.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907151702.27279.jfabi...@yolo.com


Re: [dabo-users] dCheckBox Value

2009-07-16 Thread John
On Thursday 16 July 2009 11:52:26 am Mike Mabey wrote:
> Hi All,
>
> I have a question about manually setting the value of a dCheckBox.  It
> doesn't specify in the API
> Documentation<http://paul.dabodev.com/doc/api/dabodoc/dabo.ui.uiwx.dCheckBo
>x.dCheckBox.html#Properties_Value>whether this property is read/write at
> runtime or not, though I assume it
> is, just like all the other data controls.  In my app, I have been unable
> to set this property at all, and I was wondering if there's something I
> should know concerning setting this particular property.
>
> In case you need more detail about my specific project, I'm running Win
> Vista with Python 2.5.4 with Dabo r5279.  I've developed this app in the
> ClassDesigner.  I'm trying to set the value in the afterInitAll() method of
> dForm with a 1 or 0 for True/False, but never reflects the given value and
> doesn't give an error.  It wouldn't make sense to try binding this field to
> a data set since there's no associated database, just a configuration file
> I wrote myself with values in it for each of the data controls.
>
> Any help would be very appreciated,
> Mike M.


Show us the code that sets the value.  Make sure you are using "Value" and 
not 'value'.   Also make sure you haven't set the 'UserThreeState'.  

John


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907161228.45885.jfabi...@yolo.com


Re: [dabo-users] Very Simple dropdownlist

2009-07-17 Thread John
On Friday 17 July 2009 11:33:54 am Carey Gagnon wrote:
> Ok, I have now got the drop down populating properly with all error message
> gone. Everything is saving to the database properly as well.
> Here's the appropriate section of the cdxml file:
>
>  designerClass="controlMix" DataSource="clients"
> DataField="stateprov">
>
>
> I added the following line to the bizobj file which stopped the
> "String must be present in the choices"  error:
>
> self.DefaultValues = {"stateprov": "-Select-"}
>
> My Question now (looking at the cdxml snippet), is there anyway to display
> the full name of the state in the drop down list, but save the abbreviation
> to the database on self.Form.save()
>
> Thanks in advance
> Carey

Of course - this is Dabo after all.  

In general listCtrl controls have two 'ValueMode" s.  Using the 'key' 
or 'string'.  The default is to use string value in the choices list. But you 
can change it to "ValueMode = key"

So now you need to set the key and choices to match each other.

In your form select the dropdown control.  Copy your "Choices" ( I assume they 
are similar to ['CA','WA','TX',...]) and put it into the 'Keys'.  Now set the 
choices similar to ['California', 'Washington', 'Texas', ]. Just make 
sure they match.  Next set the 'ValueMode' from 'string' to 'key'.  

Recall you will need to do something with the None value.  I always use '0' as 
my key for a None value.
Johnf





___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907171159.55263.jfabi...@yolo.com


Re: [dabo-users] dCheckBox Value

2009-07-17 Thread John
On Friday 17 July 2009 12:05:21 pm Mike Mabey wrote:
> On Thu, Jul 16, 2009 at 3:20 PM, Paul McNett  wrote:
> > Mike Mabey wrote:
> > > I'm so sorry.  I've been doing some further troubleshooting, and I'm
> >
> > fairly
> >
> > > certain now that the problem isn't with setting the dCheckBox, but with
> >
> > the
> >
> > > value I'm trying to set it to.
> >
> > No problem. But I have a guess: cb.Value = "0" yields True?
> >
> > Paul
>
> Perhaps.  I think that in an effort to write code that did more with less,
> I made things too complicated.  I guess I'm still fighting my formal
> education in the Platform-Independent Assembly Language known as C++ and
> striving to learn the truly Pythonic way to do things.
>
> In the face of ambiguity, refuse the temptation to guess.
> There should be one-- and preferably only one --obvious way to do it.
> Although that way may not be obvious at first unless you're Dutch.
> (import this)
>
> I'm not Dutch, so I guess I'll have to learn from experience so I can stop
> guessing.
>
> Mike M.

LOL  -  to this day I don't understand the part about the 'Dutch'.  But I know 
little about the history of Python.

Johnf



___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907171256.06877.jfabi...@yolo.com


Re: [dabo-users] Error importing dabo

2009-07-17 Thread John
On Friday 17 July 2009 03:45:09 pm Ed Leafe wrote:
> On Jul 17, 2009, at 5:38 PM, Paul McNett wrote:
> > Python 2.6 is not supported yet. Please try with Python 2.5.
>
>   I thought the only problem is with wxPython under Windows with Python
> 2.6. Have there been any other issues reported?
>
>
> -- Ed Leafe
Can you run 2.6 in any environment?  I'm not being smart just like to know 
because in the recent past I have not been able to run 2.6.  It has something 
to do with dGrid.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907172146.30116.jfabi...@yolo.com


Re: [dabo-users] pdf page count

2009-07-20 Thread John
On Monday 20 July 2009 05:03:46 pm Carl Karsten wrote:
> > anyone know how
> > to get a page count from a pdf?
>
> OK, that's dumb.  Anyone know how I can get the page count from:
>
># generate the pdf in the buffer, using the layout and data
>rw = dReportWriter(OutputFile=buffer, ReportFormFile=xmlfile, Cursor=ds)
>rw.write()
>
> I am not opposed to adding a ABC header and counting the number of
> ABC's in the pdf.
>
> might be nice to add .pagecount to dReportWriter, but that won't help
> track down when the good/bad flip happened.

I found this.
http://code.activestate.com/recipes/546511/
Johnf



___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907201737.01626.jfabi...@yolo.com


Re: [dabo-users] pdf page count

2009-07-20 Thread John
On Monday 20 July 2009 05:03:46 pm Carl Karsten wrote:
> > anyone know how
> > to get a page count from a pdf?
>
> OK, that's dumb.  Anyone know how I can get the page count from:
>
># generate the pdf in the buffer, using the layout and data
>rw = dReportWriter(OutputFile=buffer, ReportFormFile=xmlfile, Cursor=ds)
>rw.write()
>
> I am not opposed to adding a ABC header and counting the number of
> ABC's in the pdf.
>
> might be nice to add .pagecount to dReportWriter, but that won't help
> track down when the good/bad flip happened.

A "Improved version"
http://code.activestate.com/recipes/576832/

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907201738.21194.jfabi...@yolo.com


Re: [dabo-users] pdf page count

2009-07-21 Thread John
On Monday 20 July 2009 07:48:37 pm Carl Karsten wrote:
> On Mon, Jul 20, 2009 at 7:38 PM, John wrote:
> > On Monday 20 July 2009 05:03:46 pm Carl Karsten wrote:
> >> > anyone know how
> >> > to get a page count from a pdf?
> >>
> >> OK, that's dumb.  Anyone know how I can get the page count from:
> >>
> >>    # generate the pdf in the buffer, using the layout and data
> >>    rw = dReportWriter(OutputFile=buffer, ReportFormFile=xmlfile,
> >> Cursor=ds) rw.write()
> >>
> >> I am not opposed to adding a ABC header and counting the number of
> >> ABC's in the pdf.
> >>
> >> might be nice to add .pagecount to dReportWriter, but that won't help
> >> track down when the good/bad flip happened.
> >
> > A "Improved version"
> > http://code.activestate.com/recipes/576832/
>
> Thanks, but before I found your post I follwed up on a ChiPy post from
>
> just last week:
> >>> from pyPdf import PdfFileWriter, PdfFileReader
> >>> input1 = PdfFileReader(open('test.pdf','rb'))
> >>> print "title = %s" % (input1.getDocumentInfo().title)
>
> title = Dabo Report
>
> >>> print input1.getNumPages()
>
> 3
>
> Now to figure out how to use git bisect...

I like Paul's last post.  It's pure python and appears to work.  No need to 
import anything (other than re).
John


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907210732.07147.jfabi...@yolo.com


Re: [dabo-users] Translation failure in fresh install

2009-07-21 Thread John
On Tuesday 21 July 2009 05:25:02 pm Adrian Klaver wrote:
> On Tuesday 21 July 2009 5:01:53 pm Paul McNett wrote:
> > Rhodri James wrote:
> > >> How did you install dabo? AFAIK nothing in Dabo's setup.py specifies
> > >> putting the locales in /usr/local.
> > >
> > > I unzipped the release .tgz into ~/Tools/dabo, cd'ed to there and ran
> > >
> > > sudo python setup.py
> >
> > Ok thanks. I wonder if some python hook on Ubuntu is putting the locale
> > directory in a central place instead of in the egg, where dabo expects
> > to find it.
> >
> > Paul
>
> Could it be related to?:
> https://bugs.launchpad.net/ubuntu/+source/python2.6/+bug/362570

Very cool you have now explained why I had to place the dabo.pth file into 
'/usr/local/lib/python2.6/dist-packages' to get dabo running.

Thanks
Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907211931.51053.jfabi...@yolo.com


Re: [dabo-users] VFP SYS(2015)

2009-07-21 Thread John
On Monday 20 July 2009 11:31:36 am Simon White wrote:
> Hi
>
>
>
> Does dabo have a
>
>
>
>
> Regards,
> Simon WhitedCipher Computing705-721-3382
> simonwh...@dciphercomputing.com

That depends on what you are using sys(2015) for.  If you are using it for a 
unique key - then most of the backends (Postgres, MySQL, FireBird, MSSQL) 
have that use covered.

If you had another purpose you might want to check python's UUID objects.  

import uuid
some_unique_id = uuid.uuid()

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907211944.57394.jfabi...@yolo.com


Re: [dabo-users] Is anyone using wxDesigner with Dabo?

2009-07-21 Thread John
On Monday 20 July 2009 12:36:45 pm Simon White wrote:
> Hi
>
>
> I am just looking for
>
>
> Regards,SimondCipher Computing705-721-3382
> simonwh...@dciphercomputing.com

Not that I'm aware of.  I haven't used wxDesigner in a very long time.  But I 
think it could be possible.  Not sure you'd really gain much by doing so.  
Have you checked out the ClassDesigner or tried hand coding a form?  I hand 
code my form and find it easy.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907211948.30467.jfabi...@yolo.com


[dabo-users] reportWriter error on linux (works on windows)

2009-07-23 Thread John
openSUSE 11.0
python 2.5.2
wxpython 2.8.9.2
latest Dabo 

Traceback (most recent call last):
  File "/home/johnf/dabo/dabo/ui/uiwx/dControlMixin.py", line 27, in _onWxHit
self.raiseEvent(dEvents.Hit, evt, *args, **kwargs)
  File "/home/johnf/dabo/dabo/ui/uiwx/dPemMixin.py", line 949, in raiseEvent
super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args, 
**kwargs)
  File "/home/johnf/dabo/dabo/lib/eventMixin.py", line 93, in raiseEvent
bindingFunction(event)
  File "/home/johnf/pyProject/pespy/RptForm1.py", line 429, in doReport
if SendReport(sendto, outputfile=outputfile, 
rfxmlname=self.PrimaryBizobj.Re cord.crptname, reportDS=reportDS, 
emailinfo=emailinfo, corientation=corientation , rw = self.rw, 
encoding=self.PrimaryBizobj.ReportCursor.Encoding, callingForm=s elf, 
history_info=history_info, report_info=self.ReportInfo):
  File "/home/johnf/pyProject/pespy/RptForm1.py", line 1087, in SendReport
sentok = process_report(reportDS, rw, outputfile)
  File "/home/johnf/pyProject/pespy/RptForm1.py", line 965, in process_report
rw.write()
  File "/home/johnf/dabo/dabo/lib/reportWriter.py", line 1508, in write
c.setKeywords(_form.getProp("Keywords"))

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907231310.18207.jfabi...@yolo.com


Re: [dabo-users] reportWriter error on linux (works on windows)

2009-07-23 Thread John
On Thursday 23 July 2009 01:10:18 pm John wrote:
> openSUSE 11.0
> python 2.5.2
> wxpython 2.8.9.2
> latest Dabo
>
> Traceback (most recent call last):
>   File "/home/johnf/dabo/dabo/ui/uiwx/dControlMixin.py", line 27, in
> _onWxHit self.raiseEvent(dEvents.Hit, evt, *args, **kwargs)
>   File "/home/johnf/dabo/dabo/ui/uiwx/dPemMixin.py", line 949, in
> raiseEvent super(dPemMixin, self).raiseEvent(eventClass, nativeEvent,
> *args, **kwargs)
>   File "/home/johnf/dabo/dabo/lib/eventMixin.py", line 93, in raiseEvent
> bindingFunction(event)
>   File "/home/johnf/pyProject/pespy/RptForm1.py", line 429, in doReport
> if SendReport(sendto, outputfile=outputfile,
> rfxmlname=self.PrimaryBizobj.Re cord.crptname, reportDS=reportDS,
> emailinfo=emailinfo, corientation=corientation , rw = self.rw,
> encoding=self.PrimaryBizobj.ReportCursor.Encoding, callingForm=s
> elf, history_info=history_info, report_info=self.ReportInfo):
>   File "/home/johnf/pyProject/pespy/RptForm1.py", line 1087, in SendReport
> sentok = process_report(reportDS, rw, outputfile)
>   File "/home/johnf/pyProject/pespy/RptForm1.py", line 965, in
> process_report rw.write()
>   File "/home/johnf/dabo/dabo/lib/reportWriter.py", line 1508, in write
> c.setKeywords(_form.getProp("Keywords"))
>
> Johnf

On my Linux box is appears the Prop 'keywords' is lower case  But it 
worked for 'Author'??  still researching.
Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907231314.43225.jfabi...@yolo.com


Re: [dabo-users] reportWriter error on linux (works on windows)

2009-07-23 Thread John
On Thursday 23 July 2009 01:14:43 pm John wrote:
> On Thursday 23 July 2009 01:10:18 pm John wrote:
> > openSUSE 11.0
> > python 2.5.2
> > wxpython 2.8.9.2
> > latest Dabo
> >
> > Traceback (most recent call last):
> >   File "/home/johnf/dabo/dabo/ui/uiwx/dControlMixin.py", line 27, in
> > _onWxHit self.raiseEvent(dEvents.Hit, evt, *args, **kwargs)
> >   File "/home/johnf/dabo/dabo/ui/uiwx/dPemMixin.py", line 949, in
> > raiseEvent super(dPemMixin, self).raiseEvent(eventClass, nativeEvent,
> > *args, **kwargs)
> >   File "/home/johnf/dabo/dabo/lib/eventMixin.py", line 93, in raiseEvent
> > bindingFunction(event)
> >   File "/home/johnf/pyProject/pespy/RptForm1.py", line 429, in doReport
> > if SendReport(sendto, outputfile=outputfile,
> > rfxmlname=self.PrimaryBizobj.Re cord.crptname, reportDS=reportDS,
> > emailinfo=emailinfo, corientation=corientation , rw = self.rw,
> > encoding=self.PrimaryBizobj.ReportCursor.Encoding, callingForm=s
> > elf, history_info=history_info, report_info=self.ReportInfo):
> >   File "/home/johnf/pyProject/pespy/RptForm1.py", line 1087, in
> > SendReport sentok = process_report(reportDS, rw, outputfile)
> >   File "/home/johnf/pyProject/pespy/RptForm1.py", line 965, in
> > process_report rw.write()
> >   File "/home/johnf/dabo/dabo/lib/reportWriter.py", line 1508, in write
> > c.setKeywords(_form.getProp("Keywords"))
> >
> > Johnf
>
> On my Linux box is appears the Prop 'keywords' is lower case  But it
> worked for 'Author'??  still researching.
> Johnf
My version of reportlab maybe to old?  It is 1.21.  I think windows is much 
higher.  Could that be the trouble?

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907231326.00072.jfabi...@yolo.com


Re: [dabo-users] reportWriter error on linux (works on windows)

2009-07-23 Thread John
On Thursday 23 July 2009 01:26:00 pm John wrote:
> On Thursday 23 July 2009 01:14:43 pm John wrote:
> > On Thursday 23 July 2009 01:10:18 pm John wrote:
> > > openSUSE 11.0
> > > python 2.5.2
> > > wxpython 2.8.9.2
> > > latest Dabo
> > >
> > > Traceback (most recent call last):
> > >   File "/home/johnf/dabo/dabo/ui/uiwx/dControlMixin.py", line 27, in
> > > _onWxHit self.raiseEvent(dEvents.Hit, evt, *args, **kwargs)
> > >   File "/home/johnf/dabo/dabo/ui/uiwx/dPemMixin.py", line 949, in
> > > raiseEvent super(dPemMixin, self).raiseEvent(eventClass, nativeEvent,
> > > *args, **kwargs)
> > >   File "/home/johnf/dabo/dabo/lib/eventMixin.py", line 93, in
> > > raiseEvent bindingFunction(event)
> > >   File "/home/johnf/pyProject/pespy/RptForm1.py", line 429, in doReport
> > > if SendReport(sendto, outputfile=outputfile,
> > > rfxmlname=self.PrimaryBizobj.Re cord.crptname,
> > > reportDS=reportDS, emailinfo=emailinfo, corientation=corientation  
> > >   , rw = self.rw, encoding=self.PrimaryBizobj.ReportCursor.Encoding,
> > > callingForm=s elf, history_info=history_info,
> > > report_info=self.ReportInfo):
> > >   File "/home/johnf/pyProject/pespy/RptForm1.py", line 1087, in
> > > SendReport sentok = process_report(reportDS, rw, outputfile)
> > >   File "/home/johnf/pyProject/pespy/RptForm1.py", line 965, in
> > > process_report rw.write()
> > >   File "/home/johnf/dabo/dabo/lib/reportWriter.py", line 1508, in write
> > > c.setKeywords(_form.getProp("Keywords"))
> > >
> > > Johnf
> >
> > On my Linux box is appears the Prop 'keywords' is lower case  But it
> > worked for 'Author'??  still researching.
> > Johnf
>
> My version of reportlab maybe to old?  It is 1.21.  I think windows is much
> higher.  Could that be the trouble?
>
> Johnf

My reportLab was to old.  Updating fixed the problem.  Sorry about the noise.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907231415.42297.jfabi...@yolo.com


[dabo-users] using evt.keyCode in windows

2009-07-24 Thread John
Hi,

Under windows I want to use F4,F7, and return to activate a method.  So I have 
been binding the dEvents.KeyChar to a method to capture the keystokes.

vendcomp is a dabo.ui.dTextBox

if sys.platform == 'win32':
vendcomp._addWindowStyleFlag(wx.TE_PROCESS_ENTER)
vendcomp.bindEvent(dEvents.KeyChar, self._lookup)


def _lookup(self,evt):
from dabo.ui import dKeys as dKeys
if evt.keyCode in 
[dKeys.key_F1,dKeys.key_F2,dKeys.key_F3,dKeys.key_F5,dKeys.key_F6,dKeys.key_F8,dKeys.key_F9,dKeys.key_F10,dKeys.key_F11,dKeys.key_F12]:
return
if evt.keyCode in [dKeys.key_F7, dKeys.key_F4, dKeys.key_Return]:
thestr= self.Form.lookup(evt)
return

if evt.keyChar is not None:
keyChar=evt.keyChar
if (keyChar in """,./<>?;':"[]\\{}|`...@#$%%^&*()_=+"""): 
evt.stop()
return

The Problem is under windows the left arrow, right arrow, the delete key do 
not work.  I do use "_addWindowStyleFlag(wx.TE_PROCESS_ENTER)" to capture 
the "return" key.  It was the only way I figure out how to force the return 
key to work.  

But I don't want to lose the arrow keys and the delete key.  Anybody know how 
I can have my cake and eat too?  Of course all this works under Linux. 

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907241228.20836.jfabi...@yolo.com


Re: [dabo-users] using evt.keyCode in windows

2009-07-25 Thread John
On Friday 24 July 2009 12:28:20 pm John wrote:
> Hi,
>
> Under windows I want to use F4,F7, and return to activate a method.  So I
> have been binding the dEvents.KeyChar to a method to capture the keystokes.
>
> vendcomp is a dabo.ui.dTextBox
>
> if sys.platform == 'win32':
> vendcomp._addWindowStyleFlag(wx.TE_PROCESS_ENTER)
> vendcomp.bindEvent(dEvents.KeyChar, self._lookup)
>
>
> def _lookup(self,evt):
> from dabo.ui import dKeys as dKeys
> if evt.keyCode in
> [dKeys.key_F1,dKeys.key_F2,dKeys.key_F3,dKeys.key_F5,dKeys.key_F6,dKeys.key
>_F8,dKeys.key_F9,dKeys.key_F10,dKeys.key_F11,dKeys.key_F12]: return
> if evt.keyCode in [dKeys.key_F7, dKeys.key_F4, dKeys.key_Return]:
> thestr= self.Form.lookup(evt)
> return
>
> if evt.keyChar is not None:
> keyChar=evt.keyChar
> if (keyChar in """,./<>?;':"[]\\{}|`...@#$%%^&*()_=+"""):
> evt.stop()
> return
>
> The Problem is under windows the left arrow, right arrow, the delete key do
> not work.  I do use "_addWindowStyleFlag(wx.TE_PROCESS_ENTER)" to capture
> the "return" key.  It was the only way I figure out how to force the return
> key to work.
>
> But I don't want to lose the arrow keys and the delete key.  Anybody know
> how I can have my cake and eat too?  Of course all this works under Linux.
>
> Johnf

Solved.  Larry pointed out that the code were a match to the way VFP 
keystrokes worked.  So I added.
if (keyChar in """,./<>?;':"[]\\{}|`...@#$%%^&*()_=+""") and (evt.keyCode < 126 
and evt.keyCode >=32) : 

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907250912.04525.jfabi...@yolo.com


Re: [dabo-users] Setting DropdownList.Value exception

2009-07-27 Thread John
On Monday 27 July 2009 11:30:36 am Miguel Lopes wrote:
> The general solution is setting a default value in the bizobj (that is
> of course in the Keys list of the dropdownList).

I believe that will not work (unless the default value is set to zero (0)).  

I think you are not understanding what is the root cause of the error.

In the DB you have a field that is associated with the dropdown.  There is a 
record with the field that contains a value that is not in the 'Choices' 
or 'Keys' of the dropdown (depends on ValueMode).   The value in the field 
could be a  Null.  In fact I think you have suggested that the value is a 
null.

In Dabo Nulls are converted to '' (in most cases) for strings and zero 
for numbers (not sure if numbers are converted - Hmmm).  So if your keys for 
the dropdown contain numbers (1,2,3,4) and the field contains a null (or 0) 
you will get the traceback.

So adding the values '', and zero to the Choices, Keys causes the error 
to go away.

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907271251.53974.jfabi...@yolo.com


Re: [dabo-users] setFocus error

2009-07-27 Thread John
On Monday 27 July 2009 01:15:20 pm jpoorra...@aol.com wrote:
> OK I'm working on the "Step by step " application, and now I've made
> progress on the "Add Hours" screen. But I'm getting an error on the save
> button OnHit code:
>
> def onHit(self, evt):
> if self.Form.save():
> # A  failed save will return False. We only want to proceed if
> # the  save  succeeds.
> self.Form.new()
> self.Form.servicedate.setFocus()
>
>
> On clicking save, the entry is indeed saved, and a new record is setup  for
> the screen, but the setFocus causes an error (see below for full listing) :
>  <>
>
> I understand that this code is supposed to put cursor back on the date
> field so a new entry can be made. I don't understand why referring to the
> dDateTextBox object as 'serviceDate' would work, other than that this is
> the value of the datafield property (and the name of the field in the hours
> table).
>
> I tried using << self.Form.dDateTextBox.setFocus() >> and got  the same
> error.
>
> Thanks for any help...
>
> Jonathan Poor
>
> ===Here's the traceback:=
>
> C:\Documents and Settings\Jonathan Poor\DABO\ClientHours>python  main.py
> Traceback (most recent call last):
> File
> "c:\python25\lib\site-packages\Dabo-0.9.2-py2.5.egg\dabo\ui\uiwx\dControl
> Mixin.py",  line 27, in _onWxHit
> self.raiseEvent(dEvents.Hit, evt,  *args, **kwargs)
> File
> "c:\python25\lib\site-packages\Dabo-0.9.2-py2.5.egg\dabo\ui\uiwx\dPemMixi
> n.py",  line 949, in raiseEvent
> super(dPemMixin,  self).raiseEvent(eventClass, nativeEvent, *args,
> **kwargs) File
> "c:\python25\lib\site-packages\Dabo-0.9.2-py2.5.egg\dabo\lib\eventMixin.p
> y",  line 93, in raiseEvent
> bindingFunction(event)
> File "c:\docume~1\jonath~1\locals~1\temp\tmptidzcf.py", line 314, in  onHit
> self.Form.serviceDate.setFocus()
> AttributeError:  'dForm_31385' object has no attribute 'serviceDate'

Using the ClassDesigner open the form in question.  Select the dDateTextBox in 
question.  Now edit the 'RegID' by place a string in the field such 
as 'myDateBox'  or any string that you think it should be.

Now replace 'servicedate' with the same string you entered into the 'RegID' 
property.
 self.Form.myDateBox.setFocus()

RegID's are simple way to access a control on the form.  You'll see the value 
of them soon.  Do not confuse 'RegID' with 'Name' they are not the same.

Johnf






___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907271334.46828.jfabi...@yolo.com


Re: [dabo-users] adding or removing a panel from a Form at runtime

2009-07-29 Thread John
On Wednesday 29 July 2009 04:05:56 pm Miguel Lopes wrote:
> I'm wondering about how to add or remove panels from a form at runtime.
> I see two approaches:
>
> 1. Creating a new panel and replacing an existing one (destroying the old
> one). Meaning the new panel would take whatever sizer slot the original
> panel was occupying.
>
> I haven't thought about how this could be achieved. Any clues?
>
> 2. Creating both panels up-front with one of them hidden (with the
> Visible property set to False) .
> Then it would be a matter of toggling the visibility of panels to hide
> or show them.
>
> I wonder if you have a better approach, or if there is something
> missing in the following approach?
>
> # Two panel classes are previously defined
>
> class MainForm(dui.dFormMain):
> def afterInitAll(self):
> vs = self.Sizer = dui.dSizer('v')
> btn = dui.dButton(self, Caption='Click me')
> vs.append(Panel1(self))
> vs.append(Panel2(self))
> vs.append(btn)
> self.layout()
>
> btn.bindEvent(dabo.dEvents.Hit, self.panelToggle)
>
> def panelToggle(self, evt):
> panel1 = self.getObjectByRegID("panel1")
> panel2 = self.getObjectByRegID("panel2")
>
> panel1.Visible = not panel1.Visible
> panel2.Visible = not panel2.Visible
>
> self.layout()
>
> Txs for comments,
> Miguel

http://dabodev.com/wiki/HowToOverlayControls
 
the above is a link to the wiki.  I believe that code at the link will work 
with any dabo object including panels.




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907291725.20289.jfabi...@yolo.com


[dabo-users] how can I refresh a dropdown

2009-07-30 Thread John
Hi,

I have a need to dynamicly refresh a dropdown.  I have tried using bindEvent 
for GotFocus, Hit, MouseLeftClick. Using the following code below to refresh 
the choices and keys.

Where courseID = the RegID of the dropdown
def courseChoices(self):
self.escourse.requery()
courseDS = self.escourse.getDataSet()
availableChoices=['']
keyChoices=[0]
for row in courseDS:
availableChoices.append(row['name_1'])
keyChoices.append(row['pkid'])

return availableChoices,keyChoices

def _refresh_courses(self):
self.courseID.Choices = []
self.courseID.Keys = []
ch,ky = self.courseChoices()
self.courseID.Choices = ch
self.courseID.Keys = ky
self.courseID.update()

On my system the form locks up on 
self.courseID.Choices = ch

Johnf



___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907301010.13803.jfabi...@yolo.com


Re: [dabo-users] how can I refresh a dropdown

2009-07-30 Thread John
On Thursday 30 July 2009 10:10:13 am John wrote:
> Hi,
>
> I have a need to dynamicly refresh a dropdown.  I have tried using
> bindEvent for GotFocus, Hit, MouseLeftClick. Using the following code below
> to refresh the choices and keys.
>
> Where courseID = the RegID of the dropdown
> def courseChoices(self):
>   self.escourse.requery()
> courseDS = self.escourse.getDataSet()
> availableChoices=['']
> keyChoices=[0]
> for row in courseDS:
> availableChoices.append(row['name_1'])
> keyChoices.append(row['pkid'])
>
> return availableChoices,keyChoices
>
> def _refresh_courses(self):
>   self.courseID.Choices = []
>   self.courseID.Keys = []
>   ch,ky = self.courseChoices()
>   self.courseID.Choices = ch
>   self.courseID.Keys = ky
>   self.courseID.update()
>
> On my system the form locks up on
> self.courseID.Choices = ch
>
> Johnf

I also can not get the .clear() to work.  

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907301121.30749.jfabi...@yolo.com


Re: [dabo-users] how can I refresh a dropdown

2009-07-30 Thread John
On Thursday 30 July 2009 11:21:30 am John wrote:
> On Thursday 30 July 2009 10:10:13 am John wrote:
> > Hi,
> >
> > I have a need to dynamicly refresh a dropdown.  I have tried using
> > bindEvent for GotFocus, Hit, MouseLeftClick. Using the following code
> > below to refresh the choices and keys.
> >
> > Where courseID = the RegID of the dropdown
> > def courseChoices(self):
> > self.escourse.requery()
> > courseDS = self.escourse.getDataSet()
> > availableChoices=['']
> > keyChoices=[0]
> > for row in courseDS:
> > availableChoices.append(row['name_1'])
> > keyChoices.append(row['pkid'])
> >
> > return availableChoices,keyChoices
> >
> > def _refresh_courses(self):
> > self.courseID.Choices = []
> > self.courseID.Keys = []
> > ch,ky = self.courseChoices()
> > self.courseID.Choices = ch
> > self.courseID.Keys = ky
> > self.courseID.update()
> >
> > On my system the form locks up on
> > self.courseID.Choices = ch
> >
> > Johnf
>
> I also can not get the .clear() to work.
>
> Johnf

This appears to be only an issue on Linux.  Running on Windows all works.  I 
wonder if this is related to my performance issue that I have.  

openSUSE 11.0, python 2.5.2, wxPython 2.8.10.1.

I very sure this in not a openSUSE issue because I have the same code running 
on ubuntu 9.04 and it response the same.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907301327.09291.jfabi...@yolo.com


Re: [dabo-users] SQLite and a grid

2009-07-30 Thread John
On Thursday 30 July 2009 12:41:48 pm Ivan Miller wrote:
> I am creating my first dabo app.  I am using SQLite for the database and
> created a form by following the "The Step-By-Step Guide to Dabo Programming
> "
>
> It works great for the data entry part and I can move through the records
> with the next and prev buttons.
>
> However, when I create a grid following the directions as best I can the
> form runs but the grid does not get populated.  Yes, I am doing the requery
> and other things listed in the guide.
>
> Also some weird stuff happens.
> 1) I can't change the captions or the datafield on the grid columns.  The
> caption always reverts to "Caption" and the datafield stays blank.
> 2) The datasource on the grid is set initially to "1" and if I change the
> grid datasource to "list" then I get errors and I can't even open the form
> in the class designer anymore.  I have to edit the cnxml file and change
> the datasource on the grid back to "1" for the form to open again.
>
> I am developing on Windows Vista with python 2.6.2 and dabo 0.9.2
>
> Is this and SQLite or Windows problem?  I have not tried this with mySQL
> instead of SQLite.
>
> Thanks for your help.
>
> Ivan Miller

Sorry Ivan Dabo is currently not supporting 2.6.  From my experience the very 
control you are having trouble with is the issue.  Our leaders (Ed and Paul) 
haven't had the time to determine the cause.  I can only suggest you move 
back to 2.5.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200907301820.15628.jfabi...@yolo.com


Re: [dabo-users] Class Designer not opening (again)

2009-08-02 Thread John
On Sunday 02 August 2009 09:13:51 am Steve Rose wrote:
> I am not trying to open an existing cdxml file.  I get the problem whether
> I run "dabo\ide\ClassDesigner.py" from the command line, or click on the CD
> shortcut on my desktop.  The only .cdxml files in that folder are
> PredEditor and mover.  Hope that helps.


Open a terminal or command prompt (depends on what platform you are using).
And post the traceback.  If you are using windows you can copy the traceback 
by right clicking on the upper left icon and using edit.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908020921.18773.jfabi...@yolo.com


Re: [dabo-users] Class Designer not opening (again)

2009-08-02 Thread John
On Sunday 02 August 2009 09:21:18 am John wrote:
> On Sunday 02 August 2009 09:13:51 am Steve Rose wrote:
> > I am not trying to open an existing cdxml file.  I get the problem
> > whether I run "dabo\ide\ClassDesigner.py" from the command line, or click
> > on the CD shortcut on my desktop.  The only .cdxml files in that folder
> > are PredEditor and mover.  Hope that helps.
>
> Open a terminal or command prompt (depends on what platform you are using).
> And post the traceback.  If you are using windows you can copy the
> traceback by right clicking on the upper left icon and using edit.
>
> Johnf

Sorry I did not notice that you had post earlier.  My email client broke out 
your posting as a new posting.  

I believe you are dealing with an old bug fixed sometime ago.  You might want 
to create a fresh install of Dabo or use SVN to install.  I'm sure either 
will fix the issue.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908020932.20855.jfabi...@yolo.com


[dabo-users] path of modules

2009-08-04 Thread John
Hi,
I'm trying to write some more example Dabo code to open and use openoffice's 
uno.py.   I know where my copy of uno.py happens to be.  So it's a simple 
task to add a pth file or add the path.  But I'm wondering how I can 
determine the location in a cross platform manner and also set the path in 
code.

Does anyone have any suggestions?

Johnf  


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908040750.45550.jfabi...@yolo.com


Re: [dabo-users] Quiting the application

2009-08-04 Thread John
On Tuesday 04 August 2009 08:27:11 am Manoharan Durga wrote:
> I am starting to make a DABO application. Hope to complete it with the
> help of everyone ;-)
>
> Have created a MainForm and created a Menu as well. The only menu option
> that is ready right now is to quit the application! Created the
> following entry.
>
> mentry = dabo.ui.dMenu()
> mentry.Caption = '&Entry'
> mentry.append('Quit', HotKey='Ctrl+Q', OnHit=doQuit, help='Exit
> Application')
>
> And, I created the following function doQuit.
>
> def doQuit(evt):
> self.Form.close()
>
> But, clicking this Quit menu does not close the form or exiting the
> application. (Clicking the x button of the window does close the form!)
> Can someone help?

There are two 'closes' 
1. close the window
   OnHit=app.onWinClose

2. close the app
  OnHit=app.onFileExit

You can check out usApp.py to determine what they do.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908040855.15963.jfabi...@yolo.com


Re: [dabo-users] Quiting the application

2009-08-04 Thread John
On Tuesday 04 August 2009 08:55:15 am John wrote:
> s

should be uiApp.py 

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908040908.05095.jfabi...@yolo.com


Re: [dabo-users] path of modules

2009-08-04 Thread John
On Tuesday 04 August 2009 11:03:03 am Ed Leafe wrote:
> On Aug 4, 2009, at 9:50 AM, John wrote:
> > I'm trying to write some more example Dabo code to open and use
> > openoffice's
> > uno.py.   I know where my copy of uno.py happens to be.  So it's a
> > simple
> > task to add a pth file or add the path.  But I'm wondering how I can
> > determine the location in a cross platform manner and also set the
> > path in
> > code.
>
> import sys
> sys.path.append("/path/to/my/module")
>
>
>
> -- Ed Leafe

I'm sorry if I miss led.  How do I find the file 'uno.py' on the users 
computer.  And then I can setup the path.

Your code helps after I find the location.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908041131.35122.jfabi...@yolo.com


Re: [dabo-users] path of modules

2009-08-04 Thread John
On Tuesday 04 August 2009 11:37:28 am Paul McNett wrote:
> Ed Leafe wrote:
> > On Aug 4, 2009, at 9:50 AM, John wrote:
> >> I'm trying to write some more example Dabo code to open and use
> >> openoffice's
> >> uno.py.   I know where my copy of uno.py happens to be.  So it's a
> >> simple
> >> task to add a pth file or add the path.  But I'm wondering how I can
> >> determine the location in a cross platform manner and also set the
> >> path in
> >> code.
> >
> > import sys
> > sys.path.append("/path/to/my/module")
>
> But, it is really up to the setup of the machine to make sure a module
> is importable. Your app shouldn't have to know *where* uno.py is, it
> should just be able to 'import uno' because uno has been properly
> installed in site-packages (or Ubuntu's dist-packages invention).
>
> Paul

Ok I think I understand.  However, OpenOffice is NOT following the python 
convention.  It places the uno.py file in 
the "/usr/lib/ooo3/basic3.1/programs" directory on my system and something 
different on windows.  I'm guessing, but  I bet ubuntu has the file in a 
different location.   And of course then there is OSx.

So I thought there some be some way to find the File.

Johnf




___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908041201.59217.jfabi...@yolo.com


[dabo-users] EOF() in reportWriter

2009-08-05 Thread John
Is there an EOF() or a flag that I can use to determine I have filled the 
detail band with all the data.

Johnf


___
Post Messages to: Dabo-users@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: 
http://leafe.com/archives/byMID/200908051030.48302.jfabi...@yolo.com


  1   2   3   4   5   6   7   8   9   10   >