Error in Windows standalone

Paul Foraker paul.foraker at gmail.com
Mon Apr 11 18:27:23 EDT 2011


I've built a little app that is generating a script error on Windows 7, but
not on XP or Mac. On Win 7, the app generates this error message:

Executing at 2:58:29 PM
Type
Object  card id 1002
Line    put 'Object' & tab & the short name of tObject & cr after
tErrorString
Hint    preOpenCard

I don't have access to the Win 7 machine to run the stack in LiveCode, so
I'm relying on my user to run the standalone and let me know how it goes. So
far, not so good.

The stack is a one-card stack with a data grid and the revExternalLibrary
for MySQL support. All three stacks have a card id 1002, but none of them
have scripts. There is no "preOpenCard" handler in any object in the stack
files. There is no such command as in the line above in use in any script
that I can find.


On preOpenStack, the main stack opens a file on the user's hard drive, using
this code:

function actionFile pFname
   if the platform contains "Mac" then
      put specialFolderPath("Preferences") into tPath
   else -- windows
      put "0x000C" into myDocs
      put specialFolderPath(myDocs) into tPath
   end if
   put "/4Spires" after tPath
   if there is no folder tPath then create folder tPath
   put "/" &pFname &".txt" after tPath
   return tPath
end actionFile

I'm passing this function the string "ActionHistoryURLs" which is the name
of a file containing a return-delimited list of urls the user has entered.
If there are none yet, I use a default url instead. I use the first one in
the list (or the default one) to open a file on the server containing
encrypted database configuration information. I decrypt the config info and
execute a query to get the "action history" from the database, and then
populate the datagrid. Works fine on Mac and XP. Chokes on Win 7 in two
ways. First, it never gets the data from the default url; second, when the
user clicks that default url in a list, it should go get the data. That's
when the interrupt occurs, and he sends me the error message.

I'm wondering if this error is occurring in some part of the engine code
instead of mine, and what's up with the single quotes in the command?

Any ideas?

-- Paul



More information about the use-livecode mailing list