• ales.p
  • NEWBIE
  • 0 Points
  • Member since 2006

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 6
    Questions
  • 7
    Replies

I'm trying to build an Apex Class that:

1 - upsert some records

2 - create an attachment

3 - send an email with that attachment

 

All works well but only one thing is wrong and I'm not able to understand how to solve.

Each line of CSV file MUST contain as required CHR(13) and CHR(10) characters and I insert '\r\n' to obtain that.

 

But when I check the end of each CSV line, the file contains a double:

CHR(10) CHR(10)

...instead of

CHR(13) CHR(10)

...as expected.

 

It seems that '\r' OR '\n' has been converted both to CHR(10). :smileysad:

 

Any help?

Thanks in advance...

 

  • August 30, 2010
  • Like
  • 0

Hello, 

This is simply a business requirement and I think there are a lot of other Salesforce clients that has that.

 

Business Case:

·         I have a Customer

·         It is managed and owned by a Partner user (PRM)

·         I would like to enable Customer Portal for that Customer

 

I cannot do it but we think is unreal because that case often happens.

 

This limitation was not reported before Spring 09 implementation manual.

 

 

Any help about that?

Any well known workaround? 

 

Thanks in advance to all.

 

Alessandro 

 

 

 

 

  • March 09, 2009
  • Like
  • 0
Is there a way to invoke Apex Class Web Service from workflow message action (SOAP)?

We built a simple APEX class and we would like to call that class from workflow message action passing URL Endpoint and Sessiond ID.
We receive this error from the message queue: "INVALID_SESSION_ID: Invalid Session ID found in SessionHeader: Illegal Session"

Apex class is very simple for testing purpose:

global class HelloWorld2 {
 WebService static void sayHelloWorld(String arg)
{
Lead lead;
lead = new Lead();
lead.firstname = 'Name name';
lead.lastname = 'Surname';

insert lead;
}

}

Endpoint for workflow message action setup is:
https://na4-api.salesforce.com/services/Soap/class/HelloWorld2

Any help about that?

For testing purposes I'm trying to use an apex:repeat tag. It seems that a rerender action from a command button do NOT apply the rendering of this tag. While the same action work successfully with a dataList o a dataTable.
 
Here is my simple apex repeat tag from page editor:
<apex:pageBlock title="Contacts search result">
<apex:repeat id="searchResultsRepeat" value="{!resultContacts}" var="cContact">
{!cContact.Name} - {!cContact.Phone}<br/>
</apex:repeat>
</apex:pageBlock>

And here is the simple controller rerender function:
public Contact[] getResultContacts() {
    return [SELECT Id, Name, Account.Name, Phone FROM Contact WHERE Name = :searchKey ORDER BY Name]; 
}

I used this one also:
public List<Contact> getResultContacts() {
  return [SELECT Id, Name, Account.Name, Phone FROM Contact WHERE Name = :searchKey ORDER BY Name]; 
}

Is there something wrong?
I believe that all syntax is OK but it seems to be an issue.

Thanks

P.S.: there are no error messages, simply the repeat tag section is not re-rendered.



Message Edited by Ales.p on 01-15-2008 10:48 AM
  • January 15, 2008
  • Like
  • 0
I would like to implement a simple contact search with VisualForce and I didn't find syntax documentation about query LIKE operator.
Actually I created 3 objects: 1 simple "inputText", 1 "commandButton" and 1 "dataTable" for search contacts results.
 
Users should insert a search key in the inputText field, press the commandButton and obtain a list (dataTable) of contacts that matches the search key.
Actually it works fine with a "=" operator but I would like to extend this search with a LIKE operator.
 
  String searchKey = 'Josh Davis';
  public List<Contact> getMyContacts() {
    return [SELECT Id, Name, Account.Name, Phone FROM Contact
            WHERE Name = :searchKey
            ORDER BY Name];
  }
How to do that?
Thanks a lot.
  • January 14, 2008
  • Like
  • 0
