Re: Passing by VALUE / CStr equivalent

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



using = with a function or an activex can only be used to return a value,
and you have to do so in the order that i showed, you cannot set a property
or parameter in that manner. the description of the function call you gave
me implied that it would return something with a type of long. and required
the two parameters that you are already passing.


"S Bans" <SBans@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:F8983956-E881-43B5-BCA2-B30F73A409A6@xxxxxxxxxxxxxxxx
Hello Mark,

Please accept my thanks for your suggestion.

So far as I am getting impression is that this code is not returning any
value. Rather it is storing the value 64 to some property/parameter of
some
routine.

I will look forward to any further guidance in this regard.

With Regards

S Bans



"Mark Burgum" wrote:

i think what you need to do is

m.retval = Analysis1.Filter(0,"watchlist")

that way whatever value this function returns is placed in retval

"S Bans" <SBans@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:7AF21C40-A377-468F-A798-9B9544267730@xxxxxxxxxxxxxxxx
Hello friends,

In our of my Visual foxPro (Ver 8) codes I am using OLE Automation to
Run
another program. Definition of a property of One of the objects is as
follows
:

Property Filter(ByVal nType As Integer, ByVal pszCategory As String) As
Long
[r/w]

The code I used to implement contained the following line :

Analysis1.Filter(0,"watchlist") = 64

I get error "Function Argument value, type or count is invalid"

The support department of the application suggests that :


we must take attention to pass the watch list name BY VALUE.

Consult the manual for Foxpro how to pass BY VALUE.
In Visual Basic for example the function CStr is used for that purpose:

Analysis1.Filter(0,CStr("watchlist")) = 64


I am looking forward to guidance of seniors to implement this thing in
VFP
code. Please do guide if I have put my question appropriately or do I
need
to
present more of my code here. I have posted only the problem line here
so
as
not to confuse matters. Otherwise my code is working fine. Please
accept
my
thanks in advance.

With Regards

S Bans





.



Relevant Pages

  • Re: Passing by VALUE / CStr equivalent
    ... With Regards ... S Bans ... In our of my Visual foxPro codes I am using OLE Automation to Run ... I am looking forward to guidance of seniors to implement this thing in VFP ...
    (microsoft.public.fox.programmer.exchange)
  • Re: Control on Form for numeric values
    ... With Regards ... S Bans ... values in the Spinner Object remains in multiples of 0.05 even if ... looking forward to guidance of seniors for implementing it. ...
    (microsoft.public.fox.programmer.exchange)
  • get new list id
    ... Need your guidance on this once, and thanks for the help before. ... Best regards, ... William ... Prev by Date: ...
    (microsoft.public.sharepoint.portalserver.development)
  • Re: Downloading Zip file from internet.
    ... Pro as OS and Mcafee virusscan and Firewall. ... > S Bans wrote: ... >> Regards, ...
    (microsoft.public.fox.programmer.exchange)
  • Re: Preset list in text box
    ... "Fred Taylor" wrote: ... > Set the .Format property of your TextBox: ... Is there any solution in Visual FoxPro. ... >> Best Regards, ...
    (microsoft.public.fox.programmer.exchange)