|
-
Apr 19th, 2006, 12:34 PM
#1
Thread Starter
Addicted Member
[RESOLVED] getting the contact address from query in access
hello
i was wondering if anyone could help me with mail
merging outlook from access!!!
thanks in advance
-
Apr 19th, 2006, 01:05 PM
#2
Re: mail merge
Usually a mailmerge will involve Word to some degree.
You need to give more information.
What version of Office?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 19th, 2006, 02:23 PM
#3
Thread Starter
Addicted Member
Re: mail merge
i want to use the query to get the list of emails which i wan to send the emails to!!!
can you help plz!!!
-
Apr 20th, 2006, 02:26 AM
#4
Re: mail merge
You will want to add a reference to Microsoft ActiveX Data Objects 2.x Library in Outlooks VBA IDE. Then its basic ADO code to connect and retrieve the recordset. See tutorial located here - http://www.vbforums.com/showthread.php?t=337051
Then its a matter of creating an email and adding the email addresses to its To property.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 20th, 2006, 11:06 AM
#5
Thread Starter
Addicted Member
getting the contact address from query in access
i want to send the bills qutomatically to the customers
how can i do so ?!
the point is that i need to get the emails of the customers from the query and then somehow use them in outlook to send them ?!
can anyone help?!
-
Apr 20th, 2006, 11:09 AM
#6
Re: getting the contact address from query in access
By "get the emails" do you mean get email addresses that are stored in your database?
-
Apr 20th, 2006, 11:15 AM
#7
Re: getting the contact address from query in access
Are you using VB6 or Outlook VBA?
-
Apr 20th, 2006, 11:45 AM
#8
Re: getting the contact address from query in access
 Originally Posted by RobDog888
My intent was to merge, but I don't know whether the resulting single thread should be in ClassicVb or Office Development.
I guess you can just pick one, and then move if necessary as the member has not responded to the question on what platform he is using.
-
Apr 20th, 2006, 11:48 AM
#9
Re: getting the contact address from query in access
Threads Merged. 
I choose the Office Dev forum as its contains both Access and Outlook.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 20th, 2006, 01:36 PM
#10
Thread Starter
Addicted Member
Re: getting the contact address from query in access
well i don't it should be complicated i just want to emeil the bills which are made in access to the customers automatically after one month !!!
what should i do !!!!!!!!!!!!!!!!!!????????????????????
-
Apr 21st, 2006, 12:11 PM
#11
Frenzied Member
Re: getting the contact address from query in access
 Originally Posted by parisa_ch
