• VDave
  • NEWBIE
  • 20 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 7
    Questions
  • 5
    Replies
When I execute searchAndGetScreenPopUrl I only get 25 results per type of object. Additional matches are not returned. When you do a non api search, aka a search form the search bar results are provided in pages of 25. I am looking at the pdf (http://www.salesforce.com/us/developer/docs/api_cti/api_cti.pdf) and I don't see any mention of a limit or a way to page the results.  Also, there isn't anything in the response that would indicate additional results can be found. Am I missing something? Is there a way to get all results?
  • May 29, 2014
  • Like
  • 0
Maybe I am missing something here but is it possible to include a softphone layout in the managed package? I don't see a way form the Add to Package screen.
  • April 28, 2014
  • Like
  • 0
I am having trouble getting my Visualforce page to make an AJAX request in IE 10, 11.  Everything works fine in Chrome, and Firefox but in IE 10, 11 I get status 0 when I make a request.  I can't figure out what I am missing. Is there a bug/limitation somewhere that I am unaware of?

Here is the code (http://jsfiddle.net/LmfsY/2/) on jsfiddle showing it works outside of Visualforce.

Here is a  Visualforce page that demonstrates the issue.

<apex:page>
 
  <div class="document">
    <a class="ajax" href="#">Fire an AJAX request</a>
  </div>
 
  <script src="https://code.jquery.com/jquery-latest.min.js"
        type="text/javascript"></script>
  <script>
   $.support.cors = true;
    $(function() {

        $('.document').on('click', '.ajax', function(e) {
            e.preventDefault();
   
            // ajax request
            $.ajax({
                type: 'get',
                url: 'https://cors-test.appspot.com/test',
                dataType: 'html',
                beforeSend: function() {
                    console.log('Fired prior to the request');
                },
                success: function(data) {
                    console.log('Fired when the request is successful');
                    $('.document').append(data);
                },
                error: function (xhr) {
                    console.log('Fired when the request is NOT successful');
                    $('.document').append(JSON.stringify(xhr));
                },
                complete: function(xhr) {
                    console.log('Fired when the request is complete');
                }
            });
   
        });
   
    });
  </script>
 
</apex:page>

In IE the provided visual force page results in {"readyState":0,"status":0,"statusText":"Access is denied.\r\n"}
In Chrome/Firefox the provided visual force page results in {"status":"ok"}
  • April 23, 2014
  • Like
  • 0
The API (http://www.salesforce.com/us/developer/docs/api_cti/api_cti.pdf) provides a way to set the Softphone Height setSoftphoneHeight() but this api call sets the softphone height for every softphone object. I would like a way to set the height of a specific tab/window. As far as I can tell there is no support or way to accomplish this.

Use Case:
I want to allow users to have multiple calls up in different states in different tabs/browsers. As such I would like the height to be different based on their state.
  • April 21, 2014
  • Like
  • 0
I am developing a CTI app. For the standard (non console app) it is located in the sidebar. When the user elects to crate a new object (Lead, Contact, Case, Opportunity, Account) I scren pop the new object page.

i.e. sforce.interaction.screenPop(path, true);  where path is one of (/500/e, /006/e, /003/e, /001/e, /00Q/e)

I want to know if there is a way to get a callback once the object has been creatd? I want to get an updated with the object id once they have hit save. How can this be done without polling the database for new objects of that type?

More Info:
I am using the Streaming API but the screen refresh on 'Save' prevents me from receving the message. It does work will in the Console where the screen is not refreshed once the new object is saved.

My Issue:
  1) User elects to create a new object from my sidebar app and clicks create
  2) User is take to the new object page
  3) User fills in the required information and hits save
  4) Screen is reloaded and the object is saved. (Note: My Sidebar app is also reloaded and I have to resubscribe to the streaming api channels)
  Issue) Because the screen is refreshed the streaming api doesn't get me the information. Becase the datastore takes a long time to index I can't find the data with a search.


How can I get the id of newly created records? I have thought of a two work arounds but I am not a fan of either.
1) Poll the database after the user this create.
2) Create the object in my APEX, prefil the required fields, save the object and take the user to that page.

Is there a better way?



  • April 17, 2014
  • Like
  • 1
I am trying to find out if there is a way to have "Search" include objects  which are related to the results which are found. For example If a Contact has a phone number x and there is a Opportunity which has that contact in the contact role collection I would like it included in the search when I search x.

