Re: [Gambas-user] Passing ... parameters

2011-12-10 Thread GMail
Ha! Got it solved. All I need to do is the same check in the wrapper as the base class. There appears to be a strange effect if there is only on real parameter and it is already a Variant[]. So I just check for that instance in the wrapper class and call the base DBRead directly using Param[0]. N

Re: [Gambas-user] Passing ... parameters

2011-12-09 Thread Fabien Bodard
Public Function DBRead(...) as Boolean    Dim localtarget as Object   Dim localquery as String   Dim localsort as String    If Param.Count = 1 and Param.all[0] is QBE then decipher_QBE(Param.all[0],localtarget,localquery,localsort) Return Super.DBRead(localobject,localquery,localsort)   else Return

Re: [Gambas-user] Passing ... parameters

2011-12-09 Thread Jussi Lahtinen
> I can't debug it??? > When I try and display the Param class in the debugger or include things > like Debug Param[0] it shows an "Out Of Bounds" error. > Is this something I've done or a gb3 issue? > In short; only problem left is with debugging? I have no problems with "Debug Param[0]", but whe

Re: [Gambas-user] Passing ... parameters

2011-12-09 Thread Bruce Bruen
Fabian and Jussi, Thanks guys, this is now so close it hurts! On Fri, 2011-12-09 at 20:04 +0200, Jussi Lahtinen wrote: > Perhaps you need something like this: > > Public Function F1(...) As Integer > > Return F2(Param.All) > > End > That (Param.All) appears to be the big part of the solu

Re: [Gambas-user] Passing ... parameters

2011-12-09 Thread Fabien Bodard
it really depend of what you want to do :/ 2011/12/9 Jussi Lahtinen : > I don't know how to do this directly, but there are several ways to do it > indirectly. > Perhaps you need something like this: > > Public Function F1(...) As Integer > >  Return F2(Param.All) > > End > > > Public Function F2(

Re: [Gambas-user] Passing ... parameters

2011-12-09 Thread Jussi Lahtinen
I don't know how to do this directly, but there are several ways to do it indirectly. Perhaps you need something like this: Public Function F1(...) As Integer Return F2(Param.All) End Public Function F2(ArraOfParameters As Variant[]) As Integer Return ArraOfParameters.Count End But even

Re: [Gambas-user] Passing ... parameters

2011-12-09 Thread Fabien Bodard
hum there is someting that hurt me ... how are passed your params ... in what variable ? for exemple ... if all is string like : (param1, para2, para3) use an array Public Funtion F2(MyParam as string[]) as end call it F2(split(sParam,",")) to use "..." it's really rare it's for polymorp

[Gambas-user] Passing ... parameters

2011-12-08 Thread Bruce Bruen
Hi folks, I'm looking for a way to pass all the ... parameters in a function call on to another function. In other words, I have a situation where I want to pass all the extra parameters, but I don't know/care how many there are, viz Public Function F1(sType as String,...) as Boolean If sTyp