By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,456 Members | 1,400 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,456 IT Pros & Developers. It's quick & easy.

Strings Using Concatenated Fields

P: n/a
I am trying to prevent employees from referencing their own loans.

Here's the VBA Code:

Dim strApplicant As String
strApplicant = "dbo_snapshot_loan_app.applcnt_first_nm & "" &
dbo_snapshot_loan_app.applcnt_last_nm"

If (strApplicant = CurrentUser()) Then
MsgBox "You cannot view your own loan.", vbCancel
End If

Not working -- what am I doing wrong?

Thanks!

amy
===

May 24 '06 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Why not just send it as a RTF file. Use the Access send object command
and do something like this

DoCmd.SendObject acSendreport, "eportname", acFormatrtf, _
"email addresses", , , "subject name", , False

May 24 '06 #2

P: n/a
am*******@verizon.net wrote in
news:11**********************@38g2000cwa.googlegro ups.com:
I am trying to prevent employees from referencing their own
loans.

Here's the VBA Code:

Dim strApplicant As String
strApplicant = "dbo_snapshot_loan_app.applcnt_first_nm & "" &
dbo_snapshot_loan_app.applcnt_last_nm"
'adding these two lines will tell you, just open the immediate
window {Ctrl-G}:and compare the two values.
Debug.Print strApplicant
debug.Print CurrentUser()
If (strApplicant = CurrentUser()) Then
MsgBox "You cannot view your own loan.", vbCancel
End If

Not working -- what am I doing wrong?

Thanks!

amy
===


--
Bob Quintal

PA is y I've altered my email address.
May 24 '06 #3

P: n/a
I probably didn't explain myself too well here.

What I am getting returned from a query is a LIST of records, which may
or may not contain an employee's loan. How do I insure that the ONE
RECORD that might match the Employee's Name is Not Visible?

Thanks!

Amy
===

May 25 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.