• Bulent703
  • NEWBIE
  • 5 Points
  • Member since 2010

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

Hi,

 

I started experimenting with the new Summer 13 communities and saw that if I use the Flex toolkit I get the "API Access Disabled for Communites" error. Is there a way to enable API access?

 

Thanks!

Hi,

 

I have a Visualforce page called "TestPage1". In the controller I use Page.TestPage1.getUrl() to get the URL for this page. This works fine in regular Salesforce.com platform. However, when I use this in the new communities, it does not put the community name in the URL. So, instead of the following syntax:

 

https://abccommunities-developer-edition.na15.force.com/customers/apex/TestPage1

 

I get

 

https://abccommunities-developer-edition.na15.force.com/apex/TestPage1

 

Is this a bug in the new communities? Is there a way to get this to work?

 

Thanks!

We have a managed package that is distributed on AppExchange and some of our customers had Spring 13 preview orgs with these packages installed. Once the upgrade occured, accessing any VF pages that refer to the managed app shows an error indicating that there are some unresolved compilation errors in the managed package classes.

 

So, the code didn't change, it is just the Spring 13 preview upgrade. Is this a bug? Why would it start showing compilation issues. In addition, even some of the classes and line numbers don't really correspond to lines of code but for example an openning bracket in an if statement.

 

Thanks!

Hi,

 

We have been using the flex toolkit for sometime and suddenly this week, our app stopped working. The error we get is:

 

Error: Ignoring policy file at https://na6.salesforce.com/crossdomain.xml due to meta-policy 'by-content-type'.

 

The contents of the https://na6.salesforce.com/crossdomain.xml file is as follows:

 

<cross-domain-policy>

<site-control permitted-cross-domain-policies="by-content-type"/>

</cross-domain-policy>

 

The content-type header of this file indicates that the file is text/xml. Now the by-content-type permitted domain policy indicates that the file is supposed to be sent out with the content-type header text/x-cross-domain-policy. So any access to this file is not even permitted. How can this work? 

 

Is anyone else having issues with flex apps on salesforce.com? Am I missing something here?

 

Update: Realized that the flex toolkit example will also not run if the swf file is hosted on a server other than Salesforce.com. The issue is that the flash would like to understand if salesforce.com is giving it the right to talk to the site and salesforce is somewhat responding back in a confusing way that prevents the remote site to access salesforce.com. This practically breaks all flex toolkit based meshups hosted on other sites.

 

Further Update: After further tests, it turned out that the $API.Partner_Server_URL_180 in visualforce page returned the following URL:

 

https://namespace.na1.visual.force.com/services/Soap/u/18.0/00D30000000YoRU

 

this made the flash plugin look for a crossdomain under this domain and get a 302 redirect. When this happens flash seem to lose the context and not able to use the crossdomain file loaded from https://na1.salesforce.com/crossdomain.xml. So, if I pass the URL as:

 

https://na1.salesforce.com/services/Soap/u/18.0/00D30000000YoRU

 

This works! This might be due to the Winter 12 update.

 

Thanks!

Bulent

 

Hi,

 

I'm trying to run a Java application that bulk deletes records from Salesforce. However, I get the following error:

 

[UnexpectedErrorFault [ApiFault  exceptionCode='EXCEEDED_ID_LIMIT' exceptionMessage='delete id limit reached: 200']]

 

Here is my code (simplified):

 

public static DeleteResult[] deleteFiles(PartnerConnection conn, String[] idsToDelete) throws Exception

{

try

{

return conn.delete(idsToDelete);

}

catch(ConnectionException e)

{

logger.debug("Exception occured: " + e.getLocalizedMessage(), e);

throw new Exception("Exception occured: " + e.getLocalizedMessage(), e);

}

}

 

where I pass 9000 IDs into the array. Which limit am I hitting and how can I change this limit?

 

Thanks!

Hi,

I'm trying to create a custom detail view for a custom object and implement inline edits. However, the page is not only used to edit the custom object (Test_Parent__c) but also its related objects (Test_Child__c). Here is the controller:

 

 

public class TestController
{

    public Test_Parent__c rep {get; set;}
    public List<Test_Child__c> recs {get; set;} 
    
    public TestController() {
        String id = ApexPages.currentPage().getParameters().get('id');

        rep = [select id, Test_Text__c from Test_Parent__c where Id = :id][0];
        recs = [select id, Hours__c from Test_Child__c where Test_Parent__r.Id = :rep.Id];
    }

