473,890 Members | 1,391 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How can I Send E-Mail from an Access Table using MS Outlook

12 New Member
I am running access 2010. I have a table with email address' as one of the fields. I want to send the same message to all or some of my contacts. The table is named Donors and the field is Email address. I am using outlook express for my e-mail.
Jan 30 '12
29 7868
8,834 Recognized Expert Expert
The Code can literally be executed from anywhere. The logical choice would be in the Click() Event of a Command Button on a Form, where all the Code can be self-contained, as posted.
Feb 1 '12 #11
12 New Member
I have copied the code into a module and will try to open the module with a macro command within the current table. Will get back to you later. Thanks ADezii
Feb 1 '12 #12
12 New Member
ADezii, I would like to run the code from a macro. Can I include the Click() event or some othe start code command in a macro. If so How??????

Thanks for all your help.
Feb 2 '12 #13
8,834 Recognized Expert Expert
Why do you insist on running this Code from a Macro?
Feb 2 '12 #14
12 New Member
It doesn't have to be a macro, anything just to make the code run.
Feb 2 '12 #15
8,834 Recognized Expert Expert
Create a Command Button on a Form, then Copy-N-Paste the Code to its Click() Event. Be sure to Customize the Code to fit your specific needs.
Feb 2 '12 #16
12 New Member
Will give it a try ADezii. As you can see I'm a rookie altogether using code. Thanks

I installed a command button on a form. On the expression builder I set it to On Click. Then I copied the code to the form. When I hit the button nothing happens.
Feb 2 '12 #17
32,584 Recognized Expert Moderator MVP
  1. When designing your form, select the object you want to trigger the code from (Probably a Command Button control).
  2. Open the Properties Window (Alt-Enter) and navigate to the On Click property.
  3. At the right of the property value space will appear a button marked with an ellipsis (...). Click on this.
  4. Select the 'Code Builder' option, which takes you to the VBA IDE window and creates a procedure template for you.
  5. Paste ADezii's code into here.

PS. Please stop posting responses which include quotes from other posts which are irrelevant and unnecessary. It just wastes my time removing them all for you. Also, if you have two sentences to reply with then please post them in one post. If you're not ready to post yet - wait until you're ready before posting. It's not too complicated really, even for someone with very little experience.
Feb 2 '12 #18
12 New Member
ADezii, When I hit the command button I get an error message

Compile error:

Expected: line number or label or statement or end of statement
Feb 2 '12 #19
32,584 Recognized Expert Moderator MVP
To save time later, and until ADezii becomes available, I suggest you post the code as you now have it in your module (exactly - Use Copy & Paste) and also provide the line number that the code stops at when you choose Debug from the error message. The following threads give instructions on how to handle that properly - Before Posting (VBA or SQL) Code & Debugging in VBA - 3) General Tips. If you follow the instructions carefully this should save you both a fair bit of time and trouble (but feel free to ask for clarification if anything is not clear to you).
Feb 3 '12 #20

Sign in to post your reply or Sign up for a free account.

Similar topics

by: Tom Brown | last post by:
Hi, I have what seems to be a simple problem. But I can not for the life of me find a way to send an integer over a socket. The send method will only accept strings. Here is what I am trying to do: testmessage = 'test message' msglen = len(testmessage) sock.send(msglen) sock.send(testmessage)
by: Piotr Bieniek | last post by:
Hello, I have a problem with UDP sockets. It concerns UdpClient class as well. It throws strange exceptions on subsequent Send calls. Exception is SocketException with native error code 10049. I noticed that it happens when I call Send for the second time in my program. It seemed strange, so I compiled and run Chat sample program from MSDN. To my surprise, it worked. But then I modified it. The only change was that I duplicated sending...
by: eswanson | last post by:
I have a web page I need to post a file plus some other fields to it. How can I do this from a asp.net page. I know I can send individual fields to the other page, but how do I send a file to the other page, or is there something else like a stream which will be like a file. I am attempting to get a way from writing out a file and then having to give the page that I am posting to the file name. Instead I would like to just from asp.net...
by: Markus Poehler | last post by:
Hi there! I have created NT Service that runs on a Server. It should NET SEND to a specifiv Client in a special case of environment. It does NOT net send. The Messenger Service is running. Manually executed in DOS net send works from server. I have created a 2nd NT SRV to test it that does nothing else then sending net send onStart and installed it on the server. That net send
by: charlies224 | last post by:
Hi, I am writting a software that requires me to make sure the Num Lock is always on and Caps Lock is always off. First, I know how to detect if Num Lock or Caps Lock is on or off (if someone is interested, let me know and I will send you the codes). Once we know if the stat of Num Lock/ Caps Lock is not what we desired, we just send the Num Lock / Caps Lock key to change the stat. From most of
by: eSolTec, Inc. 501(c)(3) | last post by:
I'm looking for code samples to send a jpg image from a client machine to a host machine. Both have the same image picWindows picture container. I would like to be able to send the image on one machine to another machine as close to realtime as possible. Also, can someone point me a direction to find out how to transmit various field of information, i.e. listboxview, listbox, textbox, datagridview etc via .NET remoting. Everything I've...
by: Phil Hunt | last post by:
I am porting an VB6 program to .NET C# There is a NET SEND command in the VB6 program. Just wondering if there is any thing similar in the framework. Thanks.
by: gvijayaratnam | last post by:
Hi All, I have a fn prototype as follows void print ( char *Buffer, usigned long bufferSize, int chunkSize ); This fn will accept binary file buffer and the buffer size and the chunk size, implementation must be open socket and send the buffer in chunks which is provided by the parameter.
by: SvenV | last post by:
I based my program on the asynchronous client/server example on msdn. There weren't too many modifications to the original code. I just created some extra code to response to different messages. F.e. when I send GETARTICLES<EOF> it gets the articles from the DB and when I send something else it does that specific task. That all works fine. The problem is when I connect to the server and I try to send 2 commands after another. F.e. First get the...
by: Thomas Mlynarczyk | last post by:
Hello, I was playing around a bit with generators using next() and send(). And I was wondering why an extra send() method was introduced instead of simply allowing an argument for next(). Also, I find it a bit counter-intuitive that send(42) not only "sets" the generator to the specified value, but yields the next value at the same time.
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.