function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
michaelforcemichaelforce 

Flex Toolkit - Describe Call Bug

Dev Team,
 
Wasn't sure where to report possible bugs, so I'm throwing it up here in case others are running into it as well...  Certain SObjects are causing errors when being described via the Flex toolkit.  Somewhere in 'com.salesforce.results.DescribeSObjectResult' a null object is being referenced when trying to describe certain objects.  I could be wrong on a few of them, but I narrowed it down to the following list of objects possibly causing the error when described:
 
"ActivityHistory", "BrandTemplate", "BusinessProcess", "Document", "EmailStatus", "FiscalYearSettings", "Name", "NoteAndAttachment", "OpenActivity", "OpportunityLineItem", "Period", "PricebookEntry", "Profile", "ProcessInstanceHistory", "QuantityForecast", "QuantityForecastHistory", "RevenueForecast", "RevenueForecastHistory", "Scontrol"
 
The exact text of the actionscript error is below:
 
TypeError: Error #1009: Cannot access a property or method of a null object reference.
 at com.salesforce.results::DescribeSObjectResult$iinit()
 at ::SalesForceResponder/result()
 at mx.rpc::AsyncToken/http://www.adobe.com/2006/flex/mx/internal::applyResult()
 at mx.rpc.events::ResultEvent/http://www.adobe.com/2006/flex/mx/internal::callTokenResponders()
 at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent()
 at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::resultHandler()
 at mx.rpc::Responder/result()
 at mx.rpc::AsyncRequest/acknowledge()
 at ::DirectHTTPMessageResponder/completeHandler()
 at flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction()
 at flash.events::EventDispatcher/dispatchEvent()
 at flash.net::URLLoader/flash.net:URLLoader::onComplete()
 at flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction()
 at flash.events::EventDispatcher/dispatchEvent()
 at flash.net::URLLoader/flash.net:URLLoader::onComplete()
michaelforcemichaelforce

I wrote a quick flex app to narrow down the list of culprits... describing each object returned in the describeGlobal call one at a time, I caught the error only on the following:

"BrandTemplate", "BusinessProcess", "Document", "FiscalYearSettings", "OpportunityLineItem", "PricebookEntry", "Profile", "QuantityForecast", "RevenueForecast", "Scontrol", "UserLicense"

Message Edited by michaelforce on 10-07-2007 01:45 PM

Ron HessRon Hess
there was a misplaced '!' , thanks for reporting this.

if ( !val is ObjectProxy )
should be
if ( val is ObjectProxy )

The fix is checked into the src tree, the file in question is describesobjectresult.as
next build should be early this week, will include this fix.




Ron HessRon Hess
new library released this morning 3_10
let me know if you see any new or old issues
michaelforcemichaelforce

Ron,

Thanks for the update... it's running quite nicely.  If something else pops up should I post a message or shoot you an email?

Ron HessRon Hess
post it here, if you email i may ignore it... :smileysurprised:

if my bugs appear here for all to read about, then i'm forced to improve my process... :smileywink:
ar_sfdcar_sfdc

I seem to getting the exact same error on the 'Aggregate Result'  Object, this seems to be abug. It seems to work fine on all the other objects..