Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How would one instantiate a .NET DLL from VFP8?

Status
Not open for further replies.

jbailey268

Programmer
May 25, 2005
51
US
Hope this is the right forum.

I want to benchmark the speed between the old Street Component (written in VFP8) and a .NET equivalent that was recently translated to the .NET platform (Studio 2005).

Originally (in VFP8) I would say oSTR=CREATEOBJECT("Street.Compare")

Is the Syntax exactly the same? Namely,
oStrNew = CREATEOBJECT("StreetDotNet.Compare")

All parameters passed in are the same, 2 strings and 2 integers.
Original Way:
match=oStr.IsEquivalent("125 Second Avenue","125 2nd Ave.",1,0)

New Way ??? Will this work?
ex) match=oStrNew.IsEquivalent("125 Second Avenue","125 2nd Ave.",1,0)

Has anyone tried this kind of thing?
Thanks

As a side note: The string comparison stuff and the array list stuff in .NET were challenging to get thru to make it functionally equivalent. Seems so much easier in VFP.
Where is OCCURS(), SOUNDEX(), DIFFERENCE(), GETWORDNUM() ,
AT(where the need is to find 2nd or 3rd occurence) ?

Maybe it only seems easier in FoxPro because I've been in it for over a decade. Whereas, .NET is all new to me.
 
That's odd to me too. I originally sent this to the Regular VFP forum and when I went back it was not there.
So I put the question again in the Fox Sub-forum regarding Classes.

Checked out the link...The code magazine stuff is great and needs more in depth research for now - too much.

Just was asking what the VFP syntax was to to execute/instantiate a .NET dll from the command window or in a prg.
 
Is the Syntax exactly the same? Namely,
oStrNew = CREATEOBJECT("StreetDotNet.Compare")

Are you asking if its the same code in .Net?

In VFP, as I am sure you are aware, its the same to instantiate and execute a .Net .dll as long as it is registered
 
Thanks, I just needed some validation that what I assume to be true is so. I will register the .NET dll and try it out.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top