• RAJJ SHEKARR
  • NEWBIE
  • 0 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 1
    Replies
Hi Team, 
I'm trying to dispalying an image on Document from VF page using Document object which is working fine. 
But after migrating to Lightning I was forced to use either Files / Static Resrouce to store and access the images.
When I use any of them(Files [stored in Assert Library] / Static Resource[Made public]) to render the image on Docuemnt, it is not getting displayed on Doc.

Could you suggest which option I need to use in order to display image on Ms Doc (not using Documents Obj).

Any help in this regard will really helpful and appritiated.

Here is my sample code
==================
Main VF Page
****************
<apex:page standardController="Opportunity"  contentType="application/msword#DocName}-{!TODAY()}.doc"
           extensions="DocGeneratorController" showHeader="false" sidebar="false" standardStylesheets="false" applyHtmlTag="false" applyBodyTag="false" cache="true">
<apex:include pageName="Header" id="Head_id"/>
</apex:page>


Header.vfp
************
<apex:page standardController="Opportunity" >
<!--
Version 1 (using Documents Obj): Working for Doc & PDF 
<img src="{! $Label.Sandbox_URL}/servlet/servlet.ImageServer?id={! $Label.Logo_DocId }&oid={! $Label.Organization_ID}"  height="55"  width="220" /> 
-->

<!-- 
Version 2 (using Static Resource): Working for PDF only not for Doc
<apex:image id="theImage" value="{!$Resource.logo}" height="42px" /> 
-->
                    
<!--
Version 3 (using Files [ContentVersion & ContentDocument objs]):
working only for PDF not for Doc
<img src="{!' /sfc/servlet.shepherd/version/download/' + v.contentVersion.Id}" />
-->
</apex:page>

ThankU Friends in advance.

Thanks
Arami

Hi All,

Is there any way to hide a tab from all the profiles at a time.

Thanks in advance.

  • February 10, 2011
  • Like
  • 0