• Naresh
  • NEWBIE
  • 0 Points
  • Member since 2007

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 18
    Questions
  • 17
    Replies
Hi All,
I am using HttpRequest and HttpResponse method to make an external call in Apex. But in HttpResponse I am not getting the proper result. I am getting the "Status=Object Moved" and "StatusCode=302". I understand this is because of "response.redirect" on the requested page. For this, I again get theURL for the redirected page and made a new request by setting the new EndPoint. But this time I am getting the "Session time out error".
This is because  both request has different session. Any idea how we can made multiple request with same session?


Thanks,
NG
  • October 09, 2008
  • Like
  • 0
Hi,
I am apex:inputField visual force component on a Visual force page by using the StandardController and want to set the Tab Order (that should be vertically) for all the fields. I am not finding any attributes for the apex:inputField to set the Tab Order.

I tried to use the "tabindex" but did not work. The "tabindex" works for the apex:inputText but not for the apex:inputField.

Any idea?

Thanks in advance..........

Thanks,
NG
  • August 19, 2008
  • Like
  • 0
Hi,
Does Visual force supports Field Dependencies?

Thanks,
NG
  • August 09, 2008
  • Like
  • 0
Hi All,
Can we use Visual force pages to develop the SFDC Reports? Much appreciable if anyone can provide any document on VF and Report.

Thanks in advance..

Thanks,
NG
  • August 03, 2008
  • Like
  • 0
Hi,
I am calling a external web service in a Visual force Controller and getting the following error:
Parser was expecting element 'http://schemas.xmlsoap.org/soap/envelope/:Envelope' but found ':html'

Any idea?

Thanks in advance,
NG
Hi ,

I am trying to call an external web service from Visual force. I have taken a WSDL file.This Web service validate any Address on SFDC
Account . I parsed the WSDL to the apex class and  trying to call the request method in the Converted class from visual force. But when i tried to call it i am getting an error:-"Web service callout failed: Unable to parse callout response. Apex type not found for element http://www.serviceobjects.com/=Desc".

Any idea?

Thanks in Advance!

NG
Hi,
Is there a way I can display all fields of an object in edit mode (input fields) just like an <apex:detail /> tag displays all fields in the detail mode?



Thanks in advance!

Thanks,
NG
Hi,
My Requirement:
                                When a user create/edit the Contact object the email address (Email field on Contact) should be verified through a external web service. If the email address is  not valid user do not allow to create/edit the Contact.

Implemented Solution 1:
                                   
I have created a trigger on the Contact Object that calls an Apex class. That class then calls another Web Service. But it gives the error like this: "Callout from triggers are currently not supported". So could not able to achieve the solution.

Implemented Solution 2:
                                  After getting the error by using Trigger i tried to call the Web service through Visual force page. I have to call the web service when user create/edit the Contact. And I need to display the same standard edit (edit mode)page layout of Contact. I am not creating any custom page (UI). I need to call the external web service when user click on the 'Save' button on Contact.

Can anyone help me out? Please let me know if anyone want more clarification on this.

Thanks in Advance,
NG

Hi,
I have created an Apex class on the Sandbox and wanted to deploy the Apex class on the Production org. I am using Eclipse 3.2 for Apex deployment. While deployment i am getting the following error:
"Duplicate packages are installed. Can not make the deployment plan."

After interogation i found that on the Production org there are duplicate Package installed with the same name. These package have some important data and can not be deleted or removed.

Any idea?
Please suggest if there is any other option to deploy the code without delete or removing the duplicate Pakcages.

Note: The code coverage for the Apex class is more than 85% so it can not be the code coverage issue.

Thanks in Advance!
  • April 14, 2008
  • Like
  • 0
Hi ,
is there any way to login from one Salesforce.com org into another Salesforce.com org using Apex. Actually, i have written one Apex class and wanted to login into a different SFDC org from that class.

Please post me if anyone have any solution.

Thanks in advance,
NG
  • February 28, 2008
  • Like
  • 0
