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
HomeyHomey 

How to search custom objects using Web Service API

I'm using the web services API to retrieve the list of the Global Objects by name using the describeGlobal() webservice call as follows:

 

DescribeGlobalResult describeGlobalResult = binding.describeGlobal();

if (!(describeGlobalResult == null)) {

types = describeGlobalResult.getTypes();

}

 

The problem is that all I get are standard objects non of the custom objects in the result.  I would very much appreciate any information that would provide an idea as to how to retrieve the list of custom objects via the web service.  Please note that I have created some custom objects in the same SalesForce instance. 

SuperfellSuperfell
the describeGlobal call returns all the types the calling user has access to. If you've created new custom objects, make sure they're set to deployed and not in development, also check that the user has access to them via their profile.
HomeyHomey
I can confirm that the custom objects are deployed, but the describeGlobal call is not returning the two custom objects that have been added.  I  can see them when I log in via the same profile that is being used when retrieving the meta data using the describeGlobal call.  I'm completely stumped.
THustonTHuston

This is working just fine in my organization.  Unfortunately I don't know how it was set up.  I'm just writing an ODA to query against it.

 

            DescribeGlobalResult describeGlobalResult = binding.describeGlobal();
            if (!(describeGlobalResult == null)) {
                DescribeGlobalSObjectResult[] types = describeGlobalResult.getSobjects();

 

I'm using the new Partner WSDL, and I think getTypes and getSobjects do the same thing.