automation error

Hi

I have set up an automation with Outlook and sending emails to our clients.
I am using Redemption to avoid the security dialogs.

The problem is when it sends around 373 email, an error will occur and
emails stopped. I tried to open other forms but an error msg pops up citing
not enough memory. (Other programs works properly). When I close Access and
reopen it operates normally and when I send emails again, it will stop again
at 373-5 emails.

I tried sending very much smaller sized emails e.g "just hello". (50 bytes).
It still creates the error after 373 emails. What could be wrong and how do
I overcome this issue. Help is appreciated.

Thanks in advance
Richard

Here's the code:

Set ola = CreateObject("Outlook.Application")
    Set myNameSpace = ola.GetNamespace("MAPI")
    Set qryResults = CurrentDb.OpenRecordset("QryEmailWithoutEmailRet")

    a = 1

    If qryResults.BOF Then GoTo ExitHere
    Me.lblStatus.Caption = "Creating emails. Please wait..."
    DoEvents

    Set myFolder = myNameSpace.GetDefaultFolder(olFolderDrafts)
    Set myItem = myFolder.Items

    qryResults.MoveFirst

    Do Until qryResults.EOF


            Set myTempItem = CreateObject("Redemption.SafeMailItem")
            Set FWDItem = myItem.Item(1).Forward

            FWDItem.To = qryResults!EMAIL
            FWDItem.Display
            FWDItem.Close olSave
            DoEvents
            FWDItem.DeleteAfterSubmit = True
            myTempItem.Item = FWDItem

            myTempItem.Send
            Me.LblStatus2.Caption = a & " emails sent"
            DoEvents

            FWDItem.Close olDiscard

        Set myTempItem = Nothing
        Set FWDItem = Nothing

a = a + 1
        qryResults.MoveNext

Loop


0
richardbee (13)
4/6/2005 2:24:16 AM
outlook 87535 articles. 11 followers. Follow

1 Replies
534 Views

Similar Articles

[PageSpeed] 54

I get a very similar problem.

When doing a 'mass' merge in outlook, it will throw errors after sending the
392'nd email!I have not found that this is effected by the size of the
email.

The specific error message i get is 'Cannot resolve Message Recipient'.  I
checked and double checked the obvious cause, the email address it is
attempting to send too is valid.

I have also tried the following to get around ths issue, but to no avail.

1.  Turned off automatic send/recieve.  (i had originally thought that this
might have been a problem with a 100% cpu spike when doing both s/r and
adding emails to the queue at the same time.)

2.  Changed the automation code to initalaize a close and open a new outlook
application after sending every email.  This was slow, i had high hopes that
it would get past 392, but alas! it failed!

Does anyone know of any setting that might effect this?

Regards

John

"Richard" <richardbee@hotmail.com> wrote in message
news:u1L3S6kOFHA.1096@tk2msftngp13.phx.gbl...
> Hi
>
> I have set up an automation with Outlook and sending emails to our
clients.
> I am using Redemption to avoid the security dialogs.
>
> The problem is when it sends around 373 email, an error will occur and
> emails stopped. I tried to open other forms but an error msg pops up
citing
> not enough memory. (Other programs works properly). When I close Access
and
> reopen it operates normally and when I send emails again, it will stop
again
> at 373-5 emails.
>
> I tried sending very much smaller sized emails e.g "just hello". (50
bytes).
> It still creates the error after 373 emails. What could be wrong and how
do
> I overcome this issue. Help is appreciated.
>
> Thanks in advance
> Richard
>
> Here's the code:
>
> Set ola = CreateObject("Outlook.Application")
>     Set myNameSpace = ola.GetNamespace("MAPI")
>     Set qryResults = CurrentDb.OpenRecordset("QryEmailWithoutEmailRet")
>
>     a = 1
>
>     If qryResults.BOF Then GoTo ExitHere
>     Me.lblStatus.Caption = "Creating emails. Please wait..."
>     DoEvents
>
>     Set myFolder = myNameSpace.GetDefaultFolder(olFolderDrafts)
>     Set myItem = myFolder.Items
>
>     qryResults.MoveFirst
>
>     Do Until qryResults.EOF
>
>
>             Set myTempItem = CreateObject("Redemption.SafeMailItem")
>             Set FWDItem = myItem.Item(1).Forward
>
>             FWDItem.To = qryResults!EMAIL
>             FWDItem.Display
>             FWDItem.Close olSave
>             DoEvents
>             FWDItem.DeleteAfterSubmit = True
>             myTempItem.Item = FWDItem
>
>             myTempItem.Send
>             Me.LblStatus2.Caption = a & " emails sent"
>             DoEvents
>
>             FWDItem.Close olDiscard
>
>         Set myTempItem = Nothing
>         Set FWDItem = Nothing
>
> a = a + 1
>         qryResults.MoveNext
>
> Loop
>
>


