Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
DLL in Foxpro - Tables in App, UI functions
Message
From
11/11/1998 05:43:03
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Other
Title:
DLL in Foxpro - Tables in App, UI functions
Miscellaneous
Thread ID:
00156508
Message ID:
00156508
Views:
61
Hi!

I am trying to write a DLL in Foxpro.

This is what I've done for one part.
DEFINE class dblib AS CUSTOM OLEPUBLIC
PROCEDURE test
LPARAMETERS lnConnectionHandle,dest
temp="mainkey='Womens Wear*23809-1'"
LSQL='PDMSELECTWO measure,"'+ temp +'"'

nerror=SQLEXEC(lnConnectionHandle,LSQL,dest)
select &dest
IF nerror!=1
AERROR(aErrorArray)
lcerrorstring="SQL Server Error : "+STR(aErrorArray(1,1))
lcerrorstring=lcerrorstring+aErrorArray(1,2)+CHR(13)
lcerrorstring=lcerrorstring+aErrorArray(1,3)+CHR(13)
RETURN lcerrorstring
ENDIF
RETURN
ENDDEFINE

I also tried commeands like select &dest table
and INDEX ON field tag field

which don't fail in the dll.

But I want to have the table available to me after.
SO I do a
otest=CREATEOBJECT("dblink.dblib")
handle=otest.connect() &&One of my other functions

But When I do:
resultotest.test(handle,'worktable') &&One of my other functions

I cannot select the work table.


The questions:
1) Can I not select a table in a DLL and have it available to my
Application

2) I can't do things like SQLCONNECT(), BROWSE, MESSAGEBOX
Why not! Is there a way to do this???


Thanks a Mill
Next
Reply
Map
View

Click here to load this message in the networking platform