customizing "No Documents Found" in an embedded view

I have an embedded view which is restricted to a single category.  if there is no document in a selected category, it displays "No Documents Found".  Is it possible to change the "No Documents Found" text?

thankyou
LVL 14
cezarFAsked:
Who is Participating?
 
Jean Marie GeeraertsConnect With a Mentor Application EngineerCommented:
Okay here's the solution that works for both java applet and html-view:

I suppose you have a form on which you select the category of documents to display, or the category is somewhere in a hidden field to determin what category is to be displayed.
Let's call this field "Category".

Then here's what you do:
Before or after your embedded view applet type the error message you want to appear on a seperate line.
For example:

Sorry, no documents match this category.
[Embedded View]

Now set the hide-when options for the paragraph with the error message as follows:
Select the option Hide paragraph if formula is true and type the following formula:
!@IsError(@DbLookup("":"NoCache"; @DbName; "Name of your view"; Category; 1))
This will hide the error message if there are documents for the selected/entered category available. The @DbLookup will lookup matching documents and return an error if no documents were found.

The paragraph with the view applet has a similar hide-when formula except here you check for the opposite, so without the Not sign:
@IsError(@DbLookup("":"NoCache"; @DbName; "Name of your view"; Category; 1))
This way the embedded view will be hidden if no documents for the selected/entered category were found.
0
 
zvonkoCommented:
Hello,

place before your embeded view this text:
[<div id=view>]

and after the view this text:
[</div>]
[<div id=msg>]
Hier your customized message
[</div>]

Into JSHeader place this:
function CheckRows(){
 var rowCount = document.all.tags('tr')
 if (rowCount.length==0) {
  document.all.msg.style.visibility='visible'
  document.all.view.style.visibility='hidden'
 } else {
  document.all.msg.style.visibility='hidden'
  document.all.view.style.visibility='visible'
 }
}

and call the functiom on onLoad of the form:
CheckRows()

That all works only if you display the view as html. Applet will not work.

Regards,
zvonko

0
 
ArunkumarCommented:
Why work for a 50 Zvo ?
0
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

 
zvonkoCommented:
OK, give it to Arun :)

0
 
Jean Marie GeeraertsApplication EngineerCommented:
Because this was very easy :-)
0
 
zvonkoCommented:
JM again with its easy :(

OK mister easy, give me the code for view applet!

0
 
ArunkumarCommented:
No Zvo!

I thought you would beg for a 300 !!!

LOL !
0
 
zvonkoCommented:
I do not beg, I offer 300 points to Mr. Easy for the view applet solution :)

0
 
Jean Marie GeeraertsApplication EngineerCommented:
You're on. I'm testing something right now ;-)
0
 
zvonkoCommented:
Hey Bro! did you see? I am direct behind you :)

JM, no problem. I had simply to react to your "it's easy" :)

And to cezarF: applet solution costs 500. Ask you for it?

<|;-)
0
 
Jean Marie GeeraertsApplication EngineerCommented:
So, zvo, now you post a 'for Jerrith' question for 300 points?
0
 
zvonkoCommented:
with pleasure :)

0
 
Jean Marie GeeraertsApplication EngineerCommented:
I just got you an extra 5 in Arun's question, too :)
0
 
cezarFAuthor Commented:
sorry guys, i dunno whom to award the points.  prior to reading your comments I was able to do it(similar to jerith's comments). but, i also want to give some points to zvonko.  i'm going to increase the points to 100.  is it possible to split the points to zvo and jerith?
0
 
Jean Marie GeeraertsApplication EngineerCommented:
Yes, all you need to do is post a zero point question in the Community Support forum with a link to this question. (Just copy/paste the URL from your address bar of the browser)
Specify to community support how you want the question handled and they will take care of it for you.

Regards and thanks in advance,
JM
0
 
cezarFAuthor Commented:
tnx, jerith. would that be ok with you, zvo?  :)
0
 
ArunkumarCommented:
okay all the points for Arunkumar....
0
 
zvonkoCommented:
It is your question cezarF,

I am not a fan of empty questions only to get points, so give it completely to JM because his description here is that what you used at the end.

Cheers,
zvonko

PS: hi Bro :)

0
 
Jean Marie GeeraertsApplication EngineerCommented:
You're too generous, zvonko :-)
Hello, buddy. No points for you here, sorry :^)
0
 
cezarFAuthor Commented:
i've already posted a zero point ? in the community support to split the point to zvo and jerith.  tnx to all  
0
 
Computer101Commented:
Points reduced for a split.  You can now accept one experts comment as an answer.  After that, make another question in this topic area for the other expert.  Make the question for the amount of points intended.  Label the question, "Question for (Expert Name) and post this question number in the base of the question, i.e. For your assistance in question # --------


Computer101
E-E Moderator
0
 
Jean Marie GeeraertsApplication EngineerCommented:
So why only a B??
What was wrong with the answer?
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.