The following code is from a database called “Inquiries”:
if (info(“files”) notcontains “Customers”)
openfile “Customers”
endifif emptycell(«Terms»)=false()
message “Terms field is empty.”
endif
If the Customers database is not open, the openfile function will open the Customers database, and the following error will occur.
“sizeof( function error: no field or variable named “Terms”.”
However, the field “Terms” does exist in the Inquiries database. This procedure will recognize that the field “Terms” exits, as long as it doesn’t have to open the database “Customers”.
My workaround solution is the following.
local iTerms
iTerms=«Terms»if (info(“files”) notcontains “Customers”)
openfile “Customers”
endifif sizeof(iTerms)=0
message “Terms field is empty.”
endif
FYI, both databases are shared.
Why is this error occurring?