    public PageReference save() {
        update rep;
        update recs;
        return null;
    }

}

 and here is the visualforce for this page:

 

 

<apex:page controller="TestController" > 
<apex:form >
<apex:commandButton action="{!save}" id="saveButton" value="Save"/>
<apex:inlineEditSupport>
  <table border="1" bordercolor="black">
      <tr>
          <td>Parent Name:</td><td><apex:outputField value="{!rep.Test_Text__c}" ><apex:inlineEditSupport />
          </apex:outputField></td>
      </tr>
  </table>
<apex:repeat value="{!recs}" var="rec">
    Child Hours: <apex:outputField value="{!rec.Hours__c}"><apex:inlineEditSupport />
          </apex:outputField>
</apex:repeat>
</apex:inlineEditSupport>
</apex:form>
</apex:page>

Now, when I use the inline edit feature, the parent rep objects gets update and the child does not get updated. I played around with placing the inlineEditSupport tag inside the form and also inside the individual outputField records. I wasn't able to get this to work consistently to update both records at the same time. I would sometimes see that the child related record will get updated and most times it would not. 

 

Any suggestions or ideas?

 

 

Hi,

 

I have a requirement where I need to append text at the end of an email message. However, the email message is based on the template. If I try to get the email template body and send it as part of the email, the merge fields are not processed. Is there a good way to do this? 

Hi,

 

I started experimenting with the new Summer 13 communities and saw that if I use the Flex toolkit I get the "API Access Disabled for Communites" error. Is there a way to enable API access?

 

Thanks!

Background information:

 

We have managed package that is using the Api.Partner_Server_URL_210 to get the serverURL that can be used by the external system to call back into the Salesforce using Soap API.

 

This managed package is embedded within Opportunity page. We have enabled Partner portal through site.

 

Site is using the custom domain as "mycompany.secure.force.com"

 

Custom domain is not enabled for the org.

 

Working Scenario :

When the PRM portal user is logged from the Salesforce's contact page using "Login to Partner Portal",  user gets to the standard Partner portal page and navigates to the Opportunity page and clicks to view the managed packages's custom VF page. In this scenario VF get https://managepackagenamespace.na1.salesforce.com/XXXXXX/" as API.Partner_server_URL. Using this URL external system is able to connect back to Salesforce via Soap API and get the data.

 

Non-working Scenarion:



When the PRM portal user is logged from external facing site URL https://mycompany.secure.force.com/sitelogin page and then navigates to the Opportunity page and clicks to view the managed packages's custom VF page. In this scenario VF get https://mycompany.secure.force.com/XXXXXX/" as API.Partner_server_URL. Using this URL external system is NOT able to connect back to Salesforce via Soap API and get the data.

 

So question is does $API..Partner_server_URL suppose to return https://managepackagenamespace.na1.salesforce.com/XXXXXX/" value or Salesforce platform does not allow API calls to https://mycompany.secure.force.com/ URL.

 

Any help would be appreciated.

 

Thank you.

Hi,

I have two wrappers, one for SObject objects, one for field types. Based on the field type I need to retrieve the Sobject field value inside VisualForce page.

 

For example:

 <apex:repeat value="{!fieldsWrapper}" var="field" id="customFieldRepeater">
        <apex:column headerValue="{!field.label}" value="{!f.mySobject.get(field.id).value}"/>
        </apex:repeat>

 But this is giving Syntax error. Extra '.' error.

 

Is there a way to do this in VF page, or do i miss something?

 

Thanks,

John

Hi,

I'm trying to create a custom detail view for a custom object and implement inline edits. However, the page is not only used to edit the custom object (Test_Parent__c) but also its related objects (Test_Child__c). Here is the controller:

 

 

public class TestController
{

    public Test_Parent__c rep {get; set;}
    public List<Test_Child__c> recs {get; set;} 
    
    public TestController() {
        String id = ApexPages.currentPage().getParameters().get('id');

        rep = [select id, Test_Text__c from Test_Parent__c where Id = :id][0];
        recs = [select id, Hours__c from Test_Child__c where Test_Parent__r.Id = :rep.Id];
    }

    public PageReference save() {
        update rep;
        update recs;
        return null;
    }

}

 and here is the visualforce for this page:

 

 

