July 23, 2024

Challenge:

While upgrading our solution to Sitecore 7.2, we encountered an issue when we reached Sitecore 7.1 Initial Release

The issue was such that our Content editor stopped opening and we started getting the following error in the browser window —  Object reference not set to an instance of an object.

Drilling Down to the issue:

We thought it could be something in our config file, and the first and foremost thing we did was putting our web.config file aside and replacing it with Sitecore web.config file of a plain Sitecore 7.1 Initial Release instance.

And Bingo! It worked, Content Editor was up! 🙂

 

So the next step was to find what could be conflicting, or which config in our web.config file was the cause of this issue.

On checking, we found almost 150+ changes in our web.config as compared to Sitecore 7.1 Initial Release (Our first thought: Oh God, please Save us! 🙁  )

But then, we worked a little smartly. — We checked for various config values that had changes related to content editor only — approx 50+ in number — manageable!

We went on changing our updated value to the default value of Sitecore web.config, and on each change, getting the Sitecore instance up, to check if Content Editor was up and running.

And that’s when we found the following config which was leading us to the issue:

<!–  CONTENT EDITOR SHOW SEARCH PANEL
Indicates whether the Content Editor show the search panel above the treeview as default
Default value: true
–>
      <setting name=”ContentEditor.ShowSearchPanel” value=”true”/>

We had the value of this as false, as we did not require a Search Panel in the Content Editor.

We verified the check — On making it true, the CE was up and running and making it false, the issue resurfaced.

On confirmation, we contacted Sitecore Support, with a complete analysis, as we all know, they are the best guys who can help us in such cases!

Solution:

Yaroslav Krinitskiy from Sitecore Support, replied our support ticket, registered this issue as a Bug and provided us with a workaround for it.

The workaround, is as follows:

  1. Open the ‘\sitecore\shell\Applications\Content Manager\Default.aspx’ file.
  2. Find the following line          <div id=”SearchPanel” style=”background: #e9e9e9; border-bottom: 1px solid #4c4c4c”>
    (it must be the ~116th line)
  3. Replace it with
               <table><tr id=”SearchPanel” style=”background: #e9e9e9; border-bottom: 1px solid #4c4c4c” runat=”server”><td>
  4. Don’t forget to replace its closing tag           </div>          <div class=”scFlexContentWithoutFlexie scFlexColumnContainerWithoutFlexie” id=”SearchResultHolder” style=”display: none”>with
               </td></tr></table>
    <div class=”scFlexContentWithoutFlexie scFlexColumnContainerWithoutFlexie” id=”SearchResultHolder” style=”display: none”>

We checked it in our solution, keeping the config entry specified above as false and it worked well.

Also, on smoke testing, we could not find any other issue after applying this workaround.

 

So again, Thanks Sitecore Support, and specially Yaroslav Krinitskiy for getting us to the solution of this issue!

Happy Sitecoring and Happy Upgrading! 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *