[Zope-dev] Method calls

Steve Spicklemire steve@spvi.com
Thu, 23 Nov 2000 09:09:40 -0500 (EST)


Hi Roch,

   The whole traceback would be helpful.. one clue:

Error Type: TypeError
Error Value: hasattr, argument 2: expected string, int found

'hasattr' is the function that is complaining.... do you use
it in your code? 

-steve
>>>>> "Roch'e" == Roch'e Compaan <roche@ybm.co.za> writes:

    Roch'e> I have a method called getModulesForProduct to which I
    Roch'e> pass a ProductID eg: <dtml-in
    Roch'e> "Products.Modules.getModulesForProduct(this(), _,
    Roch'e> ProductID)" sort=name>

    Roch'e> If ProductID is passed on from a form variable it works
    Roch'e> fine.

    Roch'e> If I set the ProductID through REQUEST.set: <dtml-call
    Roch'e> "REQUEST.set('ProductID',_.str(Product.id))"> ,

    Roch'e> I get a TypeError:

    Roch'e> Error Type: TypeError Error Value: hasattr, argument 2:
    Roch'e> expected string, int found

    Roch'e> I've been banging my head against this problem the whole
    Roch'e> day so help would really be appreciated.

    Roch'e> Roché






    Roch'e> _______________________________________________ Zope-Dev
    Roch'e> maillist - Zope-Dev@zope.org
    Roch'e> http://lists.zope.org/mailman/listinfo/zope-dev ** No
    Roch'e> cross posts or HTML encoding!  ** (Related lists -
    Roch'e> http://lists.zope.org/mailman/listinfo/zope-announce
    Roch'e> http://lists.zope.org/mailman/listinfo/zope )