You need to sign in to do that
Don't have an account?
Alaa
http callouts in apex triggers
Hi Am trying to do soem HTTp callouts from an apex triger but when itest it fires I get the error:
contact your administrator Callout from triggers are currently not supported
whats this? any idea?
Its exactly what it says I'm afraid - you can't make HTTP callouts from a trigger as you would be holding up the transaction for potientially a long period of time.
Typically you'd call an @future method to make the callout, as this would be called asynchronously after the transaction has completed.
thanks.. am new to apex so do you have any example how can I use that @future method?
There's more information in the Apex Developer's Guide at:
http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_classes_annotation_future.htm?SearchType=Stem&Highlight=future|Future
but basically, you just call it as you would any other method. The @future decoration on the method means that it gets "queued" for later execution.