Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #9510

Re: IsMethod() for use in functions

From "Wolfgang Riedmann" <wriedmann@gmail.com>
Newsgroups comp.lang.clipper.visual-objects
Subject Re: IsMethod() for use in functions
Date 2016-07-06 08:26 +0200
Message-ID <du3mk6FegtbU1@mid.individual.net> (permalink)
References <aopnnb109gjouifhggg7qntmlhv2aca0ri@4ax.com> <du2b9sF4tbaU1@mid.individual.net> <7b1onb5ll4canvl4atovj95868k9knr8d9@4ax.com>

Show all headers | View raw


Hi Dick,

> > I don't know if there is a function to check for a function
> > existence - but you can call a function with Clipper calling
> > convention with _CallClipFunc() passing the parameters in an array.
> > 
> 
> I wasn't aware of this one (I even couldn't find it in the help! -
> where did you get this from?) I see that it's used in the
> SystemLibrary a few times.

it is not documented <g>. I think someone pointed me there...

> But somehow it doesn't seem to work. I have this in my code:
 
> _CallClipFunc(#TestThis,{"Hello"})
> 
> and straight below it:
> 
> FUNCTION TestThis(cParm AS STRING)
> ErrorBox{,cParm}:Show()
> RETURN TRUE

maybe you should remove the "as string" from the parameter?

For me the following code works:

METHOD OKButton( ) CLASS MainDialog

_CallClipFunc( #DickFunc, { self, "Hi Dick" } )

SELF:EndDialog(0)
RETURN SELF	

function DickFunc( oWindow, cMessage )

InfoBox{ oWindow, "DickFunc", cMessage }:Show()
	
return nil

Wolfgang

-- 

Back to comp.lang.clipper.visual-objects | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

IsMethod() for use in functions D.J.W. van Kooten <vankooten@removethis.ic2.com> - 2016-07-05 19:01 +0200
  Re: IsMethod() for use in functions "Wolfgang Riedmann" <wriedmann@gmail.com> - 2016-07-05 20:06 +0200
    Re: IsMethod() for use in functions D.J.W. van Kooten <vankooten@removethis.ic2.com> - 2016-07-05 21:11 +0200
      Re: IsMethod() for use in functions "Wolfgang Riedmann" <wriedmann@gmail.com> - 2016-07-06 08:26 +0200
  Re: IsMethod() for use in functions "Karl-Heinz" <invalid@invalid.invalid> - 2016-07-05 21:19 +0200
    Re: IsMethod() for use in functions D.J.W. van Kooten <vankooten@removethis.ic2.com> - 2016-07-06 12:00 +0200
      Re: IsMethod() for use in functions "Wolfgang Riedmann" <wriedmann@gmail.com> - 2016-07-06 14:55 +0200
      Re: IsMethod() for use in functions "Karl-Heinz" <invalid@invalid.invalid> - 2016-07-06 21:05 +0200
      Re: IsMethod() for use in functions "Karl-Heinz" <invalid@invalid.invalid> - 2016-07-07 08:18 +0200

csiph-web