Solved

How to emulate a dblookup

Posted on 2004-09-02
2
319 Views
Last Modified: 2013-12-18
HI Guys

I have made a change and am nolonger using UNID for PArent Child relationship

I am using field value(Numbers)

I have a script
Set prdoc = currentdb.GetDocumentByUNID(xxpr_link1) I need to now get the parent doc based on its prnumber
which is in the xxpr_link1

Set podoc = uidoc.Document
      Dim xxoldTotal1 As Double                        ' This PO when it was opened.
      Dim xxpr_link1 As String      ' Link to PR      from this PO.
      Dim prview As notesView
      Set prview = db.getView("VPRNUM")
      uidoc.Refresh
      
      xxoldTotal1 = podoc.oldTotal1(0)            ' Initial value of this PO saved in PostOpen
      xxpr_link1 = podoc.pr_link1(0)
      
      Set prdoc = currentdb.GetDocumentByUNID(xxpr_link1)
      
      
0
Comment
Question by:imjamesw
2 Comments
 
LVL 13

Accepted Solution

by:
CRAK earned 500 total points
Comment Utility
You haven't given us your true question or problem.

Just two lines that provide an indication:
   "I have made a change and am nolonger using UNID for PArent Child relationship"
and
   "Set prdoc = currentdb.GetDocumentByUNID(xxpr_link1)"

If xxpr_link1 does not represent a doc id, we're talking about a lookup by KEY.
Perhaps this one might help you out:

Set prdoc = <ViewInstance>.GetDocumentByKey(xxpr_link1)

Of course you neet to define <ViewInstance> first, like:

myView = currentDb.GetView("<name>").
Make sure to sort by key, just as you would for @DbLookup.
0
 

Author Comment

by:imjamesw
Comment Utility
I was playing around with by key however I was using the wrong indicator

Not the the view name

Duuuhh
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

You’ve got a lotus Domino web server, and you have been told that “leverage browser caching” is a must do. This means that we have to tell the browser everywhere in the web to use cache. In other words, we set (and send) an expiration date in the HT…
I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now