Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Subject in Dlookup not pulling two values,  need alternative

Posted on 2014-02-06
7
Medium Priority
?
351 Views
Last Modified: 2014-02-19
I tried adding two values for the Dlookup but was told it is not possible.   In my database I need to pull the body text and a subject and put it into a default email.  See the sample.
1.accdb
0
Comment
Question by:lehi52
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 39839815
< In my database I need to pull the body text and a subject and put it into a default email>

you need two dlookup() , one for Subject and one for Body Text

where in your db are you doing this?
0
 
LVL 10

Accepted Solution

by:
Gozreh earned 2000 total points
ID: 39839829
You should dim a separate verbal for each dlookup.
i showed you this in your previous question.



From all you questions it seems that you should go learn the basic of how to write and use VBA coding.
0
 

Author Comment

by:lehi52
ID: 39839900
You are correct.  I need to learn VBA.  But I really appreciate your help though.  Its really helped me get this up and running.  If I can get this email thing that you've been helping me with working it will be a huge help.  I tried the subject line code and it did not work.   Maybe I am doing something wrong.
0
Veeam Task Manager for Hyper-V

Task Manager for Hyper-V provides critical information that allows you to monitor Hyper-V performance by displaying real-time views of CPU and memory at the individual VM-level, so you can quickly identify which VMs are using host resources.

 
LVL 58
ID: 39839942
and BTW it's not impossible to get Dlookup to return more then one value.

ie.

= Dlookup("[Address] & ';' & [City]","tblCustomers","[CustomerID] = 1")
 
Then do a split on the semi-colon.

Jim.
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 39839963
yes, if the values you are looking for comes from the same record
0
 

Author Closing Comment

by:lehi52
ID: 39839974
He was right it was answered in my previous post.
0
 
LVL 10

Expert Comment

by:Gozreh
ID: 39839985
he needs one dlookup for subject and one for the body to be entered the the email, so he will need 2 separate dlookup's.
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

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

Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
Windows Explorer let you handle zip folders nearly as any other folder: Copy, move, change, and delete, etc. In VBA you can also handle normal files and folders, but zip folders takes a little more - and that you'll find here.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

885 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