|
jlockley (TechnicalUser) |
24 Oct 10 19:04 |
I've struggled on and off with ObjectPal for a number of years, and I am not really good at it, (bad memory and not enought time to really get involved). I'm at it again, trying to put together a script to permit me to access and program a query from a user interface. Using a script and method from the db community (which seems to have changed? Not be accessible?) I've got the structure below. I have two questions:
Somewhere in a lot of fields I've made a mistake resulting from an undefined variable. (Due to my poor practices in naming the fields in the table, I had to correct many and now will have to go back and correct the table - I imaging that there's a typo in the list). The syntax checks and the data model is set to the correct DB.
At any rate, with about 200 fields I am having a hard time indentifying the error. I've gone through everything twice, but proof reading is not a strength.
Is there a way to identify the discrepency via Paradox rather than going through the data a piece at a time?
any help will be appreciated A truncated version of the program is below.
method pushButton(var eventInfo Event) var StNAME String stLOCATION String stTITLE String stPARTNER String stDATE String stTelephone String stFax String
;...sample of about 200 fields
Endvar ;============================== Parameters
if StNAME.isBlank() then StNAME = "Check" else StNAME = "Check, " + StNAME endif ;................. if stLOCATION.isBlank() then stLOCATION = "Check" else stLOCATION = "Check, " + stLOCATION endif ;................. if stTITLE.isBlank() then stTITLE = "Check" else stTITLE = "Check, " + stTITLE endif ;................. if stPARTNER.isBlank() then stPARTNER = "Check" else stPARTNER = "Check, " + stPARTNER endif ;................. if stDATE.isBlank() then stDATE = "Check" else stDATE = "Check, " + stDATE endif ;................. if stTelephone.isBlank() then stTelephone = "Check" else stTelephone = "Check, " + stTelephone endif ;................. if stFax.isBlank() then stFax = "Check" else stFax = "Check, " + stFax endif
;.......etc end parameters
:........Query
quQuery = QUERY
ANSWER: : C:\Roladex\results.DB
newrol.DB | NAME | LOCATION | TITLE | PARTNER | DATE | Telephone | | Check | Check | Check | Check | Check | Check |
newrol.DB | Fax | | Check | ;......sample of about two hundred fields
ENDQUERY
quQuery = QUERY
errorTrapOnWarnings(Yes) quQuery.writeQBE(":Work:Query.QBE") try quQuery.executeQBE() tvResults.open(":Work:OrderInfo1.DB") tvResults.wait() tvResults.close() onFail errorShow() msgStop("", "") endTry errorTrapOnWarnings(No)
endMethod
| Check | |
|