• telnext
  • NEWBIE
  • 0 Points
  • Member since 2010

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 3
    Replies

Dear All,  I have two Custom Object. Say those as Parent__c and Child__c. Obviously Child__c has a lookup relation to Parent__c object (I am considering here custom object, but my question is general and it is valid also on standard objec like Account and Contact).  I would like that from a VisualForce page  a user can create a Parent__c record an many related Child__c object (the latters like a table where I can add/remove rows). When I click on the custom button Insert then the Parent__c and Child_c objects are saved ion the SalesForce DB. I am able to reproduce this using my Custom Extension. I set on the visualforce page as standardController = "Parent__c" and as extensions="MyExtension".  However, to achieve this what I have done is also to manage on the extension a separate List<Child__c> and so, when I add/remove a row from the table in the visualforce page I add/remve an element from that list. Then when I click on Insert Button I call a method in the extension that before save the Parent__c object, then set the id of the Parent__c object just created in all the Child__c element of the list and finally insert also the list.  I would like to know if there is a way to do not use a my List<Child__c> in the extension, but directly use the Parent__c.Child__r list to add/remove Child_c objects (rows). In this way then can I use the standard save method of the Parent__c standard controller to save the Parent__c object and all the related Child__c element that are in the Parent__c.Child__r list (like a CASCADE in all child)? I have tried to achieve this, but when I try to add/remove element from the Parent__c.Child__r list it is like the element are not added to the list (the list is always empy).  BR

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?