0
jperrin (1)
4/6/2005 9:58:25 AM
Reply:

Similar Artilces:

pst file size error
i had 20.000 mails in my outlook 2007. i deleted nearly all of them and remained back nearly 200 mails. but previous size of pst file did not change and is still nearly 3 GB. how can i fix it? Did you delete emails by size or just randomly? It's not the number of emails (unless you have a massive amount) but the size of them. Emails that are simply text-based are not large and don't add much to size. Attachments can and do. However, 3 GB is not a large PST for Outlook 2007. Are you concerned about this size? "turkanet" <turkanet@discussions.microsoft.com>...

Error in Log Each User's Session Guide
In creating a log that will track each user's entering and exiting the database, I followed the link provided by Gunny (Thanks so much, Gunny!) - http://www.access.qbuilt.com/html/session_logs.html And I've implemented all the necessary steps. There's only one "oddity" for my database - I currently have to use a frm_Welcome_Menu that everyone has to have opened 1st. What I did was I put an Event Procedure in the event "On Open" which, I was hoping, would call the frmHidden and then proceed with the rest of the coding. Below is my "On Open" ev...

Active Sync Authentication Error
Hello All, I hope someone can help me. I am pulling my hair from past three days. We have three HTC Desire with Active Sync configured to our SBS 2003 Exchange. Till Last week it was working perfectly until one phone had problem syncing Calendar items. I looked at the log and found the following 4 errors for Calendaring Sync. Event ID: 3005 Description: Unexpected Exchange mailbox Server error: Server: [xx.xxx.local] User: [xx@xxx.co.uk] HTTP status code: [500]. Verify that the Exchange mailbox Server is working correctly. Event ID: 8199 Description: Calendaring agen...

SQL Error: 512 in GP8 Mfg Module
Hello Everybody. The past few days, we get this error when working in the Component Trx Entry window (every trx) After clicking Ok on all the error windows, we are able to complete the Trx. We found KB Article 914891 that recommends an upgrade to the latest service pack, and will do this a.s.a.p. In the meantime, what is the impact of the error? Is data written correctly to the tables, etc .. Thx for your help. Maria. ...

Automation Testing in an Excel application.
Does anyone know of any software testing tool that is compatible with Excel? We have an Excel application based on csv files, embedded in VB code. Has VB user forms. Thanks. ...

OLE Registration Error
When I double click Microsoft Outlook I get a message saying "OLE Registration error the program is not correctly installed run setup again". I have uninstalled all of Microsoft office and installed it again and it is still coming up with the same message. Can anyone help please? Tony ...

Errors with Distribution Group Wizard and link to Public Folder Ar
I'm having a problem with setting up a Distribution Group with the Public Folder. My objective is to create a number of Distribution Groups that will archive the e-mail to them to a public folder. The DG and PF are both being created, but the link between the two is not. My objective is to use the PF as the store where a team will go to view general e-mail addresses that are being sent (webmaster@mycompany.com, for example). I am using the Add Distribution Group Wizard (ADGW, Server Management\Standard Management\Distribution Groups\Add a Distribution Group) to add the DG. I am...

