• bdensmore
  • NEWBIE
  • 0 Points
  • Member since 2008

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 8
    Questions
  • 4
    Replies
I've been looking at the examples that people have posted here for the apex:inputFile but every example seems to just save the file to the "My Documents" section.

I need to just pass the file off to a WebService instead, I don't need to save the file anywhere. Is there a better method of doing this, should I not be using an inputFile?

Thanks,
Ben
I have a WSDL file that I imported into Salesforce and generated the class file. I can instantiate the object with no issues but as soon as I try to call a method from that file I get

"Method does not exist or incorrect signature."

Is there anything special I need to do? I can't see why this would not work.

Here is my code

  sovrenCom sovren = new sovrenCom();
  String version = 'Version Info = ' + sovren.GetVersionInfo();

Here is the method in the .cls file.

        public String GetVersionInfo() {
            sovrenCom.GetVersionInfo_element request_x = new sovrenCom.GetVersionInfo_element();
            sovrenCom.GetVersionInfoResponse_element response_x;
            Map<String, sovrenCom.GetVersionInfoResponse_element> response_map_x = new Map<String, sovrenCom.GetVersionInfoResponse_element>();
            response_map_x.put('response_x', response_x);
            WebServiceCallout.invoke(
              this,
              request_x,
              response_map_x,
              new String[]{endpoint_x,
              'http://Sovren.com/GetVersionInfo',
              'http://Sovren.com/',
              'GetVersionInfo',
              'http://Sovren.com/',
              'GetVersionInfoResponse',
              'sovrenCom.GetVersionInfoResponse_element'}
            );
            response_x = response_map_x.get('response_x');
            return response_x.GetVersionInfoResult;
        }

Thanks,
Ben
I'm trying to grab data from a custom field on my Contact object in PHP but for some reason it always comes back empty. In my query I can filter on that field and using the SOQL Explorer if I run the same query I see the value for that field. Is there something special I need to do to get the value of a special field?

This is my code, the ID field shows up fine but not the custom_field__c.

try {
  $mySforceConnection = new SforceEnterpriseClient();
  $mySoapClient = $mySforceConnection->createConnection(SOAP_CLIENT_BASEDIR.'/enterprise.wsdl.xml');
  $mylogin = $mySforceConnection->login("mylogin", "mypassword");

  $query = "Select Id,custom_field__c From Contact where custom_field__c != null";
  $options = new QueryOptions(10);
  $mySforceConnection->setQueryOptions($options);
  $response = $mySforceConnection->query($query);
  !$done = false;
  $RecordNum = 0;

  echo "Size of records:  ".$response ->size."<br />";

  if ($response->size > 0) {
    while (!$done) {
      foreach ($response->records as $record) {
          $RecordNum = $RecordNum + 1;
        echo $RecordNum.". ".$record->Id." - ";
        echo $record->custom_field__c."<br />";
      }
      if ($response->done != true) {
        try {
          $response = $mySforceConnection->queryMore($response->queryLocator);
        } catch (Exception $e) {
          print_r($mySforceConnection->getLastRequest());
          echo $e->faultstring;
        }
      } else {
        $done = true;
      }
    }
  }

} catch (Exception $e) {
  print_r($mySforceConnection->getLastRequest());
  echo $e->faultstring;
}
I'm using the Web Service API to query a salesforce account. I'm trying to grab all records from the Contact Object but it always returns 2000, even though there are almost 6,000 records in there.

I've looked at some of the other posts and they recommended adding some criteria to the query which I did but I always get 2000 records.

Is there a way to bypass this limit?

Thanks,
Ben
I'm using the blogger API and trying to loop over all the entries from my blogger account. There is an element called totalResults that contains the total number of posts in the blog.

When I try to assign totalResults to an Integer I keep getting this error:
Save error: Initial term of field expression must be a concrete SObject: LIST:XMLDom.Element

I've tried assigning it to lists, converting it to an Integer and I keep getting this error.

Does anyone know of a way to do this?

This is what I'm testing with:
       xmldom.element oneBlog = service.getBlogTitle(allBlogs.entries[0].getValue('title'));
       string postFeedUrl = GoogleData.getRelLink(oneBlog, BloggerService.postUrl);
       GoogleData posts = service.getFeed( postFeedUrl );
       Integer entryLen =  posts.entries.totalResults;

Thanks,
Ben

Does anyone have a dummies guide to being able to authenticate to google to be able to post to the blogger account?

I followed the tutorial on getting the AuthSubToken but can't seem to get it to work. The visual force page to send the user to authenticate saves ok but when I try to add the page to an  object it never gives me that page as an option to insert.

I can't believe I can't just pass in a username and password to the Blog API and post and delete. Maybe I am missing something, but the whole process seems very tedious.

Does anyone have some experience with this and can share their wisdom?

Thanks,
Ben
We have a project that requires some Apex development that needs to be turned around today.

Is there anyone who is very experienced with Apex code that might be available to work on this?

Thanks,
Ben
I'm storing some information in a flashpaper .swf file that gets uploaded as an attachment for a contact.

How can I reference that .swf from within the <apex:flash> tag? I tried creating a custom controller and calling the attachment but that didn't seem to work.

Thanks,
Ben
I'm storing some information in a flashpaper .swf file that gets uploaded as an attachment for a contact.

How can I reference that .swf from within the <apex:flash> tag? I tried creating a custom controller and calling the attachment but that didn't seem to work.

Thanks,
Ben