We are working on a simple Apex class that does some aggregation based on some picklist values. Functionally and technical all looks and works ok in the Sandbox. We also have created the test method and have appropriate code coverage. But, when we deploy to production, we see weird characters in the code which weren't there in sandbox. Instead of a "-", we are seeing "?". Any ideas why?

Thanks in advance,
NG
  • February 21, 2008
  • Like
  • 0
Hi All,
I want to login into Salesforce in to an external js file by including the connection.js file. But not able to login into Salesforce.com through the login(username,password) method of connection.js file

Kindly post if anyone have the solution

Thanks in advance

Message Edited by Naresh on 11-12-2007 03:56 AM

  • November 12, 2007
  • Like
  • 0
Hi,
I want to create a Google Gadget for Salesforce.com. Still I am very
new to Google Gadgets. Kindly post me if you have any example(source
code) of Salesforce.com Gadget. That will be helpful for me to create
Google Gadgets. Please post the Gadget that have been developed for
Salesforce.com only.


Thanks in advance,
  • November 08, 2007
  • Like
  • 0
Hi All,

Can anyone have example(source code) of any google gadget developed for salesforce.com?

Kindly reply,

Thanks in advance,
  • November 08, 2007
  • Like
  • 0
Hi,
  i am not able to set any Case fields with the sending mail while using MassEmailMessage(). But this is sucessfully working on SingleEmailMessage().

The following fields i want to populate in an email using any template:

1.   {!EmailMessage.Subject}
2.  {!Case.Solution_Description}
3.  {!Case.CaseNumber}.
4.  {!EmailMessage.FromName}
5   {!EmailMessage.FromAddress}
6   {!EmailMessage.ToAddress}
7   Re: {!EmailMessage.Subject}
8   {!EmailMessage.TextBody}



The code is given below:

function sendMail(templateId)
{
    var massRequest = new sforce.MassEmailMessage();
   
    contactIDArray[0]= contactID;
    massRequest.targetObjectIds = contactIDArray;
    massRequest.replyTo = replyTo;
    massRequest.subject = 'RE:'+ '{!Case.Subject}';
    massRequest.templateId = templateId;
    var sendMailRes =  sforce.connection.sendEmail([massRequest]);
}


can anyone help me to achive this?

thanks in advance.

Message Edited by Naresh on 05-23-2007 12:23 AM

Message Edited by Naresh on 05-23-2007 12:31 AM

Hi,
     can anyone give me the solution defined below:

I created an s-control that execute on any page loading.
There is one button say 'View' on html s-control.
I want to open a file that is located on local machine by clicking the 'View' button in salesforce.

But it gives some Security error.

Can anyone tell how can i resolve this problem?

Thanks in advance
hi,
       can anyone tell how we call a S-Control from Workflow ?
thanks in advance.
hi,
       how can i get the ID of a Related object during a Merge call fail ?. I need to get the ID of a particular Related object  where  the Merge API call fail.

Thanks in advance

Naresh Goyal
  • April 16, 2007
  • Like
  • 0
Hi,
Is there a way I can display all fields of an object in edit mode (input fields) just like an <apex:detail /> tag displays all fields in the detail mode?



Thanks in advance!

Thanks,
NG
Hi,
My Requirement:
                                When a user create/edit the Contact object the email address (Email field on Contact) should be verified through a external web service. If the email address is  not valid user do not allow to create/edit the Contact.

Implemented Solution 1:
                                   
I have created a trigger on the Contact Object that calls an Apex class. That class then calls another Web Service. But it gives the error like this: "Callout from triggers are currently not supported". So could not able to achieve the solution.

Implemented Solution 2:
                                  After getting the error by using Trigger i tried to call the Web service through Visual force page. I have to call the web service when user create/edit the Contact. And I need to display the same standard edit (edit mode)page layout of Contact. I am not creating any custom page (UI). I need to call the external web service when user click on the 'Save' button on Contact.

Can anyone help me out? Please let me know if anyone want more clarification on this.

Thanks in Advance,
NG

