Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8344129
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T06:16:06+00:00 2026-06-09T06:16:06+00:00

I have a repeat where the value loops through documents in the current database,

  • 0

I have a repeat where the value loops through documents in the current database, these documents contain a database and view name. The repeat then opens the database and view and retrieves data from within them:

var dbOther:NotesDatabase = session.getDatabase(null, doc.getItemValueString("Database"));
if(dbOther != null){
    var lookupView:NotesView = dbOther.getView(doc.getItemValueString("ViewName"));
    var viewNav:NotesViewNavigator = lookupView.createViewNavFromCategory(key);
}       

This works fine on all browsers but if I view the xpage in the Notes Client I get the following error: Exception occurred calling method NotesDatabase.getView(string) null

I have tested that the dbOther variable is set by writing the Server and FilePath properties to a log. I checked that it could see the views by generating a loop using getViews and getAliases, again all view aliases were written to the log without an issue.

I have manually entered the view name in case the value was not being selected from the document correctly but received the same error.

Is there a way I can connect to a view in another database in XPiNC? I have found an XSnippet which allows you to dynamically add view data sources to your page, I think this may get around my problem but wanted to find out if there was an alternative solution before I re-write everything!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T06:16:07+00:00Added an answer on June 9, 2026 at 6:16 am

    Try some of these other ways of getting a handle on a database:

    This one uses "" instead of the null parameter to indicate current server:

    var dbOther:NotesDatabase = session.getDatabase("", doc.getItemValueString("Database"))
    

    This one uses database.getServer() instead of the null parameter:

    var dbOther:NotesDatabase = session.getDatabase(database.getServer(), doc.getItemValueString("Database"))
    

    This one uses sessionAsSigner to get access to the database (instead of using the credentials of the current user):

    var dbOther:NotesDatabase = sessionAsSigner.getDatabase(database.getServer(), doc.getItemValueString("Database"))
    

    Are you using a Lotus Notes 8.5.3 client?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Imagine that i have the following code: <a:repeat value=#{bean.getList()} var=x > <li class=la> <span>
I have created a repeat control that list some documents. I would like to
I have a small repeater which loops through up to about 10 items in
I have a timer that loops through following code every second. this code reads
I wrote the following loop since I have to repeat the same/similar code 25
I have a simple 'repeat with' in an AppleScript, and would like to move
I have a ListBox and I need to repeat the styles to be the
i have used following code to repeat a process creation/close iteratively dim vProcessInfo as
I have an EditBox control in a repeat control. Its iteration formula is: return
I have a client report (rdlc) and want to repeat some textboxes in every

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.