• Br1
  • NEWBIE
  • 100 Points
  • Member since 2008

  • Chatter
    Feed
  • 4
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 16
    Questions
  • 40
    Replies

Hi,

 

   I am developing a web application through visualforce. I have added a static resource javascript file which 

requires an image file to be called. I have put the images into /img folder and the javascript file(yyyyy.js) into /js folder and zipped folders into (XXXXXXX.zip) and added as a static resource with the name XXXXXXXZip

and added the code in my page as

 

 <script type="text/javascript" src="{!URLFOR($Resource.XXXXXXXZip, 'yyyyy.js')}"/>

 

But still i am not able to display the images.

 

Regards,

Ravindra

Dear All,
Please help me out, I am interested to handle Save event on Opportunity Object., Once the user will fill Opportunity at this level
i needed to tranfer records to my Local DataBase using WebService.
I can develop s-Control, and this Control will call Apex Class WebService , and this WEbService will send data to my Local machine , please suggest some relevant code to send data from salesforce. I already used OutBound meaage. But i am interested to call method on save Button.
 
 
Regards:
Amul
 
  • November 01, 2008
  • Like
  • 0

Hi,

 

I want to link a Contact with a custom object record when a form is submitted from my site.

 

The apex code to perform this operation is the same since 3 months ago and was working perfectly...


three weeks ago the entire list of contacts can't be seen from the site , only the ones created by the guest (site) user.

 

There's any change in the sharing settings that i must do to see the entire list of contacts again from my site?

 

 

Thanks,
Bruno.

  • July 09, 2010
  • Like
  • 0

Hi,

 

I get this exception : System.Exception: sObject type 'NAMESPACE__ObjectName__c' is not supported.

 

In a Managed Package running on a EE Org.

 

help ? 

 

brx

 

  • November 24, 2009
  • Like
  • 0

Hi,

 

I've created a StandardSetController extension and a Visualforce page with a pageblocktable that displays a list of records from a custom object.

 

At the Visualforce page I do some ajax calls to delete a record from this object, then I do a rerender of the pageblocktable to display the list *without* the recently deleted record, but it stills at the list.

 

As I can see, what is happening is that the Set of records are not loaded again when I do the rerender.

How I can reload the set of records? Is possible?

  • October 01, 2009
  • Like
  • 0

I want to send an email to the related contact of a case when the case is modified or created.

 

I've done a  workflow to send a email alert to the related contact, and a email template in plain text.

 

I create a case from the cases tab, but nothing happens, the email are not sent to the related contact.

 

The workflow rule is active , i've checked all the possible mistakes...

 

Any idea of what can be happening ?

  • August 19, 2009
  • Like
  • 0

I'am developing an application that does a lot of ajax requests in the background to update and show data, for some reason, the third post request is blocked always.

 

Is that a limitation of Force.com Sites? where i can found information ? it depends of the license of my org? 

 

Thx

Br1

  • August 12, 2009
  • Like
  • 0

Hello, i have a DE org and i want to enable Customer Portal self registration / login, i have followed all the wiki steps but i cannot register at the provided url.

Any clue ?

 

thanks.

Bruno

  • July 03, 2009
  • Like
  • 0

I have enabled some pages at "enable visualforce page access" from the public access settings, but i get "page not found" errors every time i try to load one.

The pages are part of a managed package, the site are active.

 

Thanks in advance

Brx

 

  • May 25, 2009
  • Like
  • 0

I'm doing a managed package that works with sites, at my app i expose some apex classes, pages , and set some permissions to my custom objects to make it public and accessible to the site.

 

How all this information can be packaged? where i can find info about that ?

 

I have seen at the summer'09 features a intro but the info are not sufficient.

 

thanks.

brx.

 

 

  • May 22, 2009
  • Like
  • 0

Hi,

When i try to create a user with a form and the metod Site.createPortalUser , this error shows up:

This form must be secure. Use the "forceSSL" attribute and set it to "true"


This method have been worked (without changes) at this page until May 6 , after this date the form throws the error shown above.

 

I have the forceSSL="true" at the apex:form tag already.

 

Any clue?

 

thanks

brx

Message Edited by Br1 on 05-19-2009 06:39 PM
  • May 19, 2009
  • Like
  • 0

I need the site url (the url given by the method Site.getCurrentSiteUrl()) , but not in the context of the site, just at an internal page.

 

I know that is the expected behavior (at the bottom of the sites help page are a note that says "You must also use them within the context of your public site; otherwise, a null value is returned.") but i need this url inside the crm.. any workaround?

 

thx

 

brx

  • May 19, 2009
  • Like
  • 0

I have a site with 2 pages (one of the pages are a form) and for some reason, when i try to load the pages, the site randomly shows a "page not found".

Is a dev org and i have signed up thru the preview page to enable sites at it.

 

thanks in advance

brx

  • May 13, 2009
  • Like
  • 0
Anyone knows how i get the fields that i have added to display at one approval Page Layout?
The fields are the number one at this image:

i want to display this form in my custom app but i can't get these fields.

  • December 15, 2008
  • Like
  • 0
I don't know it is possible , but here we goes:

I want to build a form to edit a Standard Object, into a custom visualforce page.

To do that , i get the description of every field (with the getDescribe() and things like this), and i put it on a list.

The apex code:

Code:
The class:

 public class AccountEditableField {
  public String label { get; set;}
  public Schema.SObjectField value { get; set; }
 }

The Parser:

 public void accountDescribe(){
 
  Set <String> fieldKeys = new Set<String>();
   
  fieldKeys = AccountFieldsDescribe.keySet();
 
  List <String> editableFieldKeys =  new List<String>();
 
  String queryFields = '';
 
  for(String elem:fieldKeys){
   // Get the fields
   Schema.DescribeFieldResult field = (AccountFieldsDescribe.get(elem)).getDescribe();
    
   //Schema.DescribeFieldResult f = Schema.sObjectType.Account.fields.elem;
   if(field.isAccessible() && field.isUpdateable()){
    editableFieldKeys.add(elem);
    queryFields += field.getSObjectField()+', ';    
   }
       
   System.Debug(' ** \n'+AccountFieldsDescribe.get(elem)+'\n ** \n The field is visible (accesible)—:'+field.isAccessible()+' \n **  \n The field is Updateable–:'+field.isUpdateable());   
  }
   
  queryFields = queryFields.substring(0,queryFields.length() - 2);
    
 
  for(String f:editableFieldKeys){
   
   AccountEditableField fieldEditable = new AccountEditableField();
   Schema.DescribeFieldResult fieldDescribed = (AccountFieldsDescribe.get(f)).getDescribe();
   
   fieldEditable.label = fieldDescribed.getLabel();
   fieldEditable.value = fieldDescribed.getSObjectField();
   
   listOfFields.add(fieldEditable);
 
  }
 
 }

 



And try to generate the form at at the visualforce page:

Code:
 <apex:form id="accountEdition">
   <apex:repeat value="{!listOfFields}" var="field">
    <apex:outputText value="{!field.label}" />
    <apex:inputField value="{!field.value}" />
   </apex:repeat>
 </apex:form> 

 When i try to save the page, the error are:

Save error: Could not resolve the entity from <apex:inputField> value binding '{!field.value}'.  inputField can only be used with SObject fields

I know that the code at the apex controller can be simplified but i keep it in that way to make it easy to understand.

Anybody knows a workaround for that problem ?
Another way to build a dynamic form ?


Thanks in advance ;)


Message Edited by Br1 on 11-05-2008 12:15 PM
  • November 05, 2008
  • Like
  • 0
How i can get the layouts metadata from the apex controller ?

The metadata API has a method describeLayout() or getDescribeLayout() but i cannot make it works at the controller.

If that is not possible , how i can connect to the metadata api from the apex controller?

Thanks
Br1
  • October 15, 2008
  • Like
  • 0
I am enabling a contact to be a Customer Portal User , i fill al the form fields, and when i press save this error shows up:

Mixed DML Exception

DML operation on setup object is not permitted after you have updated a non-setup object: Generic Exception Creator

Someone knows why it happens?

thanks in advance.
Br1
  • October 13, 2008
  • Like
  • 0
Today the HTML outputs from the controller to the visualforce page doesnt work anymore, and MUST be placed as apex:outputText  tags with escape="false" attribute.

Anyone knows workarounds , solutions to common problems that may produce?

Or where we can find that important bug fixes announcements ?

Sorry about my english is not my native language.




  • February 28, 2008
  • Like
  • 0

Hi,

 

I want to link a Contact with a custom object record when a form is submitted from my site.

 

The apex code to perform this operation is the same since 3 months ago and was working perfectly...


three weeks ago the entire list of contacts can't be seen from the site , only the ones created by the guest (site) user.

 

There's any change in the sharing settings that i must do to see the entire list of contacts again from my site?

 

 

Thanks,
Bruno.

  • July 09, 2010
  • Like
  • 0

Hi,

 

I get this exception : System.Exception: sObject type 'NAMESPACE__ObjectName__c' is not supported.

 

In a Managed Package running on a EE Org.

 

help ? 

 

brx

 

  • November 24, 2009
  • Like
  • 0

Hi,

 

I've created a StandardSetController extension and a Visualforce page with a pageblocktable that displays a list of records from a custom object.

 

At the Visualforce page I do some ajax calls to delete a record from this object, then I do a rerender of the pageblocktable to display the list *without* the recently deleted record, but it stills at the list.

 

As I can see, what is happening is that the Set of records are not loaded again when I do the rerender.

How I can reload the set of records? Is possible?

  • October 01, 2009
  • Like
  • 0

I'am developing an application that does a lot of ajax requests in the background to update and show data, for some reason, the third post request is blocked always.

 

Is that a limitation of Force.com Sites? where i can found information ? it depends of the license of my org? 

 

Thx

Br1

  • August 12, 2009
  • Like
  • 0

I have enabled some pages at "enable visualforce page access" from the public access settings, but i get "page not found" errors every time i try to load one.

The pages are part of a managed package, the site are active.

 

Thanks in advance

Brx

 

  • May 25, 2009
  • Like
  • 0

