Hi Thanks for replying,
I need to give you some more details, this script runs from the following batch file that is scheduled to run overnight on a microsoft windows server 2008 r2 with exchange 2007
batch file reads
"c:\windows\system32\windowspowershell\v1.0\powershell.exe" -psconsolefile...
Hi All,
Thanks in advance for any help given, I have recently taken over a new job role from a collegue who has a powershell script that create mailboxes from a csv file and for some unknown reason has stopped working, I am new to windows powershell and I was wondering if anyone had any ideas...
Hi,
Here is the new code
Option Compare Database
Private Sub Command4_Click()
On Error Resume Next
Dim objOutlook As Object
Dim objEmail As Object
Dim MyDb As DAO.Database
Dim rsEmail As DAO.Recordset
'Dim PER As DAO.Recordset
Dim sMessageBody, strCC
Dim apetext As Variant
Dim abdtext As...
Hi,
Sorry for being vague, I put the code in like this:
If PER.BOF = True And PER.EOF = True Then
MsgBox "No data in recordset"
Else
objSheet.range("A9").copyfromrecordset PER
objworkbook.saveas Application.CurrentProject.Path &...
Many Thanks for the advice PHV and VBAJOCK, but I still have the same problem with there being no sheets in the workbook, its like it has somehow closed the workbook before doing the save as. I have looked everywhere and this code is correct, any help will be much appreciated
Many Thanks
Diehippy
Many Thanks vbajock for you fast reply,
I check and this was an error when I transferred over to notepad not an error in the code, but thanks for pointing that out I thought I had missed something but I could not see what.
the file attaches correctly and looks like an excel file even has kb...
Hi All,
I have been working on an email project where I use a couple of sql queries in access to send an email with an excel attachement. It all works quite will except that the excel attachment comes up blank or closed? I am not sure anyway the worksheet is gone and I am unsure why, any help...
Hi All,
I have put together a vba script that runs two sql queries using the data to populate a html template and then call that template and email it to an email address from one of the queries, this does almost everything I want except that if the query PER has more than one line of data...
Thanks for your Help GComyn,
It is most appreciated, I have changed my code to the following which done almost what I wanted it to do
Private Sub Command4_Click()
On Error Resume Next
Dim objOutlook As Object
Dim objEmail As Object
Dim MyDb As DAO.Database
Dim rsEmail As DAO.Recordset
Dim PER...
Thanks Traingamer,
been looking at the code for ages missed that simple point
PER is populating my html body of my email through a function call ReturnTemplate. Being quite new to vba, I would like to link the two queries together rsEmail and PER, both queries have a field that can be linked...
Hi,
I was wondering if anyone would be so kind to have a look at my code and tell me where I am going wrong. My code has calls two queries the first populates the email add and the subject line and the other query fills the html template I have borrowed a template function to call it from an...
Hi All,
I was wondering if someone could give me some advice on why my package keep failing on the exception that I have added to the end of two update statements. The error that I am getting is the following "PLS-00103: Encountered the symbol ""EXCEPTION"" when expecting one of the following...
Hi Dagon,
It is possible, I need to setup the second update with a seperate cursor to get the correct values in the second update. You thoughts will be most appreciated
Many Thanks
Mark
Hi Dagon,
Thanks for the reply,
I have restricted the first update to only update where first grade = 'FL' or first_grade is null so any other data should come back as 'N' if it has not updated due to this restriction. As I understand it.
Many Thanks
Diehippy
Hi All,
I was wondering if you could help me I have created a pl sql script that when run, will update a table with some values then update the tables that the values came from with either a success or failure except it is just updating every record the same either success or failure and not a...
Hi Skip,
It works, that is brillant, I can not thank you enough for this, I thought I was going to lose my mind (hopefully not) can I use a simlar range code for creating the filename as I need to use the selected cells data from the third sheet
Many Thanks again you have been a absolute star...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.