function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Hari@RockzsHari@Rockzs 

Content search in Documents

Hi Friends,

 

Scenario:-  Like google search,if u enter any searchkey in textbox,then search will be done in docments,which u have uploaded salesforce,then the documents which contains that searchkey will displays in VF page

 

 

          Can u anybody share u r knowledge with us

 

Hari@RockZ 

Pradeep_NavatarPradeep_Navatar

Tryout this sample code to content search in document :

 

                                                <apex:page showHeader="false" sidebar="false">

                                                <apex:pageBlock >

                                                <b>Enter search term: </b>

                                                <apex:form >

                                                <script>

                                                function doSearch()

                                                {

                                                var searchStr = document.getElementById('txtSearch').value;

                                                window.open('/_ui/common/search/client/ui/UnifiedSearchResults?sen=001&sen=015&str=' + encodeURIComponent(searchStr), "_parent" );

                                                }

                                                </script>

                                                <input/>

                                                <input value="Go!" id="btnSearch"/>

                                                </apex:form>

                                                (<strong>NOTE:</strong> Only searches Accounts and document)

                                                 </apex:pageBlock>

                                                </apex:page>

Hari@RockzsHari@Rockzs

pradeep,

 

  Understand Scenario,

 

                         i have   DOC1 contains  Hari,Charan,Nara

                                       DOC2 contains Hari&Nara

                                       DOC3 Contains charan.

 

Now,  my requirement is if  i entered Charan in text box ,then search will be done and documents which are containing Charan will displayed on VF page.

 

here: result:-         DOC1,DOC3

 

so plaese suggest me how i can achieve that ,how we can access the content of document