<apex:page controller="TestController" > 
<apex:form >
<apex:commandButton action="{!save}" id="saveButton" value="Save"/>
<apex:inlineEditSupport>
  <table border="1" bordercolor="black">
      <tr>
          <td>Parent Name:</td><td><apex:outputField value="{!rep.Test_Text__c}" ><apex:inlineEditSupport />
          </apex:outputField></td>
      </tr>
  </table>
<apex:repeat value="{!recs}" var="rec">
    Child Hours: <apex:outputField value="{!rec.Hours__c}"><apex:inlineEditSupport />
          </apex:outputField>
</apex:repeat>
</apex:inlineEditSupport>
</apex:form>
</apex:page>

Now, when I use the inline edit feature, the parent rep objects gets update and the child does not get updated. I played around with placing the inlineEditSupport tag inside the form and also inside the individual outputField records. I wasn't able to get this to work consistently to update both records at the same time. I would sometimes see that the child related record will get updated and most times it would not. 

 

Any suggestions or ideas?

 

 

Hi

 

My visualforce page was working fine on IE8 with ajax being used. But on IE9 it gives an error

 

 

SCRIPT16386: No such interface supported
 
3_3_3.Finalorg.ajax4jsf.javascript.AjaxScript, line 122 character 41

 

SCRIPT16386: No such interface supported 3_3_3.Finalorg.ajax4jsf.javascript.AjaxScript, line 122 character 41

 

Any idea how it can be solved? 

  • March 21, 2011
  • Like
  • 0

We have a VF page that is used to override the View for the Account object. When we setup the Console view and open the details of an account, the page is displayed properly. However, when we click on a related object in the account detail (such as Account Cases), then the right side does not show up. Firebug shows the following javascript error:

 

 

Permission denied for <https://namespace.na7.visual.force.com>

to get property Window.srcFromMain from <https://na7.salesforce.com>.
[Break on this error] if (window.parent && window.parent.srcFromMain) {

 

 

This javascript function is in desktopMain.js:

function srcUp(url) {
if (window.parent && window.parent.srcFromMain) {
window.parent.srcFromMain(url);
 } else {
 srcSelf(url);
 }

 

 

 

It seems that the VF page is in a different domain then the frame set and this is causing a security issue with the javascript. Is there a workaround or solution for this issue?

 

Hi

 

If i do not select any color the value of colr is null. when Submit button is clicked for the code below just the outputText value should be displayed.

 

But a new window is openening and the same test1 page is appearing with the outPuttext in the new Window.

 

 If the color value is null or empty then the new window should not be opened. How can we restrict this?

 

Please advise.Thanks

 

 

<apex:page controller="test1">
<apex:form >
<apex:pageBlock>
<apex:outputText value="please select color" rendered="{!err}"/>
<apex:outputLabel value="Select color" />
<apex:selectRadio value="{!colr}">
<apex:selectOptions value="{!items}"/>
</apex:selectRadio>
<apex:CommandLink action="{!myaction}" target="_blank">Submit</apex:CommandLink>
</apex:PageBlock> </form> </page> public class test1 { public String colr{get;set;} Public Boolean err=false; public Boolean geterr(){ return err;} public List<SelectOption> getItems() { List<SelectOption> options = new List<SelectOption>(); options.add(new SelectOption('Red','Red')); options.add(new SelectOption('Blue','Blue')); return options; } public PageReference myaction() { if(colr == null || colr == '') { err=true; return null; } else { PageReference pr = new PageReference('/apex/test2'); return pr; } } }

 

 

 

Hi All,

 

 

In our requirement we are emailing attachments using apex.  

 

I found that email attachment size is limited to 3mb, from the following link,

http://www.salesforce.com/us/developer/docs/api/Content/sforce_api_objects_attachment.htm

. Kindly confirm this.

 

 

Are anyone of you able to send attachment more than 3 mb size? If so please post your suggestions.

 

Thanks in advance

 

 

Cheers,

Vishnu 

  

Hello,

We're developing an application on Force.com platform that will require a number of document attachments for various objects. We will be needing storage space and capabilities in addition to the default storage that comes with Force.com license. Appreciate any suggestions regarding third party data storage providers that has worked for other Force.com applications.

Thanks
  • July 10, 2008
  • Like
  • 0