Hello developers,
I'm developing an AppExchange application that use Documentation TAB and I uploaded some GIF images that I need.  When images has been uploaded, Salesforce (Sf) assign them an ID automatically. In order to refer to those images I have to use a link like that:
... with the given ID.
 
The problem is that I have to refer to those images inside Reports, S-Controls and Custom Formula Fields but the given link change every time I install or load my application for my Customers because ID change.
 
So, is there a way to refer to images with the image "Document Name" given while upload???
I'm looking to something like that or similar:
 
Help!!!
Thanks in advance.
 
Alessandro
:smileysad:

Message Edited by Ales.p on 10-12-2006 02:38 AM

  • October 12, 2006
  • Like
  • 0

I'm trying to build an Apex Class that:

1 - upsert some records

2 - create an attachment

3 - send an email with that attachment

 

All works well but only one thing is wrong and I'm not able to understand how to solve.

Each line of CSV file MUST contain as required CHR(13) and CHR(10) characters and I insert '\r\n' to obtain that.

 

But when I check the end of each CSV line, the file contains a double:

CHR(10) CHR(10)

...instead of

CHR(13) CHR(10)

...as expected.

 

It seems that '\r' OR '\n' has been converted both to CHR(10). :smileysad:

 

Any help?

Thanks in advance...

 

  • August 30, 2010
  • Like
  • 0
Is there a way to invoke Apex Class Web Service from workflow message action (SOAP)?

We built a simple APEX class and we would like to call that class from workflow message action passing URL Endpoint and Sessiond ID.
We receive this error from the message queue: "INVALID_SESSION_ID: Invalid Session ID found in SessionHeader: Illegal Session"

Apex class is very simple for testing purpose:

global class HelloWorld2 {
 WebService static void sayHelloWorld(String arg)
{
Lead lead;
lead = new Lead();
lead.firstname = 'Name name';
lead.lastname = 'Surname';

insert lead;
}

}

Endpoint for workflow message action setup is:
https://na4-api.salesforce.com/services/Soap/class/HelloWorld2

Any help about that?

Does anyone know if there is an API for the Offline edition? I have a desktop based app, which needs access to information on salesforce, but it will not always have an internet connection. I need to integrate my custom app with the Offline edition of Salesforce.
 
Thanks,
 
 
  • March 11, 2008
  • Like
  • 0
Hi All,

I would like to implement a paging sceam in datatable. from the VF developer guid I can see that we can only limit the number of records using the "ROW" attribute of the datatable but how can I display the next page or the previous page of data..

Thanks in anticipation of your humble response.

Thanks and regards
pallav
  • January 14, 2008
  • Like
  • 0
Hello developers,
I'm developing an AppExchange application that use Documentation TAB and I uploaded some GIF images that I need.  When images has been uploaded, Salesforce (Sf) assign them an ID automatically. In order to refer to those images I have to use a link like that:
... with the given ID.
 
The problem is that I have to refer to those images inside Reports, S-Controls and Custom Formula Fields but the given link change every time I install or load my application for my Customers because ID change.
 
So, is there a way to refer to images with the image "Document Name" given while upload???
I'm looking to something like that or similar:
 
Help!!!
Thanks in advance.
 
Alessandro
:smileysad:

Message Edited by Ales.p on 10-12-2006 02:38 AM

  • October 12, 2006
  • Like
  • 0
The help files tell me that there is a 1 million character limit on s-Controls.  They then vaguely mention the ability to reference outside files:
 
If you are uploading a file as part of the custom s-control, insert the {!Scontrol_URL} merge field to reference the file.
 
With the creation of the AJAX toolkit, I would imagine that more people are going to want to upload a file they've been working on their desktop and then creating an s-Control which references it for convenience / maintenance purposes if not becuase of the size limit.
 
Can anyone shed some more light on this ability?
 

Message Edited by michaelforce on 08-13-2006 08:51 AM