MSHTML error
Some of computer using windows7 pro with MS outlook 2003 some time there is below error, anyway to fix or anyway I can update the MSHTML.DLL? Faulting application name: OUTLOOK.EXE, version: 11.0.8312.0, time stamp: 0x4a403990 Faulting module name: mshtml.dll, version: 8.0.7600.16490, time stamp: 0x4b2c9557 Exception code: 0xc0000005 Fault offset: 0x00062eea Faulting process id: 0xad8 Faulting application start time: 0x01caa4687ca04826 Faulting application path: C:\Program Files\Microsoft Office\OFFICE11\OUTLOOK.EXE Faulting module path: C:\Windows\System32\mshtml.dll Repor...

Error Message
I do not understand why I get this error message when I open Outlok Express An error occurred while establishing the Dial-Up Network connection "MSN" have cable and I am not on a network. Note: I have IE and also MSN and other browsers. -- Joni OE Tools | Options | Accounts | Mail | [account] | Properties | Connection | Always connect using... (uncheck) Joni wrote: > I do not understand why I get this error message when I open Outlok > Express > > An error occurred while establishing the Dial-Up Network connection "MSN" > have cable...

Errors in DiskPrep.
Hi, I am trying DiskPrep in Windows XP, I get errors: "Could not instantiate Virtual Disk Serice Loader." http://blogs.msdn.com/mikehall/archive/2010/03/27/windows-ce-powertoy-diskprep.aspx Has anybody used this tool in WinXP? Thanks ...

CRM Integration errors
I am trying to publish schemas in the settings and configuration tool. I enter the directory to publish to and I receive the following error. Error: Exception from HRESULT: 0x80040E4D. I can not find anything on the knowledge base about this error. Tricia Tricia, I've received the same error many times on the integration server. Typically the cause is the install. During install, the Integration server populates an internal table with information about the MGP and CRM. We've abandon totally the BizTalk integration in favour of Scribe's integraiton so I can't get ...

Publish with errors
received this error message when publishing changes. Error: cannot find root path for _xslfiles ?? Any thoughts. The file is there in inetpub/wwwroot ...

Strange error
Hello, I am trying to a load a RSS with some really simple=20 code. However when I run the code I got this error: '=1F', hexadecimal value 0x1F, is an invalid character. Line=20 1, position 1. Though the rss seems to me well formed. Here is the code=20 and the rss. TestRSS("http://www- 106.ibm.com/developerworks/news/dw_webservices.rss") Function TestRSS(ByVal strRSS As String) Dim reader As New XmlTextReader(strRSS) ' Load the XmlTextReader to the XmlDocument Dim xmlDoc As New XmlDocument Try xmlDoc.Load(reader) ...

Outlook Express Error. Need Help
Hey you guys. I keep getting this error. It says " Some errors occurred while processing the requested tasks. Please review the list of errors below for more detaails." When I click the task button in the window, under status it says "warnings". What does this mean? Thanks for any help. Regards, <awosolu@bellsouth.net> wrote in news:uGGFoFAPFHA.1176@TK2MSFTNGP12.phx.gbl: > Hey you guys. I keep getting this error. It says " Some errors > occurred while processing the requested tasks. Please review the list > of errors below for more detaails.&qu...

how to automate min and max on axis based on calculation
While automating some chart making with code, I am trying to automate the span of time reflected on the x-axis. Auto doesn't work because I need the beginning to be based on an October of a given year. Similarly I have requirements for the max. The appropriate min and max are calculated elsewhere, but I am not sure how to code it to accept the value from a cell. Any help would be much appreciated. TIA This has to be done programmatically. For a ready-made solution see AutoChart Manager http://www.tushar-mehta.com/excel/software/autochart/index.html -- Regards, Tushar Mehta www...

Shared workbook error
Hi, Maybe someone could help me out, I recently made the regularly used excel spreadsheets on out office network shared workbooks. It worked fine for about a day or so but soon started stuffing up. We started having the problem where after opening and working in it for sometime (sometimes not even long) it would start acting like a read only file and not allow it to be saved. After closing the file it would only allow the user too open as a read only, until you rebooted. after which it would start working fine again for a short time before doing the same thing once again. This was happening...