Specifically I am using the SearchAndGetScreenPopUrl() of the open cti api as found in the doc (http://www.salesforce.com/us/developer/docs/api_cti/api_cti.pdf).

I am currently solving this with a custom APEX class to do the search with the contacts/accounts I find with the default search "SearchAndGetScreenPopUrl()". This works but I have to do a second search once the first has completed.

I could also solve this issue with a custom object formula which hold the field I need to search for. If I did this I wouldn't need my APEX class.

What is the best approach? Is there a better one?
  • April 07, 2014
  • Like
  • 0

I have noticed that the Id, ContactId, AccountId provided to me via the streaming api is differnt when I create/update to when the object is dleted. There are 3 additional characters at the end when I create/update. What are these characters? What do they do? And why are they also not present when I delete the object? 

When I create the object I get a message like this:
Message received from: /topic/CaseNotifications
{
  "channel": "/topic/CaseNotifications",
  "clientId": "19mycqd2dq10elvg0r0r0jhlcci",
  "data": {
    "event": {
      "type": "created",
      "createdDate": "2014-04-04T13:19:40.000+0000"
    },
    "sobject": {
      "Status": "New",
      "AccountId": "001i000000M4Iu5AAF",
      "Subject": "yrdy",
      "ContactId": "003i000000IP4VTAA1",
      "Id": "500i0000007RQ4KAAW",
      "CaseNumber": "00001048",
      "Priority": "Medium"
    }
  }
}


When I delete I get the following message:
Message received from: /topic/CaseNotifications
{
  "channel": "/topic/CaseNotifications",
  "clientId": "19mycqd2dq10elvg0r0r0jhlcci",
  "data": {
    "event": {
      "type": "deleted",
      "createdDate": "2014-04-04T13:19:47.000+0000"
    },
    "sobject": {
      "Id": "500i0000007RQ4K"
    }
  }
}

Note in the above the id: 500i0000007RQ4KAAW when I create the object and an id of 500i0000007RQ4K when I delete the object. Why are these different?
  • April 04, 2014
  • Like
  • 0
I am developing a CTI app. For the standard (non console app) it is located in the sidebar. When the user elects to crate a new object (Lead, Contact, Case, Opportunity, Account) I scren pop the new object page.

i.e. sforce.interaction.screenPop(path, true);  where path is one of (/500/e, /006/e, /003/e, /001/e, /00Q/e)

I want to know if there is a way to get a callback once the object has been creatd? I want to get an updated with the object id once they have hit save. How can this be done without polling the database for new objects of that type?

More Info:
I am using the Streaming API but the screen refresh on 'Save' prevents me from receving the message. It does work will in the Console where the screen is not refreshed once the new object is saved.

My Issue:
  1) User elects to create a new object from my sidebar app and clicks create
  2) User is take to the new object page
  3) User fills in the required information and hits save
  4) Screen is reloaded and the object is saved. (Note: My Sidebar app is also reloaded and I have to resubscribe to the streaming api channels)
  Issue) Because the screen is refreshed the streaming api doesn't get me the information. Becase the datastore takes a long time to index I can't find the data with a search.


How can I get the id of newly created records? I have thought of a two work arounds but I am not a fan of either.
1) Poll the database after the user this create.
2) Create the object in my APEX, prefil the required fields, save the object and take the user to that page.

Is there a better way?



  • April 17, 2014
  • Like
  • 1
When I execute searchAndGetScreenPopUrl I only get 25 results per type of object. Additional matches are not returned. When you do a non api search, aka a search form the search bar results are provided in pages of 25. I am looking at the pdf (http://www.salesforce.com/us/developer/docs/api_cti/api_cti.pdf) and I don't see any mention of a limit or a way to page the results.  Also, there isn't anything in the response that would indicate additional results can be found. Am I missing something? Is there a way to get all results?
  • May 29, 2014
  • Like
  • 0
Maybe I am missing something here but is it possible to include a softphone layout in the managed package? I don't see a way form the Add to Package screen.
  • April 28, 2014
  • Like
  • 0
I am having trouble getting my Visualforce page to make an AJAX request in IE 10, 11.  Everything works fine in Chrome, and Firefox but in IE 10, 11 I get status 0 when I make a request.  I can't figure out what I am missing. Is there a bug/limitation somewhere that I am unaware of?

Here is the code (http://jsfiddle.net/LmfsY/2/) on jsfiddle showing it works outside of Visualforce.

Here is a  Visualforce page that demonstrates the issue.

<apex:page>
 
  <div class="document">
    <a class="ajax" href="#">Fire an AJAX request</a>
  </div>
 
  <script src="https://code.jquery.com/jquery-latest.min.js"
        type="text/javascript"></script>
  <script>
   $.support.cors = true;
    $(function() {

        $('.document').on('click', '.ajax', function(e) {
            e.preventDefault();
   
            // ajax request
            $.ajax({
                type: 'get',
                url: 'https://cors-test.appspot.com/test',
                dataType: 'html',
                beforeSend: function() {
                    console.log('Fired prior to the request');
                },
                success: function(data) {
                    console.log('Fired when the request is successful');
                    $('.document').append(data);
                },
                error: function (xhr) {
                    console.log('Fired when the request is NOT successful');
                    $('.document').append(JSON.stringify(xhr));
                },
                complete: function(xhr) {
                    console.log('Fired when the request is complete');
                }
            });
   
        });
   
    });
  </script>
 
</apex:page>

In IE the provided visual force page results in {"readyState":0,"status":0,"statusText":"Access is denied.\r\n"}
In Chrome/Firefox the provided visual force page results in {"status":"ok"}
  • April 23, 2014
  • Like
  • 0

I have noticed that the Id, ContactId, AccountId provided to me via the streaming api is differnt when I create/update to when the object is dleted. There are 3 additional characters at the end when I create/update. What are these characters? What do they do? And why are they also not present when I delete the object? 

When I create the object I get a message like this:
Message received from: /topic/CaseNotifications
{
  "channel": "/topic/CaseNotifications",
  "clientId": "19mycqd2dq10elvg0r0r0jhlcci",
  "data": {
    "event": {
      "type": "created",
      "createdDate": "2014-04-04T13:19:40.000+0000"
    },
    "sobject": {
      "Status": "New",
      "AccountId": "001i000000M4Iu5AAF",
      "Subject": "yrdy",
      "ContactId": "003i000000IP4VTAA1",
      "Id": "500i0000007RQ4KAAW",
      "CaseNumber": "00001048",
      "Priority": "Medium"
    }
  }
}


When I delete I get the following message:
Message received from: /topic/CaseNotifications
{
  "channel": "/topic/CaseNotifications",
  "clientId": "19mycqd2dq10elvg0r0r0jhlcci",
  "data": {
    "event": {
      "type": "deleted",
      "createdDate": "2014-04-04T13:19:47.000+0000"
    },
    "sobject": {
      "Id": "500i0000007RQ4K"
    }
  }
}

Note in the above the id: 500i0000007RQ4KAAW when I create the object and an id of 500i0000007RQ4K when I delete the object. Why are these different?
  • April 04, 2014
  • Like
  • 0