well i don't it should be complicated i just want to emeil the bills which are made in access to the customers automatically after one month !!!
what should i do !!!!!!!!!!!!!!!!!!????????????????????
Answer the questions asked above.
Tengo mas preguntas que contestas
-
Apr 21st, 2006, 12:26 PM
#12
Thread Starter
Addicted Member
Re: getting the contact address from query in access
what question?
i'm suppose to get the answer from someone i mean if i knew the answer i would have done it myself.
-
Apr 21st, 2006, 12:36 PM
#13
Frenzied Member
Re: getting the contact address from query in access
See posts 6 & 7 by Hack above. No one can really help until you give more information.
Tengo mas preguntas que contestas
-
Apr 21st, 2006, 01:41 PM
#14
Re: getting the contact address from query in access
We can help you but just giving a generic scnerio doesnt help us to help you. 
Btw, what version of Office and what OS will this be on? Is it for distribution or just on your system?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 21st, 2006, 01:59 PM
#15
Thread Starter
Addicted Member
Re: getting the contact address from query in access
well let me tell you my course work
this system is used on a single worksation in a center which is used to make booking for the village hall
now one of the things this system is sopposed to do is to produce bills for the customers who made the booking and in order to save money oon postage just email it to them instead i want to get the system to email the bills automatically at the end of each month.
can you help me now please.
thank you
-
Apr 21st, 2006, 02:00 PM
#16
Thread Starter
Addicted Member
Re: getting the contact address from query in access
the bookings are save in the database so the emails are saved in the customer table.
-
Apr 21st, 2006, 02:03 PM
#17
Re: getting the contact address from query in access
Ok, but are you using VB6 or the VBA behind Access or Outlook?
Also, which version Office and Operating System?
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 21st, 2006, 04:27 PM
#18
Thread Starter
Addicted Member
Re: getting the contact address from query in access
well i haven't done anything in outlook yet
i have ony started programming i don't know what to do?!!??!!?
-
Apr 21st, 2006, 08:43 PM
#19
Frenzied Member
Re: getting the contact address from query in access
From your comment above stating this is "course work", I'll assume this is a school assignment.
You still haven't answered any of the questions above. I'm not going to repeat them for you, since you seem intent on ignoring them.
In all sincerity, why do you expect people here to help you when you ignore their requests for more information?
I understand that you may be a complete newcomer to coding and Visual Basic, but that doesn't explain why you don't answer the questions of people who try to help you.
Tengo mas preguntas que contestas
-
Apr 21st, 2006, 10:03 PM
#20
Re: getting the contact address from query in access
Plus, everyone is wiling to help but no one will write all the code for you. You need to let us know the answers and be willing to make an effort.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 22nd, 2006, 06:39 AM
#21
Thread Starter
Addicted Member
Re: getting the contact address from query in access
well i'm using vba
and window xp
sorry i didn't mean to ignore answering your questions!!!
-
Apr 22nd, 2006, 11:12 AM
#22
Frenzied Member
Re: getting the contact address from query in access
Are you developing your app in Access or Outlook, and which version? VBA is a version of Visual Basic that is common to all Office programs - Access, Excel, Outlook, Word, etc., but the specifics of how you accomplish a particular task depend on which program you're using. For example, you can program Outlook to do things from code in Access, but the code would be different than if you were programming within Outlook itself and getting your names from a table in Access.
Tengo mas preguntas que contestas
-
Apr 22nd, 2006, 11:15 AM
#23
Thread Starter
Addicted Member
Re: getting the contact address from query in access
well i'm tring to code stuff in access if possible but if it not possible than i would do it in outlook
which one is easier?
-
Apr 22nd, 2006, 01:41 PM
#24
Re: getting the contact address from query in access
Easiest way to do this is in Access since you are using Access code already.
Create a recordset of your email addresses and then...
VB Code:
Do While oRs.EOF = False
Application.DoCmd.SendObject acSendNoObject, , acFormatTXT, oRs.Fields("EmailAddress").Value, , , "Spam", "This is the message text", False
oRs.MoveNext
Loop
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 22nd, 2006, 01:45 PM
#25
Thread Starter
Addicted Member
Re: getting the contact address from query in access
where should i put this code.i'm mean which part of access?the table?
-
Apr 22nd, 2006, 01:46 PM
#26
Thread Starter
Addicted Member
Re: getting the contact address from query in access
i think since i'm sending the reports i should put it some where in the report.or should i make a command button and then locate it there?!
-
Apr 22nd, 2006, 01:47 PM
#27
Re: getting the contact address from query in access
You can place it behind your form in a button click event procedure.
You can not place any code behind a table. 
You also need to create your recordset of the email addresses.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 22nd, 2006, 01:49 PM
#28
Re: getting the contact address from query in access
If your sending an object, like a report, then you need to change the code a bit. Change acSendNoObject to acSendReport and then the next parameter (the blank one) will be the report name.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 22nd, 2006, 01:50 PM
#29
Thread Starter
Addicted Member
Re: getting the contact address from query in access
-
Apr 22nd, 2006, 01:52 PM
#30
Thread Starter
Addicted Member
Re: getting the contact address from query in access
what should i do if i want the system to send it automatically at the end of each month?!
-
Apr 22nd, 2006, 01:54 PM
#31
Re: getting the contact address from query in access
You would need to keep your db open and use an API or two to create a timer event checking what day it is, once a day. Then if its determined to be the last day, call the procedure to send the emails.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 22nd, 2006, 01:58 PM
#32
Thread Starter
Addicted Member
Re: getting the contact address from query in access
well i have linked visual basic 6.0 to access to make my coursework a bit more complicated than the others (trying to be smart) ))))))
now should i put the timer in the visual basic codes and use the format function thing?!
-
Apr 22nd, 2006, 02:01 PM
#33
Re: getting the contact address from query in access
So then your using a combination of Access VBA and VB6.
Yes, you will place a timer control on a form and in the timer event decide if you want to email the reports or not.
VB/Office Guru™ (AKA: Gangsta Yoda™ ®)
I dont answer coding questions via PM. Please post a thread in the appropriate forum. 
Microsoft MVP 2006-2011
Office Development FAQ (C#, VB.NET, VB 6, VBA)
Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
If a post has helped you then Please Rate it! 
• Reps & Rating Posts • VS.NET on Vista • Multiple .NET Framework Versions • Office Primary Interop Assemblies • VB/Office Guru™ Word SpellChecker™.NET • VB/Office Guru™ Word SpellChecker™ VB6 • VB.NET Attributes Ex. • Outlook Global Address List • API Viewer utility • .NET API Viewer Utility •
System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6 
-
Apr 22nd, 2006, 02:02 PM
#34
Thread Starter
Addicted Member
Re: getting the contact address from query in access
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|