Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Stonefiled and MMortals Update not locating Database.
Message
 
 
To
03/02/2003 13:07:41
General information
Forum:
Visual FoxPro
Category:
The Mere Mortals Framework
Miscellaneous
Thread ID:
00748479
Message ID:
00749016
Views:
31
To establish the database for use by SDT, your code should look something like the following. Just modify to fit with the MM instructions.
oMeta = NEWOBJECT("DBCXMgr", "DBCXMgr")
IF VARTYPE(oMeta) <> "O" OR ISNULL(oMeta)
   MESSAGEBOX("Could not open SDT")
   RETURN .F.
ENDIF
*!* If the database is already open:
SET DATABASE TO DATABASE_NAME
llRetVal = oMeta.SetDataBase(DBC())
IF NOT llRetVal
   MESSAGEBOX("Error Establishing Default Database")
   RETURN .F.
ENDIF

*!* If the database is NOT already open:
IF !oMeta.oSDTMgr.OpenData(ADDBS(lcDataPath) ;
      + DATABASE_NAME, .T., llExclusive)
   MESSAGEBOX("Error Opening Database")
   RETURN .F.
ENDIF
>Hello Everyone,
>
>I've instantiated the Stonefield class according to the Mere Mortals instructions, but the update method is not finding any open database to act upon. I can see properties I could set to force the database name. What part of the instructions is missing to have stonefield's update method work with Mere Mortals?
Mark McCasland
Midlothian, TX USA
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform