Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CFC Object get method call problem

Status
Not open for further replies.

nwyork

Programmer
Oct 23, 2004
26
0
0
US
I'm redoing a shopping cart to be object based. I have a user object with a getDiscount method. I keep getting error when I call the method "The value "cfuser2ecfc1565979364$funcGETDISCOUNT" cannot be converted to a number".

Here is my code:

initializing:
<cfset session.objUser = createObject("component","cfcs.user").init(FORM.Email,FORM.Password)/>

calling:
<cfset Discount = session.objUser.getDiscount/>

This is my first time doing oo in cf so any help would be appreciated.

Thanks,
Nick
 
I think my object is not being initialized correctly. But still if anybody has an example that would be great.
 
The problem was I wasn't () after method call.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top