I'm doing a managed package that works with sites, at my app i expose some apex classes, pages , and set some permissions to my custom objects to make it public and accessible to the site.

 

How all this information can be packaged? where i can find info about that ?

 

I have seen at the summer'09 features a intro but the info are not sufficient.

 

thanks.

brx.

 

 

  • May 22, 2009
  • Like
  • 0

Hi,

When i try to create a user with a form and the metod Site.createPortalUser , this error shows up:

This form must be secure. Use the "forceSSL" attribute and set it to "true"


This method have been worked (without changes) at this page until May 6 , after this date the form throws the error shown above.

 

I have the forceSSL="true" at the apex:form tag already.

 

Any clue?

 

thanks

brx

Message Edited by Br1 on 05-19-2009 06:39 PM
  • May 19, 2009
  • Like
  • 0

I need the site url (the url given by the method Site.getCurrentSiteUrl()) , but not in the context of the site, just at an internal page.

 

I know that is the expected behavior (at the bottom of the sites help page are a note that says "You must also use them within the context of your public site; otherwise, a null value is returned.") but i need this url inside the crm.. any workaround?

 

thx

 

brx

  • May 19, 2009
  • Like
  • 0

I have a site with 2 pages (one of the pages are a form) and for some reason, when i try to load the pages, the site randomly shows a "page not found".

Is a dev org and i have signed up thru the preview page to enable sites at it.

 

thanks in advance

brx

  • May 13, 2009
  • Like
  • 0

Hi All,

 

Can any help me How to update a Field in paritcular Table(object), i tried to update a Lead record, but i coud't set the id value.

 

ex,

 

Lead leadOldObject = ref for exsiting; //existing lead object ....

 

Lead l = new Lead();

l.LastName =  l.LastName +'Its me';

l.id = new ID(leadOldObject.id); // if i commited this line getting error as no id was assigned for update objects

update l;

 

<end> 

 

l.id = new ID(leadOldObject.id);

if i commited the above line getting error as no id was assigned for update throw 

 

not commented means i compiler error on this line..

 

Thnx in advance! 

Hi,

 

   I am developing a web application through visualforce. I have added a static resource javascript file which 

requires an image file to be called. I have put the images into /img folder and the javascript file(yyyyy.js) into /js folder and zipped folders into (XXXXXXX.zip) and added as a static resource with the name XXXXXXXZip

and added the code in my page as

 

 <script type="text/javascript" src="{!URLFOR($Resource.XXXXXXXZip, 'yyyyy.js')}"/>

 

But still i am not able to display the images.

 

Regards,

Ravindra

I don't know it is possible , but here we goes:

I want to build a form to edit a Standard Object, into a custom visualforce page.

To do that , i get the description of every field (with the getDescribe() and things like this), and i put it on a list.

The apex code:

Code:
The class:

 public class AccountEditableField {
  public String label { get; set;}
  public Schema.SObjectField value { get; set; }
 }

The Parser:

 public void accountDescribe(){
 
  Set <String> fieldKeys = new Set<String>();
   
  fieldKeys = AccountFieldsDescribe.keySet();
 
  List <String> editableFieldKeys =  new List<String>();
 
  String queryFields = '';
 
  for(String elem:fieldKeys){
   // Get the fields
   Schema.DescribeFieldResult field = (AccountFieldsDescribe.get(elem)).getDescribe();
    
   //Schema.DescribeFieldResult f = Schema.sObjectType.Account.fields.elem;
   if(field.isAccessible() && field.isUpdateable()){
    editableFieldKeys.add(elem);
    queryFields += field.getSObjectField()+', ';    
   }
       
   System.Debug(' ** \n'+AccountFieldsDescribe.get(elem)+'\n ** \n The field is visible (accesible)—:'+field.isAccessible()+' \n **  \n The field is Updateable–:'+field.isUpdateable());   
  }
   
  queryFields = queryFields.substring(0,queryFields.length() - 2);
    
 
  for(String f:editableFieldKeys){
   
   AccountEditableField fieldEditable = new AccountEditableField();
   Schema.DescribeFieldResult fieldDescribed = (AccountFieldsDescribe.get(f)).getDescribe();
   
   fieldEditable.label = fieldDescribed.getLabel();
   fieldEditable.value = fieldDescribed.getSObjectField();
   
   listOfFields.add(fieldEditable);
 
  }
 
 }

 



And try to generate the form at at the visualforce page:

Code:
 <apex:form id="accountEdition">
   <apex:repeat value="{!listOfFields}" var="field">
    <apex:outputText value="{!field.label}" />
    <apex:inputField value="{!field.value}" />
   </apex:repeat>
 </apex:form> 

 When i try to save the page, the error are:

Save error: Could not resolve the entity from <apex:inputField> value binding '{!field.value}'.  inputField can only be used with SObject fields

I know that the code at the apex controller can be simplified but i keep it in that way to make it easy to understand.

Anybody knows a workaround for that problem ?
Another way to build a dynamic form ?


Thanks in advance ;)


Message Edited by Br1 on 11-05-2008 12:15 PM
  • November 05, 2008
  • Like
  • 0