Solved

How to emulate a dblookup

Posted on 2004-09-02
2
331 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 13

Accepted Solution

by:
CRAK earned 500 total points
ID: 11968202
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
ID: 11968358
I was playing around with by key however I was using the wrong indicator

Not the the view name

Duuuhh
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IBM Notes offer Encryption feature using which the user can secure its NSF emails or entire database easily. In this section we will discuss about the process to Encrypt Incoming and Outgoing Mails in depth.
Sometimes clients can lose connectivity with the Lotus Notes Domino Server, but there's not always an obvious answer as to why it happens.   Read this article to follow one of the first experiences I had with Lotus Notes on a client's machine, my…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

688 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