• Deyan Chugunov 7
  • NEWBIE
  • 0 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 0
    Replies
Hello guys,

I need help finding a solution of an issue I got. So, I have overriden the Account`s Edit and New actions with my custom Visualforce page. This page is build dynamically, based on the used Layout. I collect all the layout fields and pass them to to the Standard Controller`s addFields() method. So far so good. When I open a given Account for Edit, everything works like a charm and the Account is edited and saved, but when I want to create a new one, I get an error message saying: No such column 'BillingGeocodeAccuracy ' on entity 'Account'.
The interesting thing is that the Account is actually created inspite the error message, which is shown only in Lightning Experience. I have debugged my code and checked the fields which I pass to the addFields() method - BillingGeocodeAccuracy is NOT one of them, but somehow is included in the SOQL query. I have found a work around which is to use insert instead of Standard Sontroller`s save() methodbut this does not seems right to me. This approach brings other issues like validation ruls not triggering for example. I would much appreciate any help on that. Thanks!
Hi all,

I`m struggling to fix an issue which arise with the new Salesforce Lightning Experience. So, I have a Visualforce page which is assigned to the Edit functionality of Accounts. In Salesforce Classic mode everything works perfectly good, but when I switch to the new Lightning Experience I get a strange behavior on redirect - the lightning is removed and I get redirected to the classic mode page. I hope to clarify things with the below screenshots.

First, I edit one of my accounts to go to my Visualforce page.
User-added image

First, I edit one of my accounts to go to my Visualforce page.
User-added image

First, I edit one of my accounts to go to my Visualforce page.User-added image

I'm using PageReference object in my Apex controller for navigation, but from what I've red it is not working with the Lightning.
For example:
 
    PageReference pg = null;
    try{
        pg = stdController.save();  
    }catch(Exception ex){           
        Logger.Instance.LogException(ex, false);
    }

    return pg;
If anyone can give me directions, I would be very grateful!