Error after GP 9.0 SP4 update
Greetings, We just applied SP4 for GP 9.0 and the server install went fine and most of the desktops work fine. Two of the desktop installs are generating an error during the login process. Error registering table SY_PATHNAMES_MISSING_TEMP. Clicking OK give another error: ICJC_LunkerStatuses. Clicking OK allows Dynamics to run. This is only happening on two desktops out of twenty. All installs were done with user with admin rights and computers were running GP with SP3 just fine previous to the SP4 upgrade. Any ideas on what could be the problem? Dave, It seems dictionaries got corrupt...

Money 2005 always crashes (wininet.dll error)
PLEASE HELP I have just purchased the download version of Money 2005 standard. HOWEVER, I am unable to use it at all. First of all it is not compatible with money 2003 which I find very hard to believe (and I found no reference to this on the microsoft money website). But most importantly the program crashes all the time. If I try to sign in using my normal internet access, I am unable to verify my passport account becasue I am behind a proxy. This also has stoped me downloading the complete program from the net. So... IF I say "work offline", The program goes to t...

CRM Calendar Error
Good Day Board, I have finally gotten the CRM to install and I'm now getting into the web interface. However, when I select the Calendar option under My Work, I get an "Unexpected Error" page, and nothing more. Anyone encounter this and know how to get around it? Thanks. This problem seems to have cleared itself up. I did nothing at all. Just came in the next day and tried again and it worked. Kirrin Jones wrote: > Good Day Board, > > I have finally gotten the CRM to install and I'm now getting into the > web interface. However, when I select the Calenda...

CRM / Crystal Install error
Just wondering if anyone is having the same install problem I am and if there is a solution. I am installing CRM on it's own server and using an existing SQL server. CRM installs to the default instance of SQL which is good but half-way through the install when it tries to setup Crystal Reports I get the error "Failed to install CRM Server Unknown error 80040e14" When I check the SQL logs I find that the Crystal APS service is trying to log into the SQL server on a Anonymous account? SQL log reports "Logon for NT Authority/Anonymous, access denied". Everything ...

Need to consolidate large quantities of data and vlookup errors out
I've got a large table with horse racing odds that go fron .10-1 t 150-1 in .10 increments with values assigned to those odds, so it look like this: A1 B1 .10-1 4 .20-1 4 .30-1 3 etc. all the way up to 150-1. I tried making a table out of this with 2 columns and my hands wen numb after inputting about 200 odds entries :) I tested it out wit the part I did manage to complete with the vlookup formula and it gav me some wierd errors for results (maybe because of so many entries) For example, using the first example above, the user would input .10- and it would spit out 3 rath...

Error Message when send/receiving: An object could not be found.
Can anyone tell me why this error message comes up when I try to send/receive in Outlook? I have tried to repair using the disc, but it doesn't help this problem. ! The operation failed. An object could not be found. Thanks, Kimberley ...

Printing errors in excel
When I highlight some rows and colums to print, the matching column headers aren't printing right unless the size is reduced to 40% in print preview/setup. I have freezepanes set up on the left and top, and when I print out data, I have it set so all the freezepanes print as well. I have names across the top, and date of birth and other information below. When I hightlight the data below, the names don't match when I print with the data I hightlighted, unless i change the print size to less than 45%. Any ideas? I tried multiple versions of excel and several printers within ou...

Illegal operation error while printing EXCEL or WORD Files
Hi, I am facing an illegal operation error when i try to print any file from excel (any no. of pages), this happens in stand alone printer as well as a networked printer. When we press the print button, it flashes this message, but still prints, but once the printing is completed, i will have to restart the PC. Due to this error other applications PRINTING also will NOT HAPPEN and the only way out is, restart the PC. This happens not only in EXCEL, it happens in all the MS applications (outlook, access, front page, powerpoint also). When I check the print manager (before restart),...

Error on the script of this page
This is a multi-part message in MIME format. ------=_NextPart_000_0009_01C6FD1E.A3BEE240 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello, Every time I open personal folders, I get a message saying: Error on the script of this page line 298 car 1 error: non registered class code 0 =20 URL: outlook today I close it, and then every thing works OK Thank you for your help if possible Louis MOUSSY ------=_NextPart_000_0009_01C6FD1E.A3BEE240 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-...