Embedded Views

Since an embeded view only displays a single view, is it possible to create a view that lists all other views in the current database.  What I am trying to do is create a form which will display all the views in the current data base, then use that form as the src for a frame in a three framed homepage.
Chris_mAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

phooeyCommented:
You could:

Create a  field on the form that is populated, using script, with the list of the views.

Don't write out the views as just text, but write them out as links, using the target property to open them in a different frame.

i.e.
"<A HREF=" + server/database/view + "?openview TARGET=/_top/>" + ViewName + "</A>"
0
phooeyCommented:
This is the kind of script you will need to use.  Just look under NotesDatabase (views property) in the help db.

Dim session As New NotesSession
Dim db As NotesDatabase
Dim textString as String
Set db = session.CurrentDatabase
Forall v In db.Views
  TextString = TextString + v.Name
End Forall


(Note, this won't actually work, but is a good starting place!)
0
pentapodCommented:
I don't suppose you're using R5?  It's easy using R5...

....Pentapod
0
Cloud Class® Course: Microsoft Office 2010

This course will introduce you to the interfaces and features of Microsoft Office 2010 Word, Excel, PowerPoint, Outlook, and Access. You will learn about the features that are shared between all products in the Office suite, as well as the new features that are product specific.

HemanthaKumarCommented:
Hi Chris

What is the Notes Ver u r using ?

Do you wan't to show the list of views in the database on the Web or Notes ?

~Hemanth
0
Chris_mAuthor Commented:
I am using 4.6 ver 3b.  What I want to do is to use the document that has the list of views dynamically created as the source of a frame in a frameset homepage.  This so that the left frame of the homepage can display an expanded list of all the views in another database.  I can do this by physically creating links to the views, but that is not a good solution.  Far better to have them rerad and displayed automatically.

The db.Views solution proposed by phooey seems to be the right way to go, but I am not sure how to get them into the form so that they will be read when the homepage is called up.
Regards and thanks to all who are helping me.
0
phooeyCommented:
How familiar are you with script and agents?

Basically, you can pretty much use the script I gave above, but in an agent.

This agent is then called from the WebQueryOpen event on the form, an has the effect of populating a field with the views that exist.  You could actually use a javascrip document.write in your agent, but perhaps this is a bit far!

One other possible way, especailly if the views rarely change:

Create the agent to populate a field on a keyword form.
Use a standard @DBColumn on your web form to get the contents of this keyword.
You can then run the agent on schedule, or as neccessary and keep the view list as up to date as required.

This would have the added advantage of reducing overall server load.
0
HemanthaKumarCommented:
Hi Chris

You can use domino field to accomplish these, create a text field with name $$ViewList(Editable/Computed) in a form, which will list all the views in the current database when opened  on the browser. Use this form handle in the frameset.

Good Luck
~Hemanth
0
phooeyCommented:
Muck Fe, he's right you know !, so perhaps you could open the form from the lookup database and display this in your main databases frameset.
0
Chris_mAuthor Commented:
Hello HemanthaKumar!  Your solution displays the views perfectly, however, there is a small problem.  When I click on a view, the list of documents displays, but, when I select a document, I get a 404 Error .... File does not exist.  In fact, the file does exist, I can open the files if I access the database thru' a link.  What can the problem be?
0
HemanthaKumarCommented:
Hi Chris

I need to know what is the url link that is being displayed when u keep ur mouse pointer on the document link. Could u post the sample here.

OR

try to view the source of the document error & copy that and paste it here.

~Hemanth
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Lotus IBM

From novice to tech pro — start learning today.