Hi,
I have created an Apex class on the Sandbox and wanted to deploy the Apex class on the Production org. I am using Eclipse 3.2 for Apex deployment. While deployment i am getting the following error:
"Duplicate packages are installed. Can not make the deployment plan."

After interogation i found that on the Production org there are duplicate Package installed with the same name. These package have some important data and can not be deleted or removed.

Any idea?
Please suggest if there is any other option to deploy the code without delete or removing the duplicate Pakcages.

Note: The code coverage for the Apex class is more than 85% so it can not be the code coverage issue.

Thanks in Advance!
  • April 14, 2008
  • Like
  • 0
I created an Apex trigger in Sandbox.  I am now trying to deploy the Trigger using the Force.com IDE for Eclipse.  When I get to the step where I "Validate Deployment" it results in a failure.
Deployment Log:
*** Deployment Log ***
Result: FAILED

...

# Deploy Results:
 Name: unpackaged/package.xml
 Action: NO ACTION
 Result: FAILED
 Problem: Invalid version specified:12.0

Does anyone know why this is happening?  Could it be because our Sandbox was already upgraded to the Spring 08 (API version 12.0) release and our production instance wasn't yet (still API version 11.1)?
-greg
  • January 30, 2008
  • Like
  • 0
Hi All,
I want to login into Salesforce in to an external js file by including the connection.js file. But not able to login into Salesforce.com through the login(username,password) method of connection.js file

Kindly post if anyone have the solution

Thanks in advance

Message Edited by Naresh on 11-12-2007 03:56 AM

  • November 12, 2007
  • Like
  • 0
Hi,
I want to create a Google Gadget for Salesforce.com. Still I am very
new to Google Gadgets. Kindly post me if you have any example(source
code) of Salesforce.com Gadget. That will be helpful for me to create
Google Gadgets. Please post the Gadget that have been developed for
Salesforce.com only.


Thanks in advance,
  • November 08, 2007
  • Like
  • 0
Hi,
 
I have 50 mail merge templates with different details. Based on state, it should select particular mail merge template. I want to write a sControl which can select particular mail merge template based on state.
 
How can I do this sControl?
 
Thanks in advance.
 
 
 
 
 
 


Message Edited by Sunil on 03-20-2008 02:46 AM
  • October 10, 2007
  • Like
  • 0

Hi

I'm calling my own SOAP web service and it always fails with:

Web service callout failed: Unable to parse callout response. Apex type not found for element =gah

It's a simple web service, with one operation, getInfo, returning a String.  I've added the WSDL below.
I "generate code from WSDL" (code also attached below) and call this code, which then fails. (The code generated fine).

The error occurs when I subsequently execute the code. ie.

Contactz11.ContactInfoImplPort c = new Contactz11.ContactInfoImplPort();
String r = c.getInfo();

This does actually call the SOAP service (I see that in my server log).  The problem appears to be in Apex's conversion of the resulting String.

Any advice gratefully accepted...

Jon


Here's the generated Apex Code:
//Generated by wsdl2apex

public class Contactz11 {
public class getInfo {
private String[] apex_schema_type_info = new String[]{'http://ws.memestorm.com/','false'};
private String[] field_order_type_info = new String[]{};
}
public class ContactInfoImplPort {
public String endpoint_x = 'http://memestorm.dyndns.org:8080/contactz';
private String[] ns_map_type_info = new String[]{'http://ws.memestorm.com/', 'Contactz11'};
public String getInfo() {
Contactz11.getInfo request_x = new Contactz11.getInfo();
Contactz11.getInfoResponse response_x;
Map<String, Contactz11.getInfoResponse> response_map_x = new Map<String, Contactz11.getInfoResponse>();
response_map_x.put('response_x', response_x);
WebServiceCallout.invoke(
this,
request_x,
response_map_x,
new String[]{endpoint_x,
'',
'http://ws.memestorm.com/',
'getInfo',
'http://ws.memestorm.com/',
'getInfoResponse',
'Contactz11.getInfoResponse'}
);
response_x = response_map_x.get('response_x');
return response_x.gah;
}
}
public class getInfoResponse {
public String gah;
private String[] gah_type_info = new String[]{'gah','http://www.w3.org/2001/XMLSchema','string','0','1','false'};
private String[] apex_schema_type_info = new String[]{'http://ws.memestorm.com/','false'};
private String[] field_order_type_info = new String[]{'gah'};
}
}


