Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
S*O*S !!! -- CreateObject() = Syntax Error
Message
From
06/07/1999 11:53:34
Len Wooden
Statistical Resources, Inc
Baton Rouge, Louisiana, United States
 
 
To
06/07/1999 09:52:29
Kenneth Downs
Secure Data Software, Inc.
New York, United States
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Miscellaneous
Thread ID:
00237700
Message ID:
00237803
Views:
12
>
>Can you repost the exact command that is giving the syntax error?
>
  l_cparmmac = ""
  IF l_nqtyparms >= d_nfirstinit
    FOR l_n = d_nfirstinit TO l_nqtyparms
      l_cparmmac = l_cparmmac + ", p_xparm" + LTRIM(STR(l_n-d_nfirstinit + 1))
    ENDFOR make A string OF parms TO pass
  ENDIF
  IF !EMPTY(p_cclasslib) && they sent us a class library 
    l_ccreateobj = ["] + p_cclasslib + "." + p_cclassname + ["] + l_cparmmac
    This.r_aregis[1, d_nobjectcol] = createobject(&l_ccreateobj)
  ENDIF
where d_nfirstinit = 5, d_nobjectcol = 2 and in the example that created the syntax error l_nqtyparms = 6 , p_cclasslib = "SRI_reps", p_cclassname = "REP_FILTERS", p_xparm1 = "REPORT BILLING REPORT", p_xparm2 = "", and this results in
l_ccreateobj = ""SRI_reps.REP_FILTERS", p_xparm1, p_xparm2" && quotes shown as they appear in the debug window

and remember, the code works 99% of the time.

-- Len
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform