yes, sure:
SQL = "Update tblmaster set [notes]=[notes] & ',' & Now() & ', ' & '" &
forms!Telephone!Email & "' where ID=" & forms!Telephone!ID
where Email - is a textbox on the same form
--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com
Hello:
I already have the docmd.runsql placed after the DoCmd.SendObject.
This
is
what I did to have the "notes" field automatically to update. I added
me.notes.setfocus at the end ... which worked!
Is there an easy way to add the person's email address to in the SQL
statement below?
SQL = "Update tblmaster set [notes]=[notes] & ',' & Now() where ID=" &
forms!Telephone!ID
docmd.runsql SQL
:
Hi
I think you need to add docmd.runsql just after DoCmd.SendObject
--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com
Thank you so much for your help! It works ...
I have one last question on the SQL portion.... I hope....
What do I have to do to have the notes field automatically update
the
"notes" field on the form after an email is sent? What I'm doing
right
now
is I click inside the "notes" field on the form to finish the SQL
process.
I am using a command button on this process.
Thank you,
:
Hi,
if primary key of tblmaster is ID then it will be:
SQL = "Update tblmaster set [notes]=[notes] & ',' & Now() where
ID=" &
forms!Telephone!ID
docmd.runsql SQL
--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com
Thank you for your help! I got the first part done. I'm having
problems
with the SQL part. Here is what I wrote. The name of my table
is
called
Master and the name of my form is called Telephone. After the
email
is
sent,
I want to update the notes field on the form. Here is what I
tried.
I'm
not
clear what goes in the question marks. I just want the notes
field
in
the
form to include that an email was sent.
Thank you!
Dim SQL As String
SQL = Update tblmaster set [notes]=[notes] & ',' & Now() where
???
:
1. I want to copy/paste a value in my current form on the
subject
liine
of
my email. The name of the textbox in my form is called
Number.
Am
I
supposed to include that information after the line entry
.....
"Ref:
", _
... which alread shows up in my email?
so in your sendobject metod instead if "Ref:" write "Ref:" &
forms!MyForm!Number
MyForm - should be a name of your form, if you run this from
class
behind
form - you can use Me!Number
2. In my current form, I have a textbox called Notes. How do
I
add
a
one-line entry to include date/time email was sent?
run a query with following SQL:
Update mytable set [Notes]=[Notes] & ', ' & Now() Where Number=
forms!MyForm!Number
--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com
:
1. just add a reference to your textbox:
"Ref: " & forms!MyForm!textfromform
2. You can run update query to set date/time in appropriate
table
after
docmd.sendobject
--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com
Yes, here is what I have so far (see below). I would like
to
do
two
things.
First: I would like to copy text data from the textbox
field
in
my
form
to
"Ref: textfromform".
Second: I would like to have MS Access automatically pass
additional
information on my form annotating that an email was sent to
a
recipient
with
date and time email sent.
DoCmd.SendObject _
, _
, _
, _
" ", _
, _
, _
"Ref: ", _
" ", _
True
:
Hi,
have you tried docmd.SendObject ?
--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com
I created a telephone log in MS Access and would like to
know
if
there
is a
way I can copy my notes from a form in Access and past
it
to
my
email
message
automatically? Also, is there a way to have an entry
added
in
my
notes
to
indicate that an email was sent?
Thank you for your help,