Here's the WSDL:

<?xml version="1.0" encoding="utf-8"?><wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:ns1="http://ws.memestorm.com/" xmlns:ns2="http://schemas.xmlsoap.org/soap/http" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="ContactService" targetNamespace="http://ws.memestorm.com/">
  <wsdl:types>
<xsd:schema xmlns="http://ws.memestorm.com/" attributeFormDefault="unqualified" elementFormDefault="unqualified" targetNamespace="http://ws.memestorm.com/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:element name="getInfo" type="getInfo"/>
<xsd:complexType name="getInfo">
<xsd:sequence/>
</xsd:complexType>
<xsd:element name="getInfoResponse" type="getInfoResponse"/>
<xsd:complexType name="getInfoResponse">
<xsd:sequence>
<xsd:element minOccurs="0" name="gah" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
  </wsdl:types>
  <wsdl:message name="getInfo">
    <wsdl:part element="ns1:getInfo" name="parameters">
    </wsdl:part>
  </wsdl:message>
  <wsdl:message name="getInfoResponse">
    <wsdl:part element="ns1:getInfoResponse" name="result">
    </wsdl:part>
  </wsdl:message>
  <wsdl:portType name="ContactInfo">
    <wsdl:operation name="getInfo">
      <wsdl:input message="ns1:getInfo" name="getInfo">
    </wsdl:input>
      <wsdl:output message="ns1:getInfoResponse" name="getInfoResponse">
    </wsdl:output>
    </wsdl:operation>
  </wsdl:portType>
  <wsdl:binding name="ContactServiceSoapBinding" type="ns1:ContactInfo">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="getInfo">
      <soap:operation soapAction="" style="document"/>
      <wsdl:input name="getInfo">
        <soap:body use="literal"/>
      </wsdl:input>
      <wsdl:output name="getInfoResponse">
        <soap:body use="literal"/>
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:service name="ContactService">
    <wsdl:port binding="ns1:ContactServiceSoapBinding" name="ContactInfoImplPort">
      <soap:address location="http://memestorm.dyndns.org:8080/contactz"/>
    </wsdl:port>
  </wsdl:service>
</wsdl:definitions>

Hi,
  i am not able to set any Case fields with the sending mail while using MassEmailMessage(). But this is sucessfully working on SingleEmailMessage().

The following fields i want to populate in an email using any template:

1.   {!EmailMessage.Subject}
2.  {!Case.Solution_Description}
3.  {!Case.CaseNumber}.
4.  {!EmailMessage.FromName}
5   {!EmailMessage.FromAddress}
6   {!EmailMessage.ToAddress}
7   Re: {!EmailMessage.Subject}
8   {!EmailMessage.TextBody}



The code is given below:

function sendMail(templateId)
{
    var massRequest = new sforce.MassEmailMessage();
   
    contactIDArray[0]= contactID;
    massRequest.targetObjectIds = contactIDArray;
    massRequest.replyTo = replyTo;
    massRequest.subject = 'RE:'+ '{!Case.Subject}';
    massRequest.templateId = templateId;
    var sendMailRes =  sforce.connection.sendEmail([massRequest]);
}


can anyone help me to achive this?

thanks in advance.

Message Edited by Naresh on 05-23-2007 12:23 AM

Message Edited by Naresh on 05-23-2007 12:31 AM

Hi,
     can anyone give me the solution defined below:

I created an s-control that execute on any page loading.
There is one button say 'View' on html s-control.
I want to open a file that is located on local machine by clicking the 'View' button in salesforce.

But it gives some Security error.

Can anyone tell how can i resolve this problem?

Thanks in advance
hi,
       can anyone tell how we call a S-Control from Workflow ?
thanks in advance.