Computer Support Forum

Excel Macro: Auto Email

Question: Excel Macro: Auto Email

Hello all;

I am new to this forum and also to Excel macros. I have a large Excel file detailing financial accounts with my small business.
Anyway, I would like to email any customer who has an overdue balance as per column V in my attached sample file (any customer with a greater than zero value in V). I would like to send an email; something like this:

Joe Wilson;
As of 2/28/11 (latest date in the row that is on/after the current date), your account is currently overdue and you owe $1500.00 (G3).
Thank you.
Treasurer
I found several other threads explaining how to send an automatic email from Excel, but I haven't found one for sending an individualized email to a list of recipients. If this question has been answered, please feel free to redirect me. Otherwise, I'd appreciate any suggestions. Please let me know if I can detail my needs any better.
Thanks!

Relevance 100%
Preferred Solution: Excel Macro: Auto Email

I recommend downloading and running Reimage. It's a computer repair tool that has been proven to identify and fix many Windows problems with a high level of success.

I've used it in the past to identify and fix everything from blue screens (BSOD's), ActiveX errors, corrupt files and processes, dll/exe/sys errors, recover lost memory, Windows update problems, defragging, malware removal etc.

You can download it direct from this link http://downloadreimage.com/download.php. (This link will automatically start a download of Reimage that you can save to your computer.)

Answer: Excel Macro: Auto Email

welcome to the board.

I put some code in the sheet

The macro name is CheckAndMail

Let me know if this is what you need

PS: I just corrected something I came accross and have re attached the corrected sample

2 more replies
Relevance 90.2%

Hi there - Using MS Access 2007.
I have a FORM with a macro that runs a query to generate ONE excel file and attaches to email using MS Out look to send out. - That Works great.

Problem: Multiple users to send email & attachment.
I would like for the macro to generate excel file (S) - based by the UID.

Can someone suggest a better way of handling this that is not time consuming?

Thanks In advance!
 

Answer:MS Access 2007 - Macro > Excel > Auto Email

Access can open Outlook and send an attachment to mutiple recipients either as a list or as individual emails.
So are the attachments all the same for the recipients?
 

1 more replies
Relevance 88.15%

Hi all

Looking for some help! Working on an excel document which contains a button I need to send to multiple people, that's fine what I need is for the subject field of the email to take the contents of a particular cell in the workbook and display that. My current code is;
Code:
Sub SendThis_ActiveWorkbook()

Dim Recip()
With ActiveWorkbook

ReDim Preserve Recip(0)
Recip(0) = "[EMAIL="[email protected]"][email protected][/EMAIL]"
ReDim Preserve Recip(1)
Recip(1) = "[EMAIL="[email protected]"]example[/EMAIL][EMAIL="[email protected]"][email protected][/EMAIL]"
.SendMail Recipients:=Recip, _
Subject:="Vacancy Authorisation " & Format(Date, "dd/mmm/yy")
End With

End Sub
Basically I want the subject to be "Vacancy Authorisation [cell contents] 01/01/2000" so I want the contents of a cell to appear in between the date and the "vacancy authorisation" part of the subject line. Assistance appreciated!
 

Answer:Solved: Excel email macro auto-populate subject line

Subject:="Vacancy Authorization " & Range("A1").Value & " " & Format(Date, "dd/mmm/yy")

Regards,
Rollin
 

2 more replies
Relevance 72.16%

Hello,

I've got this code to get rid of all leading apostrophes in the Excel (2003) Cels:

Code:
Sub Auto_Open()

Dim S As Range, temp As String
Worksheets("qryOfficeNetForeign").Activate
With Worksheets(1)
If MsgBox("Are you sure you want to remove all leading apostrophes from the entire sheet?", _
vbOKCancel + vbQuestion, "Remove Apostrophes") = vbCancel Then Exit Sub
Application.ScreenUpdating = False
For Each S In ActiveSheet.UsedRange
If S.HasFormula = False Then
'Gets text and rewrites to same cell without the apostrophe.
S.Value = S.Text
End If
Next S
Application.ScreenUpdating = True
End Sub
This code runs fine when I use the shortkey for it (CTRL + R), but when I try to autorun it I get an error:

Code:
Runtime Error 91: Object Variable Or With Block Variable Not Set
When I click the debug button, this line is selected:

Code:
For Each S In ActiveSheet.UsedRange

How can I autorun this code on opening of Excel, I would also like to run the code only if the sheetname is: "qryOfficeNetForeign"
I am no VBA expert, so am getting only errors
Thanks,
Wouter
 

Answer:auto run macro on excel start

7 more replies
Relevance 71.34%

I'm trying to write a macro that will go down a column and fill in the blank cells by adding 1 to the cell value above. The macro will need to skip cells that already have a number. Column goes down ~11,000 rows

Before:

102
blank
blank
201
blank
blank
104

After:

102
103
104
201
202
203
104

Thanks.
 

Answer:Solved: Excel Macro to Auto Number

No macro required.

Select the first blank cell, then the whole column (CTRL+SpaceBar).

Press F5 > click "Special" > select "Blanks" > click "OK".

Type "=" (the "equals" sign), press the UpArrow key (formula bar says "=A1", for example), modify to "=A1+1", press CTRL+Enter to enter the formula into all selected cells simultaneously.

To "top & tail" copy and Paste Special > Values the entire column.

Full instructions here. HTH, welcome to the board.
 

2 more replies
Relevance 70.93%

Have a spreadsheet, with a macro that runs on start up.

It uploads data from the web and places it in a worksheet named data, and from that worksheet certain info is used in another worksheet all of which are in the same workbook.
Macro is such that when a new month commences a new worksheet with month/year is opened

All has been working until yesterday 1/6/12 (Aust) .

The data uploaded is always 1 day behind actual date so on 1/6/12 the latest data would have been for 31/5/12 and would have gone into the May 2012 worksheet.

The problem I have encountered is that the file becomes blurry and I am unable to close it down .
Have had to manually shut down and reboot to use computer.

Ran a quick scan with Malwarebytes and it cam up with one infection "Pup.Bundleinstaller.Bi " which I had removed.
Have since run full scan with no infections

Details from Hijack this log show
Logfile of Trend Micro HijackThis v2.0.4
Scan saved at 10:22:20 AM, on 02-Jun-12
Platform: Windows 7 SP1 (WinNT 6.00.3505)
MSIE: Internet Explorer v9.00 (9.00.8112.16421)
Boot mode: Normal

Running processes:
C:\Program Files (x86)\Common Files\Acronis\Schedule2\schedhlp.exe
C:\Windows\vVX1000.exe
C:\Program Files (x86)\Google\GoogleToolbarNotifier\GoogleToolbarNotifier.exe
C:\Program Files (x86)\Skype\Phone\Skype.exe
C:\Program Files (x86)\Google\Google Desktop Search\GoogleDesktop.exe
C:\Program Files (x86)\Google\Google Desktop Search\GoogleDesktop.exe
C:\Program Files (x86)\TaskPlus\taskplus0... Read more

Answer:Problem opening Excel fiel with auto run macro

Problem solved it was not a virus .

Thanks to all who looked at asisting

Pedro
 

1 more replies
Relevance 70.93%

Hi,

I have a worksheet containing various data including an expiry date, this is created by adding 364 to the start date and then then using an auto fill to fill in all other rows (over 50,000).

I would like to make a macro to do this alongside a number of actions but when making the macro I am specifying only a certain range to fill (A1:A50000). The problem I have is this list is consistently growing and so this range would then not include any new records added. Is there a way that I can make it so it auto fills from A1 to the last present row?

Thanks for your help

Dan
 

Answer:Solved: Auto Fill Data in Excel Macro

8 more replies
Relevance 70.11%

Hi All,

I really hope someone can help me. I've been looking through all the forums and haven't quite found a macro code that has worked for me. I know this is very simple, but I have no idea what I am doing. Here it goes....

I have a very simple expense report on Sheet 1 of an Excel (2007) workbook. In this worksheet, the first couple of columns simply list the expense items. However, there is a table with only 14 rows (including the header) of data (6-19). Underneath row 19 is a total row that sums the 2 columns of information (don't need to worry about this row but thought I'd tell you anyway). This table only has 4 columns as follows:

Column G - Code
Column H - Category
Column I - $ (this column is using the SUMIF function to calculate the expense category totals)
Column J - % of Total (this column is simply dividing column I by the Total $)

I don't know if this matters or not but there is also a pie chart linked to this table of information.

I would like this table (H6:J19) to automatically sort by % of Total (in descending order) any time I add new expenses so that I don't always have to sort manually.
If there is a way to do this, I would so appreciate simple instructions. I've attached a sample of what the report looks like.
I hope you guys can help!!!
 

Answer:MACRO NOVICE - Simple Auto Sort using Excel 2007

Hi Janel, welcom to the board

I think this should do the trick, I don't have 2007 here but I used your sheet in 2003

Add the following code the the Sheet1 project

Code:


Private Sub Worksheet_Change(ByVal Target As Range)
Sheet1.Range("G7:J19").Sort Key1:=Range("J7"), Order1:=xlDescending, Header:=xlNo, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom, _
DataOption1:=xlSortNormal
End Sub

To do this just right-click on the Sheet1 tab and select view Code, you will automatically be in the VBAProject.

In the right screen paste the code above.

every time you change values in the list the range G7:J19 without hearders will be sorted by Total % descending order, th epoie chart will do it's own work since it's related to this table.

Happy coding.
 

1 more replies
Relevance 69.29%

I'm sorry if this has been discussed elsewhere but I have been looking all over for this answer. I feel like this is my last resort; I hope you can help.

I am in charge of developing forms on Excel. With ONE worksheet containing only ONE form, each workbook will have any number of worksheets (from 1 to over 200).
I have created a macro designed to insert the required header and footer information, for each form (AKA each worksheet), simultaneously for the entire workbook.
Now here is my challenge. Within the required footer information, each worksheet (form) must have a unique number (e.g., 7510001); the department is 751 and the first form number will be 0001.
The next form (worksheet) must have the number 7510002 in its footer information, and so on.
What I would prefer is the ability to insert the first number (possibly in a pop-up screen) and then have the macro populate the increment for the rest of the worksheets within the workbook.

Thank you in advance.

Bob
 

Answer:Solved: Macro for Auto Inserting a Number Incrementally (+1) in the footer of Excel 2

6 more replies
Relevance 68.88%

I have an Excel model (office 2000) which has a range of cells that contain if/then statements. I'm trying to get Excel to automatically send an email if any of the cells within that specified range were to provide a value that was false. Is this possible? Thanks for any insight.
 

Answer:Email Macro in Excel??

16 more replies
Relevance 68.88%

Any way of controlling the time a email is sent via a excel spread sheet using vba?
 

Answer:Excel - macro email-

6 more replies
Relevance 68.88%
Question: Excel Email Macro

Hi

I am trying to write a macro in Excel 2003 to automatically send an email using Outlook to a list of individuals asking them to confirm their personal details using the attached template. Could someone show me where I am going wrong with the script please?

Many thanks
 

Answer:Excel Email Macro

16 more replies
Relevance 68.88%
Question: Excel Email Macro

Hi All,

I have a spreadsheet and i am needing to create a macro that will opena new message in Outlook and populate the 'To' Field with one cell and then the 'CC' field with 2 email addresses, one from one field and the other from a different field. then the subject from another field and then the body from another. it then leaves the message window open so i can check it right and hit send.

I found the script the other day but can not find it anywhere including this site.

Any help on this will be great.

JPL

Any
 

Answer:Excel Email Macro

Hi JPL,

You could use this function, just pass the values to it
Code:

Function MailData(mSubject As String, mMessage As String, Sendto As String, Optional CCto As String)
Dim eSubject As String, EBody As String
Dim app As Object, Itm As Variant
Set app = CreateObject("Outlook.Application")
Set Itm = app.CreateItem(0)

With Itm
.Subject = mSubject
.to = Sendto
If Not IsMissing(CCto) Then .CC = CCto
.Body = mMessage
' .Attachments.Add (NewFileName1) ' Must be complete path
.Display ' This property is used when you want
' .send
End With
Set app = Nothing
Set Itm = Nothing
End Function

It's from one of the posts, I do not remember which one
 

1 more replies
Relevance 68.06%

I have a user who wants to create a macro which will automatically send an excel spreadsheet into outlook and email it.
Any suggestions welcome. Thanks.
 

More replies
Relevance 68.06%

My sense is this is a pretty simple request, but I'm completely illiterate when it comes to VB.

I have an excel spreadsheet with a number of data points. I'm looking to export the entire sheet to a CSV file and send it via Outlook. Any suggestions?
 

More replies
Relevance 68.06%

Windows 7 --------------------------------------------------------------------------------First thing...I know nothing about macros!! I do know a very little about formulasI have created "IF" formula in excel 2010, based on a date it will create a send due in column "E", =IF(D5=$A$2,HYPERLINK(mailto:"&$K$1&"?subject="&A5&-B5&"&body="&$C$3,"sendworks great but, I have to go thru 86 rows in column "E" and hit "Send Due" numorous times,then hit send again on all the emails, can we automate this some how, like a macro that engadges when I open my outlook every morning?Thank u

Answer:Need Macro to automate email from excel

I have written code in Outlook, which is essentially a template, you fill in the details, all sorts of stuff happens accordingly to what you have selected, and you press send and it will send the emails to whoever it is you want. Iv done this in Outlook, so my question is, why do you need this to be done in Excel? is Outlook acceptable?

3 more replies
Relevance 67.24%

I would like to ask for an Excel macro which can send an automate email on a certain date every Month.

The dates would be as follows:

1st Monday: Email should be sent to [email protected] automatically
2nd Wednesday: Email should be sent to [email protected] automatically
3rd Tuesday: Email should be sent to [email protected] automatically
3rd Tuesday: Email should be sent to [email protected] automatically
3rd Tuesday: Email should be sent to [email protected] automatically

Subject line: ABC123D5679_Data transfer expected today

Details of the body of the text message:

"Dear All,
This is to remind you that we are expecting the data transfer to be posted in Novartis system today . This is just an advanced intimation.

Kindly let us know if you foresee a delay in the data transfer.

Kind regards,
Rohit"
Many thanks in advance for your help guys. This means a lot.
 

More replies
Relevance 67.24%

Hi - I have a list of names for a particular company where I have the first name and last name of the customer plus the email naming convention their company uses. For example the company's email naming convention is: [email protected] Is there a way I can create an Excel Macro that will automatically create the email from the available information? For example if I create three columns where one has the first name, last name and the @companyurl.com?I hope someone can help with this as it will save a lot of time!!Thank You!

Answer:Need Excel macro to creat email address out of just a name

This can be done fairly easily, but I'm not going to offer any suggestions.Since it appears that you do not work for this company, I can only assume that this will be for some sort of mass, unsolicited mailing. If your project was sponsored by the company in question, they would supply you with a distribution list and you wouldn't have to build your own.For all I know, I'm on that list of names that you have and I don't need any more unsolicited email.Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

3 more replies
Relevance 67.24%

Hello

I need to come up with a simple outlook macro (or script?) that fires off whenever a new email meeting certain criteria is received.

1. new email is received with "please refresh quotes" in the subject
2. outlook runs a macro that causes another macro to run (the second macro is located in a excel workbook which is already running in my office pc)
3. the excel (attached) is simply refreshing market prices and emails whenever the macro is triggered. because the quotes are obtained via a DLL feed I can only get it at work.

the purpose is simply to get live market quotes on my personal email from my work email whenever i need.
thanks in advance for your help.
 

Answer:Solved: Run excel macro when new email is received

9 more replies
Relevance 67.24%

Hi there,

I have a workbook which i would ideally like to send an automated mail when the date is within 30 days of "Todays date" .
I have found something similaar on past posts whichprints certain cells to an email but is triggered by a button press not date, but wondered if anyone could adjust it for me as my excel knowledge is very limited.
I really am struggling.

The password for the spreadsheet is Kalibratedbyme (capital K)

Best regards and many thanks!
 

Answer:macro to allow a date to send an email in excel

The content is different but why are you duplicating a post?
 

3 more replies
Relevance 66.42%

Hello,

My first post, sorry to be a leech right off!

I'm trying to automate some of my day to day emails. I'd like to get a macro set up that will send an email from Excel and paste the range I select in to the body of the email. Would be great if it would send to a list of addresses listed on the page as well.

Using the attached example, I'd like the macro to take whatever range I highlight on the table, copy it to the body of an email and send it to the group of emails listed on the right side.

I'm learning excel, this would help me a lot! I'll be editing this to fit a variety of other tasks. I hope it can be flexible. Thanks in advance.

Chris
 

Answer:Macro: Email Range/Selection to group from Excel

http://www.rondebruin.nl/mail/folder3/mail4.htm

I have done the looping attached.
 

2 more replies
Relevance 66.42%

Hy guys

2nd time i am posting stuff for help, and as i was helped before i will again look forward the response.

I have a file of excel, in which i am sending emails to different candidates of admission, with scan letter placed in the same folder by name.

I want to edit this code, which could select attachment based on Column A list adjacent to the email address

I am attaching the file also pasting the code

Sub Test1()
'For Tips see: http://www.rondebruin.nl/win/winmail/Outlook/tips.htm
'Working in Office 2000-2013
Dim OutApp As Object
Dim OutMail As Object
Dim strbody As String
Dim SigString As String
Dim Signature As String
Dim cell As Range

Application.ScreenUpdating = False
Set OutApp = CreateObject("Outlook.Application")

On Error GoTo cleanup
For Each cell In Columns("B").Cells.SpecialCells(xlCellTypeConstants)
If cell.Value Like "?*@?*.?*" And _
LCase(Cells(cell.Row, "C").Value) = "yes" Then

Set OutMail = OutApp.CreateItem(0)

strbody = "We at Graduate School of Engineering Sciences and Information Technology are extremely pleased to know that you have selected Hamdard University as preferred choice for your graduate/post-graduate Studies. " & vbNewLine & vbNewLine & _
"Hamdard University is a pioneer Higher Education Institute (HEI) of Karachi producing Masters and PhDs in the fields of Engineering, Computer Sciences, Information Technology, Energy and Environment since 19... Read more

Answer:Attachment based on cell value in a excel email macro

anybody ???
 

2 more replies
Relevance 66.42%

I found this code in this forum.
i want to add recipient as CC or BCC. What is the correct code for that?
Thanks in advance!

Code:
Public Sub email()

Dim SubJ, Recip As String

SubJ = "Enter your suject"
Recip = "[email protected]"


ThisWorkbook.SendMail Recip, SubJ

msgbox "Email Sent"

End Sub

 

Answer:Send excel sheet ( email) through macro with recipient and cc

6 more replies
Relevance 66.42%

Hi:
I am very new to Excel 2007 and macros. I have a spreadsheet that I am trying to get to send an email reminder to the point of contact [ col b ] 5 days prior to the closure document due NLT date [ col m ]. I am looking for assistance in writing a macro which will accomplish this if it is possible. I have attached the spreadsheet that I referenced.
Your assistance would be greatly appreciated.
Thanks in advance.

desantisj
 

Answer:Excel 2007 Macro to Send Reminder Email

desantisj, welcome to the Forum.
There are already 3 or 4 posts on this forum that have the VBA code (Macro) that you can modify for your Workbook if you can read the code. Zack has written the code so it is a bit complicated, but it should be a case of substituting your Cell references that hold the data for the ones that others have used.
Otherwise it is a case of waiting for an Excel guru to come along and help. If none of them come along I can probably help you, but I normally work with Access.
 

2 more replies
Relevance 66.42%

Hi
I need help writing a macro that takes an Excel file to email.

The Excel file is a data base, I wanted the Macro to take the email from a column of the Excel file, and send out the email to all the emails in the database, if possible also adding a column of the Excel file to address the specific person.

thank you.
 

Answer:need help writing a macro that takes Excel file to email

Can you post a sample file? Please remove any sensitive data.

Rollin
 

2 more replies
Relevance 66.01%

I found how to send an email from an Excel Macro (http://forums.techguy.org/business-applications/1056070-solved-excel-email-outlook-code.html)

Here is the code I'm using:
Code:

Sub Email_Test()
'
' Macro11 Macro
' Keyboard Shortcut: Ctrl+r
Dim eSubject As String
Dim Sendto As String
Dim CCto As String
Dim Body As String
Dim app As Object
Dim Itm As Variant
Set app = CreateObject("Outlook.Application")
Set Itm = app.CreateItem(0)
'Populate variables

mSubject = "Excel EMail Test"
Sendto = "[EMAIL="[email protected]"][email protected][/EMAIL]"
CCto = ""
mMessage = "You have received Knowledge Document Feedback for your domain."

With Itm
.Subject = mSubject
.To = Sendto
If Not IsMissing(CCto) Then .CC = CCto
.Body = mMessage
' .Attachments.Add (NewFileName1) ' Must be complete path
.Display ' This property is used when you want
' .send
End With
Set app = Nothing
Set Itm = Nothing
End Sub
Is there a way to format the message section with bullets? How about paragraph breaks?

Name: John Doe

Date: 6/15/2012
Doc #: KM123456
Etc:
Etc:
Comments:
I'm perfictly willing to look at how-to documentation if someone can point me in the right direction.

Thanks
firstshot
 

Answer:Solved: Formatting Excel Macro Email Message Section

Hi, I haven't really looked myself but instead of bullets I generally use a dash and a tab
Paragraph as such are not possible but you have the linefeed and carriage return

example to add to your macro code before calling the mail proc
Code:

Dim mytext as string
mytext = vbnullstring
mytext = "Dear Jon Doe" & vbclrf & vbcrlf
mytext=mytext & "-" & chr(9) & "Date :" & the date variable & vbcrlf
mytext=mytext & "-" & chr(9) & "Doc #:" & the dos variable & vbcrlf
mytext = mytext & "-" & chr(9) & "Etc :" "etcetera"
mytext = mytext & vbcrlf & vbcrlf
mytext = mytext & "Sincerely yours," & vbcrlf & vbcrlf
mytext = mytext & "Jane Doe" & vbcrlf

vbcrlf can also be replaced wij Chr(10) or Chr(13)

See it this helps.

Maybe html formattingis possible but this works just as fine.
 

3 more replies
Relevance 66.01%

Hello,

I have a list of email addresses that have either:
[email protected]
[email protected]
[email protected]
or no corelation to [email protected]

I'm looking for a macro that will take the emails with dots in them and put the first and last names into cells next to the email. The others I can do by hand. PLEASE HELP!
 

Answer:Solved: Excel Macro to convert email addresses to names

16 more replies
Relevance 65.19%

Hi there

can someone help me trigger auto email from the attached excel sheet ?

The email should be triggered upon the 'status' with corresponding message from 'remarks' column
 

More replies
Relevance 65.19%

hello,
i am trying to sent out an automatic email anytime the workbook has been changed and for example 3 days have passed from a certain date on the worksheet. this would have to be applied to close to a hundred rows per sheet and would be sent to outlook 2007. not express or anything. wondering if it would require multiple VBA codes or not.
i have looked on the Ron site and many postings but i just found out what a macro was and would love to learn how to write VBA but dont have the time. looking to try and solve this. also need to know if the computer im working on has to have outlook or if i can do it from one that doesnt.
Have an example and any details for further assistance just ask. any help would be greatly appreciated thank you.
 

Answer:Auto email using excel

16 more replies
Relevance 65.19%

Firstly i would like to say hi to everyone and thanks in advance for any advice / help.

Here is my problem...

I have a spreadsheet and it contains a list of our employees and when any of their work related certificates expire. What i would like to do is create a script??? or something that will run and send an email to a selected list of people informing them that a certificate is about to expire.

The spreadsheet is excel format and the email software my work uses is Groupwise.

Also something to note would be that there may be multiple people who have expiring certificates at the same time, would it be possible to send just one email or would individual emails be the only way to go.

I have attached a very simple spreadsheet so you can get a better idea of what i mean.

Once again, thanks guy for any help you can provide.
 

Answer:Auto Email from Excel

why oh why do spamers exist
 

2 more replies
Relevance 65.19%

Hi all,

I need to know if is it possible that a macro in Excel sends an email containing the visible cells using Microsoft Outlook.
btw, I saw some code on the internet, that saves the visible cells in a new excel file and attach it in a new email using Microsoft Outlook, but I don't want to have attachments in the email.

thanks for any possible help.
 

More replies
Relevance 65.19%

Although decently experience with excel, I am quite new with VBA and I cannot "record" this macro, so any help writing this in VBA is much appreciated.

1) I need to create a macro that will take a number that is entered into a cell, and upon hitting a button in the excel sheet create an email where the subject line is the number that was in that original cell.

1b)I would like to do this without changing the name of the excel file though, or at least have another macro that resets the file to its original name.

2) Also, if possible, the same macro/vba as above, only with two cells, a number in one and a name in the other, which then shows up as "Number-Name" as the subject line in the email.

Thanks to anyone that can help - Mike
 

Answer:Excel Macro -> email created with field data as subject line

8 more replies
Relevance 64.37%

HI All,

Can any one help me on this.

I want to auto send email from file whwnever a cell value changed.

In attached excel file if the value of cell "C" get changed to yes then excel should automatically send email to the addreess mentioned the column D.

Help on this .

shishir kumar
 

Answer:Excel to auto send email

Hi there, welcome to the forum,
There are quite a lot of postings with similar questions.
Have you checked this? You can search for then and I'm sure that the solution is there for you.
Some minoor editting may be needed but it will work
 

1 more replies
Relevance 64.37%

Hi I am trying to set up a Client data base and I would like to be able to email everyone in the company when a change has been made to columns B,D,E, and F. I plan on having different tabs for each company and when I update the companies folder and change one of those four columns, Iím looking for it to send out an email alert saying "CompanyX Contact Manager Client Folder Has Been Updated".

I have been trying my best to figure it out with info I found on here but I am not very good with Code and any help will be much appreciated
 

Answer:Excel Auto Email Code ?

16 more replies
Relevance 64.37%

Hi guys,
I have a list of some certifications and their respective expiry dates written in Excel sheet. What I want is to be getting Auto reminder few days before, on and after the expiration date.
Attached is the VBA program that I tired to use but it was reading the whole data instead of being selective. Also attached is an extract of the excel sheet.
Pls I will appreciate any help
Thanks,
CJ
 

Answer:Auto Email reminder from Excel

Have you read the Thread under yours -
http://forums.techguy.org/business-applications/856705-automatic-email-excel-based-date.html
 

1 more replies
Relevance 63.55%

Hi everyone,

I have no prior experience with Macro/VBA and would need help in creating an excel spreadsheet where an email reminder would be sent 60 days, 30 days and 7 days respectively if the project is not completed to the email stated in the 6th column with information from its row. If its completed, the checkbox would be checked and no mail will be sent.

The email should look like:

To: <email stated in that row>
Subject: Reminder to complete project within (e.g. 60 days)

Body:
Dear all,
Reminder to complete IN1661234 by 31st Aug 2016.

<personal email signature>

Do I need to create a button where I have to click in order for those reminders to be sent or will it be sent automatically everyday as long as the spreadsheet is opened?

Also, is it possible to create 3 different email template for each reminder days, such as 60 days prior to the deadline, the subject of the email would be First Reminder, 30days would have Second Reminder and 7 days prior would have FINAL REMINDER and a urgent marked on the email?

And how do I change the email where those reminders will be sent from?

Any help with regards to the above would be greatly appreciated. Thank you so much.
 

Answer:Auto Email Reminder from Excel when project is almost due

16 more replies
Relevance 63.55%

Hello folks. Just a general opinion required at the moment, please. I might need to create something to monitor due delivery dates against actual delivery dates. It's pretty easy to use an Excel wbook and conditional formatting to highlight late deliveries, but what I'd like is an automated email sent to a couple of relevant people as soon as an item becomes late. That also might not sound too hard, but what I think might be a problem, is this. Is there a way for this to happen even if the program is not currently open and running? And would this sort of thing be easier to achive in Access or Excel? (Assuming it is possible at all)Thanks

Answer:Excel or Access to auto send email

If the program is not running, then that's it. The only thing I can suggest is that you run the program automatically using Schduled Tasks.

5 more replies
Relevance 63.55%

Hi, I have download a template from http://www.rondebruin.nl/sendmail.htm and make some modification to create a tracking program for own use. Now, I would like to add in some features to my tracking program which hope it will serve better. I have few questions here which would like to seek for the expert support.

Refer to the attachment:
1. How could I make the email to send out the OPEN and OVERDUE items only(excluded the closed items)?
2. I have set the conditional format, it work in the Excel but not work in the email. How could I solve this (It's just shown differently)?

Hope to hear from you soon.
Thanks in advance.

Regards
Ykit
P/S : I am using Excel 2007 and Outlook 2007.
 

Answer:Solved: Excel - Auto Email Problem

16 more replies
Relevance 63.55%

Hello,I sort of got stuck with a very tedious Excel tracker that tracks when people are due for their vaccinations.I know that there are ways to set up formulas in Excel 2007 but I am pretty ignorant in the whole process. I humbly request your help.Here is a gist of my Excel tracker:Column A=Name | Column B=Job Title | Column C=Due DateAnd then the rows fill in accordingly.So, let's say I had this:John Smith | Janitor | 09/15/2010Could I somehow synch those three rows up with my Outlook contacts list and send a formatted email to them? Could I also set it up to CC me?I would want something like, " Hello, if you are seeing this then you are due for your annual vaccination. Please complete your vaccination as soon as possible. Thank you."Thanks for your help.

Answer:Excel Due date tracker-- Auto email when due?

Hi,I can offer some help with formulas.If you have the following arrangement A B C D E F
1 Name Position Vacc. Due Status Rem. sent Vacc. Date
2 Smith J Janitor 15-Sep-10 Due 15-Sep-10
3 Smith K Clerk 10-Sep-10 Done 10-Sep-10 12-Sep-10
You can start by getting a warning when a vaccination is due.In Cell D2 enter this formula:=IF(C2-TODAY()<8,IF(F2="","Due","Done"),"")This tests to see if the due date is 1 week or less away from today's date, using "IF date difference is less than 8 (days)" : IF(C2-TODAY()<8For a longer warning increase the 8 in the formulaThe formula then uses a second IF to see if the vaccination date cell has been completed : IF(F2="","Due","Done"). This returns "Due" if there is nothing in the vaccination date cell, else it returns done.To avoid "Due" showing up when there is no date in cell C2 you can add an extra test for an empty cell:=IF(C2="","",IF(C2-TODAY()<8,IF(F2="","Due","Done"),""))Now to improve the visibility of vaccinations due, you can use 'Conditional formtting' which changes the appearance of a cell based on values in that (or other) cells.Select cell D2.From the Ribbon select Home - Styles - Conditional Formatting, From the drop down select 'Manage Rules' and select 'New Rule'In the dialog box select the last item in the list 'Use a formula to determine which cells to format'Enter this formula in the box =IF(D2="Due",TRUE,FALSE)Note that TRUE and FALSE do not have double quotes - they are Excel's logical values true and fa... Read more

2 more replies
Relevance 63.55%

Hi,

New here. I dug up a thread that Zack Barresse solved many years ago. I am looking to do the exact same thing. The link to the thread is below. My file is infinitely more complicated than what that user was asking for so I need a bit more help tuning the VBA. Link: http://forums.techguy.org/business-applications/710581-automatic-email-alerts-using-excel.html

Some specifics:

- I am using Outlook not Express
- Excel 2007
- All the functionality is complete for monitoring several live streams of securities data with several trade indicators.
- It is consolidated onto one sheet for manual monitoring (Picture below). Basically takes copious amounts of data and reduces it to just IF and AND functionality for the triggers for easy use from all the other sheets.
- The workbook will be open and running/refreshing on its own 24/7 as it is now.

I am a busy guy, I just need the VBA to automatically email me remotely when any of the 7 currency pairs causes a trigger when I am on the go. I can log trades from an app on my phone.

One other hurdle would be that if say (Using percentages to keep it simple) that a trigger would be if something reached as high as 80% to send the notification email. But where the system refreshes every 60 seconds it shouldn't send another notification each time it remains at or above 80%. Just the once. It may remain there for hours and that is a lot of emails.


Thoughts? and many many thanks in advance.
 

Answer:Excel - Auto Email based on cell value

10 more replies
Relevance 63.55%

Firstly Hi,
I'm Hodge and this is my first post on this forum, please (HELP)

I have been looking around the various forum's trying to figure this out myself but with little success. There are many variants of this problem throughout these forums with many solutions, but none of which i've been able to adapt or use.

I basically run a diving team with 27+ divers and have various spread sheets to manage the team, from equipment servicing to personnel run out dates. I have been trying to find/create a Macro that will automatically send me an email, with Cc's option, when cells in column M & O turn yellow or red. Then copy all the data within that row and email the address in column P as an attachment. I have looked at Ron de Bruin's code, and tried to adapt it without success. Once I have the correct code, I believe i will be able to adapt it to most, if not all of my spreadsheets.

Hopefully someone has used this type of code before for the same reasons, Sorry must mention that I'm working on MS Office For Mac 2011, but don't think the process is much different. I don't really know much about VBA, so any help will be welcomed.

I've attached one of my spreadsheets just incase.

Thanks in advance for any help you may be able to offer.

Hodgey
 

Answer:Solved: Auto Generated Email in Excel

16 more replies
Relevance 63.55%

Hi Guys,

I have just joined this forum, I found some solutions given by Zack quite useful to me. Thank you so much.

But also need help in taking it further, as I have created a worksheet with lots of data which will have to be incorporated while sending auto email reminders to various admin officers depending on the dates, especially for Statutary payments like Telephone, Electricity etc.

If any body can help....... Please...............
 

Answer:Auto Email reminder from Excel Sheet

http://forums.techguy.org/business-applications/773873-how-make-excel-send-email.html
 

1 more replies
Relevance 63.14%

Hi guys,

Really need your assistance ..
Attached is example for my problem.

I only know how to set the parameter for the 'status' (using condiitonal formatting), but i dont know how to create the code in VBA to create emails on certain condition .. I'm not used to VBA, and still learn about it (my head was spinning lately).

So, I wish someone here could help me ..

Regards.
 

Answer:Solved: auto email based on certain condition in excel

16 more replies
Relevance 63.14%

Hi Guys,

We create basic spreadsheets to keep track of tasks and reviews. Often spreadsheets have different formats with one thing in common. Each will have a due date.

I would like be able to create Macro / VBA to send email and/or task for due dates in multiple excel sheets.
Using MS EXCEL2007 and OUTLOOK 2007
Reminder to be sent at trigger event dates 14 days,7 days, 2 days before due and every day overdue
Due dates could get color coded as they approached deadline. For e.g Over 14 days (nil), 14 days (green), 7 Days (orange), 2 days/ overdue (Red).
Due dates could be always put in column A for example for simplicity and consistency if necessary or perhaps it could work of Column heading (DATE DUE).
Also for simplicity emails would only need to go to 2 people. From there we can forward to relevant people after being aware of task ourselves.
When multiple trigger events occur within same Spreadsheet, Have the one email rather than 20 if twenty occur on same day. Different spreadsheets emails are fine.
A check that if email has been sent it will not send another email till next date trigger event.
A 'Send Email' button for all trigger events and another Send selected email' button for one or more selected rows only.
Text in subject line email could be Excel file name
Text in body of email would include Excel file name and Title row and trigger event row.
Unfortunately i have limited experience with Macro's / VBA. Have checked forum... Read more

Answer:General auto-email deadlines: excel - Outlook

There are quiet a lot of posts with similar quetions, maybe you should take a look at these.
When you open your thread you can see the list of 'similar threads' below.
 

1 more replies
Relevance 63.14%

Hello Everyone,

I am a beginner at using vba and I am trying to use excel to send an email automatically before 5 days of due date. I have a an excel sheet of bank loan repayment but every loan due at a different date.

If possible i would like to use an email template that excel would place the values specific payment details and their due date and then send the email to the email address on the specific cell.

I have attached my excel sheet format for your referance.
Thank you so much in advanced

Regards,
Nilesh Jagtap
 

Answer:Excel - Trigger Auto Email Depending on Due Date

Welcome to TSG niljag!

Working on one of these right now at this TSG thread . Practice1.xls in Post #4 is lastest. See if you can adapt to similar. I didn't look at your attachment.

There are many of these(excel emailers) in TSG. Search "excel email" and find one you like. When you get to an issue let us know and we'll try and help.
 

1 more replies
Relevance 63.14%

I've read the previous post with the same issue, but I'm unable to understand how to use the other codes posted within my product. I would like to send an email based on a date. I will attach my document so it is easier for me to explain the requirement. Columns L37-L45 have due dates - I would like the email to be sent 60 days prior. I have posted some mock emails in R37-R45 and the email message in the EMAIL workbook tab. Any assistance would be greatly appreciated.

Thank you so much!
 

Answer:Auto send an email based on date in Excel

Welcome to the board.
I've had to save it as 2003 version but the code works under 2007

See attached my copy of your sheet with the code in ThisWorksheet module.

This just a simple way of doing it and you will have to edit it for your needs but maybe it can put you on the right track.
 

2 more replies
Relevance 63.14%

Hello Everyone,

I am a beginner at using vba and I am trying to use excel to send an email automatically depending on a past due date. I have a an excel sheet that has over 200 companies and we require an annual report but everyone report is due at a different date. I am using conditional formating to change the color of the text depending on how long it has been since we have received the last report. If the last report is 366 days since it has been submitted then I would like an automatic email to be sent.
For conditional formatting i used this "=(TODAY()-365)"

For email i am using;

Sub Send_Email_Using_VBA()
Dim Email_Subject, Email_Send_From, Email_Send_To, _
Email_Cc, Email_Bcc, Email_Body As String
Dim Mail_Object, Mail_Single As Variant
Email_Subject = "Trying to send email using VBA"
Email_Send_From = "[email protected]"
Email_Send_To = "[email protected]"
Email_Cc = "[email protected]"
Email_Bcc = ""
Email_Body = "Your annual report is Due"
On Error GoTo debugs
Set Mail_Object = CreateObject("Outlook.Application")
Set Mail_Single = Mail_Object.CreateItem(0)
With Mail_Single
.Subject = Email_Subject
.To = Email_Send_To
.cc = Email_Cc
.BCC = Email_Bcc
.Body = Email_Body
.send
End With
debugs:
If Err.Description <> "" Then MsgBox Err.Description
End Sub

If possible i would like to use an email template that excel would place the values specific to the co... Read more

Answer:Excel - Trigger Auto Email Depending on Date

Hi welcome to the forum.

You already have the send_email_using_vba, weel you will need something that checks all the cells where the due date is x days old and call this macro

Sub CheckSomething()

<< here you will have to put the code that checks each rows in the
<< date column and if the condition is met then call the send email macro

End Sub

Since I have no idea of your sheet's layout you will have to do your own homework

I suggest you also tell us what version of Excel you're using,
 

1 more replies
Relevance 62.32%

Hey everyone,

I'm trying to stretch my resources and minimize some data entry, using the tools at hand. However, I've hit a bit of a wall on inspiration - looking for some ideas.

I have an Excel Spreadsheet (about 8 worksheets) that I use to log some daily activities - however, because I have a lousy memory, I like to email myself from the road with the notes for my Log. Then, when I return to the office, I either re-type (or copy/paste) my email notes into the appropriate sections of my log file.

What I'd LIKE to do is create a form and rule in Outlook that would auto-fill my Excel worksheets based on the text of my email. I'm not worried about Triggers (the rules setup on that end is simple enough for me), I'm more looking for the best way to have Outlook interact with Excel in this way.

I send emails from the road on my Android phone.

Any ideas? Thanks!
 

Answer:Solved: Outlook Email to Auto-Fill Excel spreadsheet

8 more replies
Relevance 62.32%

Hello Friends,I am leading the finance team. I need to create an excel worksheet which tracks all my invoices raised on different clients alongwith the due dates. I want excel to send an auto email to client after 2 days of due date and second reminder after 7 days or so.I am from finance back ground and thus do not have any idea of running any codes or macros.Can any body help me with this on priority basis?Thanks and regards,Manish

Answer:Excel worksheet to send auto email reminder to clients

Try here:http://www.rondebruin.nl/sendmail.htmLook under the section: Add-ins and Worksheet TemplatesMIKEhttp://www.skeptic.com/

2 more replies
Relevance 59.04%

I am using the MSN Stock Quote addin with MS Excel 2003. Prior knowledge of this should not be necessary, but I just thought I'd provide full context to my issue. I wrote a macro that essentially records daily stock prices. Because I don't want to store old quotes into perpetuity, i need to ensure that the update quotes button has been hit. I use sendkey() to accomplish this, and then the macro copies the quotes and pastes them elsewhere. My main goal is to have the task scheduler open this file daily so i dont ever have to think about this again, and i'm so close. Essentially my problem is that it takes a few seconds after the update button is hit for the add-in to fetch the new prices from the internet, and this process appears to be delayed until the macro is finished. This is a problem because the macro ends up recording un-updated quotes. I have tried the Application.Wait procedure, and I've tried time consuming loops, do while loops, etc. All of these approaches result in the same thing: Can someone please help me with this? I'm too lazy to hand update this spreadsheet every trading day for the rest of my life (or until i quit). Thank you in advance!
 

Answer:Excel Macro - Allow cells to update query before macro completes

Can't you just put the update macro code in a module of it's own and call it from the main macro?

Regards,
Rollin
 

1 more replies
Relevance 55.35%

Hi, I'm new to this forum (actually forums in general) I was wondering if anyone could help me with a macro code. I work with 4 Excel sheets for my shippments, 2 sets for one plant and 2 for the other but all within the same file.

What I am trying to do is set up a macro that will automatically search for changes within sheet 1 (also for sheet 3, the other plant) When I change the rows color from blank to green/red, I need the macro to automatically cut that whole row and paste it into sheet 2 on the next blank row.

This doesn't seem like it would be that hard to do, but I know know the whole macro language.

If you can answer this please send me an email to soulblazor(@)hotmail.com

Thank you for your help.

More replies
Relevance 54.94%

I am trying to create a code that will autofilter data on an Excel worksheet. The code works fine to filter the data, but it does not hide the AutoFilter Arrows.

Below is the code I am using. What (if anything) is wrong with the code below?
Code:

ActiveSheet.Range("A1:D500").AutoFilter Field:=2, Criteria1:="<>", Visibledropdown:=False
 

Answer:Solved: Excel 2007 Macro -> Hide Excel AutoFilter Arrows

I noticed that the code above (in Post #1) that the AutoFilter Arrows were beinf truned off on Field 2, but none of the others.

I have played around, and done some research to come up with the code below:
Code:

Dim c As Range

For Each c In ActiveSheet.Range("A1:D1")
ActiveSheet.Range("A1:D500").AutoFilter Field:=2, Criteria1:="<>"
c.AutoFilter Field:=c.Column, Visibledropdown:=False
Next

Does anyone have a better solution?
 

1 more replies
Relevance 54.94%

Hi,

I was wondering if anyone could help me. I need to extract data from multiple excel files into a new excel file and sum the values. The data comes from excel files that are made from a template so the data is always in the same place or same cells. For example, i have data saved daily in excel files with the following naming convention 080204, 080304, 080404,..... and so on. What i would like to do is have a macro that will create a week ending sheet by importing and summing the data from that week.

Thanks for reading!
 

Answer:excel macro for copying and pasting data from multiple excel files

thanks for all those who read!!!! let me know if anyone needs the code!
 

1 more replies
Relevance 54.94%

Hello again,

I have a word doc that has a form in it. The form may have any number of fields (boxes) to type text answers into, or be a drop down list to select an answer from. I need an excel macro that extracts all data from the form, but with every five fields starting a new row in excel. So all data from the form will appear within 5 columns in an excel spreadsheet.

field 1 field 2 field 3 field 4 field 5
field 6 field 7 field 8 field 9 field 10
etc

Is that possible? I have had no luck to do it myself.

Sample form attached, thank you
____________________________
 

Answer:Solved: Excel macro to extract Word form data into Excel

7 more replies
Relevance 54.94%

Iím using Windows 7 and I used a macro which worked totally fine under Excel 2003. Now, under Excel 2007 it does not run anymore but displays the following error message:

"Run-time error '445':
Object doesn't support this action.

The function of the macro is to open up all other Excel spreadsheets located in the same folder and copy data out of them into the spreadsheet in which the macro is stored.

When I click on "Debug" the Visual Basic Editor highlights the row which says: Set FilSrch = Application.FileSearch

Can you help me with this? I've searched for a solution for a long time but could not find anything which worked.

The following is the start of the macro code:

Sub UpdateTable()
Dim X As Range, I As Integer, J As Integer, RecNo As Integer, CopyVal As Variant
Dim SourceBk As Worksheet, DestBk As Worksheet, StartRow As Integer, IndRange As Range
Dim ServRange As Range, SrcOpen As Boolean, SourceName As String
Dim FilSrch As Object, MyFilArray() As String

'MsgBox "This function not available in this version.", vbInformation, "Function Not Available"
'Exit Sub
'Sheets("LookUp").[a12] = Now
With Application
.ScreenUpdating = False
.StatusBar = "Counting source files ..."
End With
Set FilSrch = Application.FileSearch
With FilSrch
.NewSearch
.LookIn = ActiveWorkbook.Path
.FileType = msoFileTypeExcelWorkbooks
If .Execute > 0 Then
ReDim MyFilArray(.FoundFiles.Count)
For I = 1 ... Read more

Answer:Solved: Excel 2003 Macro Doesn't Run in Excel 2007 - Help Requested

7 more replies
Relevance 54.94%

Hello,

I need help to create an Excel macro that would

1. ask users to select x number of rows to be copied from one worksheet of one Excel file
2. once users have selected the rows to be copied, then the rows are copied from the one original Excel file into X number of target Excel files

Notes:
the target Excel files are all based on the same template
there is one worksheet in each of the target Excel files

in the target files, the rows should be copied from the first available empty row, going down

Looking forward to your help!

Thanks a lot.
Mzz
 

Answer:Macro needed to copy x number of rows from one Excel file into a batch of Excel files

Hi, welcome to the board.
Not much info there to get the correct picture.
Sample? Of source and template please
And not to forget, what version of Excel are you and the users using?
 

1 more replies
Relevance 54.53%

I'm working on a Bill of Material creation automation project that requires some expertise in VBA, and I have none.
The objective is to run a macro from an excel spreadsheet called "PGE BOM", to do the following:
1) Go to the folder "C:\Documents and Settings\Desktop\Auto Project"
2) Find all the .mdb databases in this folder
3) Find "HistoricalMaterialItemsAll" table in EACH of those databases in step 2, and import the data from the columns listed below into PGE BOM.xls's columns C through G:
DrawingNumber
ItemNumber
Quantity
PgeCode
Description
The following is a VBA code that my friend had written in Excel 2007. Unfortunately I have an older version (2000) and the code does not seem to be compatible with Excel 2000.
Sub ImportAccessData()
Stop
dPath = "C:\Documents and Settings\Desktop\Auto Project\"
sFile = "*.MDB"
strSrch = dPath & sFile
Set TargetWB = Application.ActiveWorkbook
Set TargetWS = TargetWB.ActiveSheet
sRow = 2
bFile = False
If Dir(strSrch) <> "" Then
strFlNm = Dir(strSrch)
bFile = True
End If
Do Until bFile = False
strPath = dPath & strFlNm
Call GetData(strPath)
strFlNm = Dir
If strFlNm = "" Then bFile = False
Loop
End Sub
Sub GetData(fl)
Stop
strSQL = "Select HistoricalMaterialItemsAll.* From HistoricalMaterialItemsAll"
Workbooks.OpenDatabase fl, strSQL, xlCmdTable
Set WB = Application.ActiveWorkbook
Set WS = Applicatio... Read more

Answer:Excel Macro - VBA code to import access data to excel

Hello, and welcome to the board!

When posting code, please use CODE tags, which extremely helps with readability.

Perhaps you could try using the code constant???...
Code:

Option Explicit

Sub ImportAccessData()
Dim dPath As String, sFile As String, strSrch As String
Dim TargetWB As Workbook, TargetWS As Worksheet
Dim sRow As Long, bFile As Boolean, strFlNm As String, strPath As String
dPath = "C:\Documents and Settings\Desktop\Auto Project\"
sFile = "*.MDB"
strSrch = dPath & sFile
sRow = 2
bFile = False
Set TargetWB = Application.ActiveWorkbook
Set TargetWS = TargetWB.ActiveSheet
If Dir(strSrch) <> "" Then
strFlNm = Dir(strSrch)
bFile = True
End If
Do Until bFile = False
strPath = dPath & strFlNm
Call GetData(strPath, TargetWB, TargetWS)
strFlNm = Dir()
If strFlNm = "" Then bFile = False
Loop
End Sub

Sub GetData(fl As String, WB As Workbook, ws As Worksheet)
Dim strSQL As String, iRow As Long, sRow As Long
strSQL = "SELECT HistoricalMaterialItemsAll.* FROM HistoricalMaterialItemsAll"
Workbooks.OpenDatabase fl, strSQL, 3 'xlCmdTable
iRow = 2
Do Until ws.Cells(iRow, 1) = ""
ws.Cells(sRow, 7) = ws.Cells(iRow, 5) 'Get the Description
iRow = iRow + 1
sRow = sRow + 1
Loop
Application.DisplayAlerts = False
WB.... Read more

1 more replies
Relevance 54.53%

Hi,
I want to merge two excel files into a 3rd one.

The data are in the files Book1, Book2 and the result in Book3.

I know that i can use VLookup to do the above. But what i have pasted is just an example. The real excel files contains about 9 columns with at many repeating row!!!

Any help will be much appreciated.
Thx
 

Answer:Excel - macro to merge 2 excel files using a common column

Hi welcome to the board. How are you going to treat the duble items, If you want to merge 2 files adn duplication occurs here must be one cell whihc is common to let's say Book1 and Book2.

Do you have a common value? Index? Whatever you call it?
 

3 more replies
Relevance 54.12%

I used a macro which worked totally fine under Excel 2003. Now, under Excel 2007 it does not run anymore but displays the following error message:"Run-time error '445':Object doesn't support this action.The function of the macro is to open up all other Excel spreadsheets located in the same folder and copy data out of them into the spreadsheet in which the macro is stored.When I click on "Debug" the Visual Basic Editor highlights the row which says: Set FilSrch = Application.FileSearchCan you help me with this? I've searched for a solution for a long time but could not find anything which worked.The following is the start of the macro code:Sub UpdateTable()Dim X As Range, I As Integer, J As Integer, RecNo As Integer, CopyVal As VariantDim SourceBk As Worksheet, DestBk As Worksheet, StartRow As Integer, IndRange As RangeDim ServRange As Range, SrcOpen As Boolean, SourceName As StringDim FilSrch As Object, MyFilArray() As String'MsgBox "This function not available in this version.", vbInformation, "Function Not Available"'Exit Sub'Sheets("LookUp").[a12] = NowWith Application .ScreenUpdating = False .StatusBar = "Counting source files ..."End WithSet FilSrch = Application.FileSearchWith FilSrch .NewSearch .LookIn = ActiveWorkbook.Path .FileType = msoFileTypeExcelWorkbooks If .Execute > 0 Then ReDim MyFilArray(.FoundFiles.Count) For I = 1 To .FoundFiles.Count If .FoundFiles(I) <> ActiveWorkbook.Path & "\" & ActiveWorkbook.Name Then ... Read more

Answer:Excel 2003 Macro doesn't run under Excel 2007

As far as I know, Application.FileSearch is not available in 2007. Searching for filesearch replacement turns up lots of hits with various workarounds, such as this:http://groups.google.com/group/micr...Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

2 more replies
Relevance 54.12%

Hi guys,

I have been on the lookout for a macro that will compare 2 worksheets within MS Excel and output the differences on a third sheet.

I am being directed to the URL below but cannot for the life of me work out how to implement this:

http://exceltip.com/st/Compare_two_worksheets_using_VBA_in_Microsoft_Excel/477.html

There are two snippets of code which I will include here for convenience but not sure whether these should be pasted into Workbook Code (i.e. right-clicking Excel icon left of "File" - top-left), Worksheet Code (i.e. right-clicking worksheet tab) or inserting a new Module - or some other method. Is there anyone here that could guide me to how to implement this code?

Quote from webpage - "With the macro below it is possible to compare the content of two worksheets.
The result is displayed in a new workbook listing all cell differences. "

Code:
Sub CompareWorksheets(ws1 As Worksheet, ws2 As Worksheet)
Dim r As Long, c As Integer
Dim lr1 As Long, lr2 As Long, lc1 As Integer, lc2 As Integer
Dim maxR As Long, maxC As Integer, cf1 As String, cf2 As String
Dim rptWB As Workbook, DiffCount As Long
Application.ScreenUpdating = False
Application.StatusBar = "Creating the report..."
Set rptWB = Workbooks.Add
Application.DisplayAlerts = False
While Worksheets.Count > 1
Worksheets(2).Delete
Wend
Application.DisplayAlerts = True
With ws1.UsedRange
lr1 = .Rows.Count
lc1 = .Column... Read more

Answer:Solved: How to use this Macro in MS Excel (compare excel worksheets)

Apologies... I have sorted this... For those that might be looking at this for help here's what I missed:

These are both Sub's that should be created as a Module - both in the same module. I am just comparing worksheets within the Active Worksheet so just removed:

' compare two different worksheets in two different workbooks
CompareWorksheets ActiveWorkbook.Worksheets("Sheet1"), _
Workbooks("WorkBookName.xls").Worksheets("Sheet2")
Click to expand...

I was then able to run this from Macro's. All sorted.

Apologies again
 

1 more replies
Relevance 54.12%

Does anyone know how to run Excel 2003 print macro on Excel 2007 or higher? When I tried running my 2003 macro, the VBA editor pops up w dialogue box, " Run-time error '1004': Method 'ActivePrinter' of object'_Application' failed ".

This is my code: Application.ActivePrinter = "Epson LQ-300 ESC/P 2 on USB003"

Can anyone help?

Thanks!
 

Answer:How to run Excel 2003 print macro on Excel 2007?

Welcome to TSG hope we can help you and you can help others.

I'm not an Excel macro guy but you code looks reasonable. What happens if you run this. I suspect printer name is a little off.

MsgBox "The name of the active printer is " & Application.ActivePrinter
 

1 more replies
Relevance 54.12%

Hi, I have created an excel macro that runs sensitivities in my model. The excel button runs 5 different cases.

The macro runs fine and does as I want it to.

Once the macro has run, and I go to edit a cell and hit "F2" excel crashes. This only seems to happen in certain cells and not all of the time.

Does anyone have experience with similar questions?

Thanks
 

Answer:Excel Macro runs fine..then excel crashes

11 more replies
Relevance 54.12%

With due respect and credit to DerbyDad03 whose earlier post gave me the code below; is there any way to have the new worksheets created from a variable length field e.g. a persons name in a list or a field of fixed length other than a date as the script below uses?Sub CreateMonthlySheets()Dim lastRow, mMonth, tstDate1, tstDate2, shtName, nxtRowOn Error Resume Next'Turn off ScreenUpdatingApplication.ScreenUpdating = False'Make a copy of the data sheet and sort by date Sheets("Sheet1").Copy After:=Sheets(1) Sheets(2).Name = "SortTemp" With Sheets("SortTemp") lastRow = .Cells(Rows.Count, 1).End(xlUp).Row Rows("2:" & lastRow).Sort Key1:=Range("A2"), Order1:=xlAscending 'Using SortTemp Sheet, create monthly sheets by'testing Month and Year values in Column A'Loop through dates For Each mMonth In .Range("A2:A" & lastRow) tstDate1 = Month(mMonth) & Year(mMonth) tstDate2 = Month(mMonth.Offset(-1, 0)) & Year(mMonth.Offset(-1, 0)) 'If Month and Year are different than cell above, create new sheet If tstDate1 <> tstDate2 Then ActiveWorkbook.Sheets.Add After:=Worksheets(Worksheets.Count) 'Name the sheet based on the Month and Year ActiveSheet.Name = MonthName(Month(mMonth)) & " " & Year(mMonth)'Copy Column Widths and Header Row .Rows(1).Copy ActiveSheet.Rows(1).PasteSpecial Paste:=8 'ColumnWidth ActiveSheet.Rows(1).PasteSpecial 'Data... Read more

Answer:Excel Macro to create new worksheet in Excel 2010

I created a quick macro to help you out. This macro creates a new sheet and names it using the contents of cell "A1".Sub CreateNewSheet()
Dim NewSheet
Dim SheetName As String

SheetName = Worksheets("Sheet1").Cells(1, "A").Value
Set NewSheet = Sheets.Add(After:=Sheets(Worksheets.Count), Count:=1, Type:=xlWorksheet)
NewSheet.Name = SheetName

End Sub
Law if Logical Argument: Anything is possible if you don't know what you're talking about.

4 more replies
Relevance 54.12%

I run a weekly excel 2007 macro that converts a spreadsheet to a Word document, but it stops after row 29 of data. Any spreadsheet with 29 rows or less works fine. If I have 34 rows of data, the macro hangs. See below for script. Any help would be appreciated.

Public Sub AddControls(WrdApp As Word.Application, CurRow As Integer)
Dim OptChecked As Boolean
Dim GrpName As String
GrpName = "Grp" & CurRow
'Calculate the colors based on the cell information.
CurRange = "F" & CurRow & ".." & "F" & CurRow
Range(CurRange).Select

If InStr(1, UCase(ActiveCell.Text), "X SRM") > 0 Then 'SRM
OptChecked = True
Else
OptChecked = False
End If

SetCellBG WrdApp, True
WrdApp.Selection.TypeText Text:="Governance:" & vbCrLf

Set RadioObj = WrdApp.Selection.InlineShapes.AddOLEControl("Forms.OptionButton.1")
With RadioObj.OLEFormat.Object
.GroupName = GrpName
.Caption = "SRM"
.Font.Name = "Arial"
.Font.Size = 8
.Value = OptChecked
End With

If InStr(1, UCase(ActiveCell.Text), "X PPO") > 0 Then ' PPO
OptChecked = True
Else
OptChecked = False
End If

WrdApp.Selection.Collapse Direction:=wdCollapseEnd
WrdApp.Selection.TypeParagraph

Set RadioObj = WrdApp.Selection.InlineShapes.AddOLEControl("Forms.OptionButton.1")
With RadioObj.OLEFormat.Object
.GroupName = GrpName
.Caption = "PPO"
.Font.Name = "Arial"
.Font.Size = 8
.Value = O... Read more

Answer:Excel Macro - converting excel to word doc - stops after row 29

13 more replies
Relevance 53.71%

Hello, I'm just joined and am trying to create a macro that will automatically email an entire workbook to a list of individuals. I also want the macro to copy and paste a range of cells within a specific sheet in the workbook and paste it into the body of the email. I am able to email the workbook but can't figure out the second part. Any help would be appreciated.

I am using Excell 2007 and LotusNotes 8.5.1
 

Answer:Macro to email centain range in body of email as well as the whole workbook

Hi, welcome to the forum.
There are several posts where I added some simple tips and tricks.
Do you have the macro you use now to mail the whole workbook?
If I see how you have done this then maybe it's a cinch to add the extra info
You may also post a workbook with fictious data if you wish
 

1 more replies
Relevance 53.71%

I have a word document that includes a form the user must fill in. I want to create a button that will do all of the following:
1. Update all fields
2. Attach the updated word document to an email
3. Enter an address I have stored in the macro into the To field of the email.

I have one module which does the first part:
Sub CommandButton1_Click()
Dim oStory As Range
For Each oStory In ActiveDocument.StoryRanges
oStory.Fields.Update
If oStory.StoryType <> wdMainTextStory Then
While Not (oStory.NextStoryRange Is Nothing)
Set oStory = oStory.NextStoryRange
oStory.Fields.Update
Wend
End If
Next oStory
Set oStory = Nothing
End Sub

I found that if I add this to the before End Sub it attaches the updated Word document to an email:
Application.Options.SendMailAttach = True 'Or False
ActiveDocument.SendMail

However, I can't figure out how have it put a specific address into the To field of the document.

So I tried another tact. I have the email address as a hyperlink in the document, and set a bookmark at the hyperlink. Then I created a module that will go to the bookmark and open the hyperlink. However, this will not add the document as an attachment:

Sub Open_Hyperlink()
Selection.GoTo What:=wdGoToBookmark, Name:="hyperlink"
With ActiveDocument.Bookmarks
.DefaultSorting = wdSortByName
.ShowHidden = False
End With

Selection.Range.Hyperlinks(1).Follow NewWindow:=False, AddHistory:=True
End Sub

So then I found this bit of coding on the web, and tried imp... Read more

Answer:Word Macro to attach doc to email, then send address email

I found a solution, but I think it is a bit bulky. It seems to work but I'd love to know if there is a simpler solution:
Sub CommandButton1_Click()
Dim oStory As Range
For Each oStory In ActiveDocument.StoryRanges
oStory.Fields.Update
If oStory.StoryType <> wdMainTextStory Then
While Not (oStory.NextStoryRange Is Nothing)
Set oStory = oStory.NextStoryRange
oStory.Fields.Update
Wend
End If
Next oStory
Set oStory = Nothing

ActiveDocument.Save

MsgBox "Thank you. Your order has been sent", vbOKOnly, "Thank you. Your order has been sent"
Dim bStarted As Boolean
Dim oOutlookApp As Outlook.Application
Dim oItem As Outlook.MailItem
On Error Resume Next
If Len(ActiveDocument.Path) = 0 Then 'Document has not been saved
ActiveDocument.Save 'so save it
End If
Set oOutlookApp = GetObject(, "Outlook.Application")
If Err <> 0 Then 'Outlook isn't running
Set oOutlookApp = CreateObject("Outlook.Application")
bStarted = True
End If

Set oItem = oOutlookApp.CreateItem(olMailItem)
With oItem
.To = "[email protected]"
.Subject = "Promo Order" '
.Body = "Thank you for your order"
.Attachments.Add Source:=ActiveDocument.FullName, Type:=olByValue
.Send
'**********************************

End With
If bStarted Then 'If the macro started Outlook, stop it again.
oOutlookApp.Quit
End If
Set oItem = Nothing
Set oOutlookApp = Nothing
End Sub
 

1 more replies
Relevance 53.3%

I have an equation that I need help with putting into an excel Macro. The equation is as follows:
=IF(AND(ISBLANK(E2),ISNA(F2)),"XXXXXX",IF(AND(ISBLANK(E2),ISNUMBER(F2)),"ASSIGN LAN ID",IF(AND(E2="XXXXXX",ISNUMBER(F2)),"ASSIGN LAN ID",IF(AND(E2="XXXXXX",ISNA(F2)),E2,IF(AND(OR(ISBLANK(E2)="FALSE",E2<>"000000",E2<>"111111",E2<>"999999",E2<>"IOIOIO",E2<>"XXXXXX"),OR(ISNUMBER(F2),ISNA(F2))),E2,"No Criteria Met")))))

I need this put into a macro as either an if then else statement or a case statement. If anyone could help me out i would appreciate it
 

Answer:Excel Equation converted to an excel macro

Not sure if this will work for you or not, untested...
Code:
dim e as range, f as range, c as range
set e = range("E2"): set f = range("F2"): set c = activecell
if e = "" and worksheetfunction.isna(f) then
c.value = "XXXXXX"
elseif e = "" and isnumeric(f.value) then
c.value = "AS SIGN LAN ID"
elseif e = "XXXXXX" and isnumeric(f.value) then
c.value = "ASSIGN LAN ID"
elseif e = "XXXXXX" and worksheetfunction.isna(f) then
c.value = e.value
elseif (e <> "" or e <> "0000 00" or e <> "111111" or e <> "999999" or e <> "IOIOIO" or e <> "XXXXXX") and (isnumeric(f) or worksheetfunction.isna(f)) then
c.value = e.value
else
c.value = "No Criteria Met"
end if
HTH
 

3 more replies
Relevance 53.3%

Excel '07 won't open an "excel 4.0" macro (i.e. *.xlm file). I am one of a few users at work using excel 2007, I believe this file was made with excel 2000 or similar. When I had excel 2000 it opened fine, it's a common file on the network that everyone should be able to access, and everyone with excel 2000 can easily. So I know it's not the file. When I try and open it with excel 2007 I get that stupid error about the file being different to the extension.

I've tried registry edits and workarounds after scowering the net but nothing seems to fix it. All it does is display the error, then opens excel in the background without even a new worksheet. Excel isn't hanging, it just does nothing. Any ideas?
 

Answer:excel 2007 won't open excel 4.0 macro

XLM was long ago replaced by VBA (with Excel 5 in 1993) and MS no longer really supports it (although I think they claim that they do, kinda, sorta.) So the only thing you can do, I think, is to make a copy of the xlm file and convert the xlm code in the copied file to VBA. Fortunately, I found a link that tells you how to do that:
http://blogs.msdn.com/b/excel/archive/2010/02/16/migrating-excel-4-macros-to-vba.aspx
(Look at the link at the bottom, too. But you will need to download that to an older PC, possibly.)
Now, assuming all goes well, this will give you two versions of the same file, but if everyone else has Excel 2000 (or later) then they will all be able to use the new VBA-based file, so you won't end up with two files that would lead to confusion.
Still, it looks to be a lot of work, so good luck!

On a final note, if you need this file done in VBA and you can't figure out how to redo it, make a post describing your needs - there are some amazing VBA coders on here.
 

1 more replies
Relevance 53.3%

A macro I wrote in VBA for Excel 2004 won't run in Excel 2011 (alas...). Upon opening the spreadsheet an "on open" routine runs, and bombs out on the following command:
Code:
Set cmdbar = Application.CommandBars.Add _
(Name:="Sort", _
Position:=msoBarTop, _
MenuBar:=False, _
temporary:=True) 'msobartop docks the menu at the top

Does anyone know if the VBA structure ("CommandBars.Add") has been removed or altered?

Is there another way to accomplish the same thing in 2011? I want to create a custom command bar (I populate it later in the module).
 

More replies
Relevance 53.3%

Does anyone know the best way to setup a Macro in Excel 2007 that will work in Excel 2003 as well?

I have an Excel 2007 workbook that I am using a macro to change the "Fill Color" and "Font Color" of cells. However, I will get everything working in Excel 2007, but when I open the workook in Excel 2003 I get many debug errors.

If I change the code in Excel 2003, and then re-open in Excel 2007 I get debug errors.

There must be a way to setup teh workbook to work on both Excel 2007 & 2003.
 

More replies
Relevance 52.48%

How do I auto start a macro when I open an excel file?
 

Answer:How do I Auto Start a Macro

Unless it's signed / fully trusted..... you can't.
You can code it to but Microsoft have applied security features to prevent it.
It's a big vulnability.
 

5 more replies
Relevance 52.48%

Hi, any VB gurus know how to get this script to work automatically each time I compose new, reply, and forward messages in Outlook 2003?

Code:

Public Sub MyMacro()
Dim Mail as Outlook.MailItem

Set Mail=Application.ActiveInspector.CurrentItem
Mail.BCC = "your address here"
End sub


Thanks.
 

Answer:Auto BCC in Outlook macro

Hello admin types. I moved this thread to business apps to see if I could get more macro gurus to comment. You can delete this one.

Cheers!
 

1 more replies
Relevance 52.48%

Hi,is there a way in macro wherein if a certain cell has value, the other cells will be automatically populated?Example:In cell E6 I put the date, then the values in cell A4, B4, C4 and D4 will be automatically copied to A6, B6,C6 and D6. Same goes when I enter the date on cell E7, the values in cell A4, B4, C4 and D4 will be automatically copied to A7, B7,C7 and D7 so on and so forth...Thank you so much in advance.

Answer:Auto Copy using macro

You can do it with IF functions:In A6 enter this formula:=IF($E6<>"", A4, "")Drag it across to D6.Then edit each cell, highlighting the A4, B4, etc and press the F4 function key to get: =IF($E6<>"", $A$4, ""), =IF($E6<>"", $B$4, ""), etc.Now select A6:D6 and drag the formulas down as far as you need them.Posting Tip: Before posting Data or VBA Code, read this How-To.

13 more replies
Relevance 52.07%

Dear Guyz

I have a macro helped and developed by a respected admin of this group

it has following statement

If Cells(lRow, "N").Value >= 5 And Len(Trim(Cells(lRow, "P").Value)) > 0 Then ' check if the months passed are >= 5 (same as the red conditional formatting)
If Len(Trim(Cells(lRow, "O").Value)) = 0 Or (IsDate(Cells(lRow, "O").Value) = True And Month(Cells(lRow, "O").Value) <> Month(Date)) Then
toList = Cells(lRow, "P") 'gets the recipient's email address Column O

I want to add another line from another macro

If cell.Value Like "?*@?*.?*" And _
LCase(Cells(cell.Row, "C").Value) = "yes" Then

which makes sure that only @ emails are there and also ensures to which person it has to email and which it has avoid.

Can anybody help me to sort out this especially @Keebellah
 

Answer:Yes for Email No for no Email Condition in an if Statement of macro

7 more replies
Relevance 52.07%

Hi, any VB gurus know how to get this script to work automatically each time I compose new, reply, and forward messages in Outlook 2003? I know this is not necessarily the Outlook forum but I know there are more macro masters in here!

Code:
Public Sub MyMacro()
Dim Mail as Outlook.MailItem

Set Mail=Application.ActiveInspector.CurrentItem
Mail.BCC = "your address here"
End sub
As it is now this will run but only when I go to tools, macros, run, etc. too tedious.

Thanks.
 

Answer:Outlook 2003 Auto BCC macro

Bump - can this not be done?
 

1 more replies
Relevance 52.07%

I am creating a form in Microsoft Word 2003. There is an area that requests a physical company information, including; Address:City, State, Zip:Phone:Fax: Primary Contact:Email:I would like to make it so that when a box labeled 'same as physical address' is checked that the information that has been entered will autofill to corresponding fields labeled Billing Information, with the following fields:Address:City, State, Zip:Phone:Fax: Primary Contact:Email:Can anyone help me with this?

Answer:Writing an Auto Fill Macro

Hi,When you fill out the initial company information and address, what identifies where each piece of information is. Is it identified by it's location in a table in Word, or is the information in named fields.What is the 'same as physical address' box - what type of object is it?RegardsRegards

4 more replies
Relevance 52.07%

I'm a bit new to macros and my boss is looking for a macro to auto import from a xls file automacitcally generated every 2 hours. I want to import this data, make a pivot table, and have it automatically update every 2 hours without having to open the generated file everytime. is this possible?

thanks!
 

More replies
Relevance 52.07%

Hello All....
i'm newbie in programming..i have a question how to develop a program / macro vba in excel.
so, i have a data in sheet1, e.g :

Information Engineering
Industrial Engineering

and then, in sheet2 will be automatically created a text in column A

Informatics Engineering Smt 1
Informatics Engineering Smt 2
Informatics Engineering Smt 3
Informatics Engineering Smt 4
Informatics Engineering Smt 5
Informatics Engineering Smt 6
Industrial Engineering Smt 1
Industrial Engineering Smt 2
Industrial Engineering Smt 3
Industrial Engineering Smt 4
Industrial Engineering Smt 5
Industrial Engineering Smt 6

Also in Column B the same data
Informatics Engineering Smt 1
Informatics Engineering Smt 2
Informatics Engineering Smt 3
Informatics Engineering Smt 4
Informatics Engineering Smt 5
Informatics Engineering Smt 6
Industrial Engineering Smt 1
Industrial Engineering Smt 2
Industrial Engineering Smt 3
Industrial Engineering Smt 4
Industrial Engineering Smt 5
Industrial Engineering Smt 6

and ofcourse in i write in sheet1 another data, the sheet2 will automatically ajjust the data same with the data just inserted into sheet1

anyone can help ?
many thanks
 

More replies
Relevance 52.07%

I don't even know what to call this.

I'm looking for some software that will let me set my computer to repeated a set of key strokes indefinitely with a settable variable of time between keystrokes.

Does anyone know of any software like this?
 

Answer:Auto-typer? Repeating key macro?

AutoHotkey will do that. To type in an x the command is Send x. The timing can be done several ways, I usually use the Sleep command. Sleep, 1000 would pause for 1 second.
 

1 more replies
Relevance 51.25%

Hi I am new to this site and would like to send my greetings to all of you. I am new to macro and have never used em before, please help.I need help on making a macro for the following situation. I receive a excel file that have more then 7000 names in cloumn B and i need to filter it to display only a certain name and then save as html format with the name that i just filtered and i have to create a main folder then a sub folder for every single saved file and on top of that i have to put it on the G: server drive.I am sorry for my explanation, please bare with me. all this task is being done manually everyday and is taking much of my time. So i would like to know if there is a way for me to have a macro that auto filter the list and save as htlm every filtered result and create the folders and sub foders with date stamps.Any imput is tremendously appriciated, thank you all in advance.

Answer:Macro to auto filter&save as html

Hi,A few questions for clarification:1.When you say more than 7000 namesIs that 7000 different namesor7000 cells with names - but many are the same.2.If many are the same, approximately how many unique names are present in column B3.If there were say 100 unique names, can you confirm that you want 100 files saved, each in a unique sub-folder named with the appropriate 'filtered' name.4.If each file saved is filtered by a unique name, do you need to save only the data that belongs to that name.5.What row does the data start on. Is there is a header row or rows before the data.6.What is in column A - is it data that also needs to be saved.Regards

18 more replies
Relevance 51.25%

Thank to Humar for his hard work and knowledge he came up with the following macro for me: Option ExplicitSub Parser()'Parsing by regionDim strWkBkName As StringDim rngStart As RangeDim rngEnd As RangeDim rngCell As RangeDim rngDestStart As RangeDim arryNames() As StringDim intArry As IntegerDim blnNotPresent As BooleanDim blnFound As BooleanDim intDestOffst As IntegerDim wkbkNew As WorkbookDim strPath As StringDim strNamePath As StringDim objFSO As ObjectDim n As IntegerOn Error GoTo ErrHndApplication.ScreenUpdating = FalsestrWkBkName = ActiveWorkbook.NameSet rngStart = ActiveSheet.Range("B9")Set rngEnd = ActiveSheet.Range("B" & CStr(Application.Rows.Count)).End(xlUp)Set rngDestStart = Worksheets("Sheet2").Range("A9")strPath = "C:\Users\Documents\test\"intArry = Int(rngEnd.Row / 4)ReDim arryNames(intArry)For Each rngCell In Range(rngStart, rngEnd) blnFound = False blnNotPresent = False For n = 0 To intArry If rngCell.Text = arryNames(n) Then blnFound = True If blnFound = True Then Exit For If arryNames(n) = "" Then blnNotPresent = True If blnNotPresent = True Then Exit For Next n If blnNotPresent = True Then arryNames(n) = rngCell.Text End IfNext rngCellFor n = 0 To intArry If arryNames(n) <> "" Then Worksheets("Sheet2").Cells.Clear Worksheets("Sheet1").Range("1:8").Copy _ Destination:=Worksheets("Sheet2").Range("A1") Worksheets("Sheet1").Rows(1).Copy Worksheets("Sheet2").Ra... Read more

Answer:Macro to auto filter&save as html

Hi for what its worth please don't flame my nobness here is what i have tried .. i was able to filter the column c and save it as folders and html file .. my problem is the main filtering of colum B and saving them as main folder here is my code:Option ExplicitSub neeew1()'Parsing by regionDim strWkBkName As StringDim rngStart As RangeDim rngEnd As RangeDim rng1Start As RangeDim rng1End As RangeDim rngCell As RangeDim rng1Cell As RangeDim rngDestStart As RangeDim arryNames() As StringDim intArry As IntegerDim blnNotPresent As BooleanDim blnFound As BooleanDim intDestOffst As IntegerDim wkbkNew As WorkbookDim strPath As StringDim strNamePath As StringDim objFSO As ObjectDim n As IntegerOn Error GoTo ErrHndApplication.ScreenUpdating = FalsestrWkBkName = ActiveWorkbook.NameSet rngStart = ActiveSheet.Range("B9")Set rngEnd = ActiveSheet.Range("B" & CStr(Application.Rows.Count)).End(xlUp)Set rng1Start = ActiveSheet.Range("C9")Set rng1End = ActiveSheet.Range("C" & CStr(Application.Rows.Count)).End(xlUp)Set rngDestStart = Worksheets("Sheet2").Range("A9")strPath = "C:\Users\bdo\Documents\S-report\region test\test\"intArry = Int(rng1End.Row / 4)ReDim arryNames(intArry)For Each rngCell In Range(rng1Start, rng1End) blnFound = False blnNotPresent = False For n = 0 To intArry If rngCell.Text = arryNames(n) Then blnFound = True If blnFound = True Then Exit For If arryNames(n) = "" Then blnNotPresent = True If blnNotPresent = True Then Exit For Next n ... Read more

2 more replies
Relevance 51.25%

When you enter the date on the spreadsheet and choose the add date to TAB button I get an error. what have done wrong???? THANKS!Sub Tab_Date_2()'' Tab_Date_2 Macro'' Range("M5").Select Selection.Copy Sheets("2-Jan-17").Select Sheets("2-Jan-17").Name = "2-Jan-17" Range("L5").Select Application.CutCopyMode = False ActiveCell.FormulaR1C1 = "DATE" Range("J6:M6").SelectEnd Sub

Answer:What is wrong with this Macro for auto filling date.

Let's start with a posting tip for asking a question in a help forum:Telling us that you "get an error" doesn't give us much to work with. Since we don't know how your spreadsheet or macro environment is set up, we can't really test your code in a manner that might produce the same error.What error are you getting? What instruction is causing the error? Have you tried single stepping through the code to help you determine where the problem might be?That said, I don't understand what the code is supposed to be doing.Issue #1:
Range("M5").Select
Selection.Copy
You copy M5 and then never do anything with the copied value.Issue #2
Sheets("2-Jan-17").Select
Sheets("2-Jan-17").Name = "2-Jan-17"
You Select the sheet named "2-Jan-17" and then you rename it with the same name. What is the reason for doing that?This part seems OK:
Range("L5").Select
Application.CutCopyMode = False
ActiveCell.FormulaR1C1 = "DATE"
Range("J6:M6").SelectOK, you are putting the word "DATE" in 2-Jan-17!L5 and then Selecting the range 2-Jan-17!J6:M6. I guess that makes sense. I wouldn't do it that way, but it gets the job done if that's what you need.Perhaps if we knew what you are trying to accomplish, we could be of more assistance.Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

2 more replies
Relevance 51.25%

I have this macro that I run for my report and it goes and opens other excel files and pulls information from them. The excel files have the same names except everyday i have to change the macro to get the same file name with a variance in the date as shown below.

Code:
Sub Update_Dashboard()
Sheets("Lampe").Visible = True
Sheets("Kay").Visible = True
Sheets("Magoulas").Visible = True
Range("C5").Select
Application.Run "'2007-05 June- EXPO Task Trends Dashboard [COLOR="Red"]0612[/COLOR].xls'!Erase_Data"
Application.Run "'2007-05 June- EXPO Task Trends Dashboard [COLOR="red"]0612[/COLOR].xls'!Magoulas"
Application.CutCopyMode = False
Application.Run "'2007-05 June- EXPO Task Trends Dashboard [COLOR="red"]0612[/COLOR].xls'!Kay"
Application.CutCopyMode = False
Application.Run "'2007-05 June- EXPO Task Trends Dashboard[COLOR="red"] 0612[/COLOR].xls'!Lampe"
Range("C45").Select
Application.CutCopyMode = False
Application.Run _
"'2007-05 June- EXPO Task Trends Dashboard [COLOR="red"]0612[/COLOR].xls'!Atlanta_CSC"
Range("C46").Select
Application.CutCopyMode = False
Application.Run "'2007-05 June- EXPO Task Trends Dashboard [COLOR="red"]0612[/COLOR].xls'!OC_CSC"
Range("A2").Select
Sheets("Lamp... Read more

Answer:Solved: Auto updating Date in Macro

Try something like
Code:
Application.Run "'2007-05 June- EXPO Task Trends Dashboard " & Format(Now, "MM") & Format(Now, "DD") & ".xls'!Erase_Data"
Regards,
Rollin
 

2 more replies
Relevance 51.25%

Hi you all,    I use Word 2000 and Windows XP on my 3 networked machines.    I wrote numerous macros and autocorrects in Word on one machine and would like these settings to be copied to my other machines.    How do I do that ?Thanks,Claude

Answer:Macro and Auto text in Word 2000

Re: macros, open Visual Basic Editor by hitting Alt/F11 (with Word open).  You should see your macros under Modules.  Right click on a macro name there and select Export.  Copy that file to your other computer, open Visual Basic Editor, right click on Modules and import the file(s) exported from the other computer.

1 more replies
Relevance 50.84%

In excel 2010, I entered "=HYPERLINK(VLOOKUP(B3,CTO_DB!A1:B1001,2,0),B3)". How can I make it auto open the file if hyperlink is exist? Thanks

Answer:Auto open word, excel and pdf file in excel

It is a bit complicated, using LOOKUP with HYPERLINK,see here for an explanationhttps://stackoverflow.com/questions...MIKEhttp://www.skeptic.com/

4 more replies
Relevance 50.84%

Im wondering if it is possible to do this before i start trying...

I recieve an email containing an excel sheet containing several peices of info such as:
Name
Surname
ID
Etc Etc... Now when i open this.. i need the information posted into specified columns in a new excel document where it will have
NAME | SURNAME | ID |
-------------------------------------------
STEVE NORTH 01874
Any help given appreciated.
 

Answer:Excel - Auto export data into specified excel sheet

6 more replies
Relevance 50.84%

I have had to reinstall pc due to it going at a crawl!!

After installing Outlook 2002, I can not get Outlook to auto fill the email address field when I start to type an email address in it.

The address book is there and in tacked after copying the outlook.pst file back to its original location after install.

How do I get Outlook to autofill?

Also when I click the 'TO' button in the new email window, it says that there is no address book!
but when I click the address book icon in the main Outlook window there are email address there?!

Any ideas how I can get this to work correctly again.

Answer:reinstalled pc, now create email in Outlook 2002 does not auto fill email address like before

When you did the re-install, did you erase/format the hard drive before the re-install? If you did and did not save the Outlook auto fill file, then the all the auto fills you had are gone. Did you import the pst file into outlook?

1 more replies
Relevance 50.84%

hi there,,when i go to enter my email address in firefox the pop up address is spelled wrong,,,how can i change it,without losing all my auto complete forms.
i am using windows xp home edition..
thanks..
 

Answer:Solved: wrong email spelling in auto complete email address

Delete Firefox auto-complete entries

There is also an add on for firefox that allows you to manage autocomplete

Available features include:

* matching against bookmark addresses
* matching against page titles and bookmark names
* matching anywhere in the address, not just the beginning
* changing the sorting criterion to alphabetical by address or title, most frequently visited, most recently visited, or top-level pages first
* completing the best match inline
* temporarily or permanently disabling the suggestion popup
* excluding local pages and pages containing search results
* swapping the address and title columns on the suggestion popup
* highlighting the column where a match was found
* fine-tuning the popup appearance by hiding page titles, changing the number of visible suggestions, and setting the truncation method for long addresses and page titlesClick to expand...

Autocomplete Manager 2.3
 

3 more replies
Relevance 50.84%

Hello! I have a spreadsheet for event tracking, but there need to be multiple rows/ event so there is one row per participant. Some information needs to remain constant, like the event date, time, etc, but some needs to be tailored to the participant, like type of participant, prep work to be done, etc.However, the problem is that if a "constant" detail were to change, not all the entries would be updated. The macro I had is Sub InsertRow() Dim i As Long Selection.Offset(1, 0).EntireRow.Insert i = Selection.Row Range("A" & i & ":I" & i + 1).FillDownEnd Subwhich worked fine, but I want it to somehow fill with =Rowabove, or be linked somehow. Is this possible?

Answer:Macro to auto fill cells below, but stay connected?

I don't understand what you are trying to do.AFAICT, your code basically inserts one row below the selected cell/row and copies the data from A:I in the row above to the new row.What is it that you want it to do?Click Here Before Posting Data or VBA Code ---> How To Post Data or Code.

5 more replies
Relevance 50.84%

Hello,
I've got three sheets in a workbook. The following macro will work on the first sheet when I open the workbook, but will not work when I switch to either of the other sheets. I've tried by putting the macro in "this workbook", in each sheet, and in all four places. What I want is the macro to freeze row 5 at A5 so I can see the headings and bring up the next clear row to about a third down from the top, where I can enter data. That's what the End(xlUp), etc. and SmallScroll Down, etc. is all about. I randomly picked A300 because it's below any data.

Private Sub Workbook_Open()
Dim ws As Worksheet
For Each ws In Me.Worksheets
Application.Goto Reference:="R1C1"
ActiveCell.Offset(4, 0).Range("A1").Select
ActiveWindow.FreezePanes = True
Application.Goto Reference:="R300C1"
Selection.End(xlUp).Select
ActiveWindow.SmallScroll Down:=6
ActiveCell.Offset(1, 0).Range("A1").Select
Next ws
End Sub

Mike
 

Answer:Solved: auto running a macro when opening a sheet

1. In ThisWorkbook is correct, but you're using the wrong event.

2. I don't know if this can be an "exact science".

Private Sub Workbook_SheetActivate(ByVal Sh As Object)
On Error Resume Next
Range("A5").Select
ActiveWindow.FreezePanes = True
x = Range("A" & Rows.Count).End(xlUp).Row
Range("A" & x + 1).Select
ActiveWindow.SmallScroll Down:=x / 30
End Sub
 

2 more replies
Relevance 50.84%

ActiveDocument.AttachedTemplate.BuildingBlockEntries seems to have a problem ... to generate the macro I simply clicked INSERT then Headers and selected the "ANNUAL" header and closed headers. Here is the macro generated...

Sub Macro5()
'
' Macro5 Macro
'
'
If ActiveWindow.View.SplitSpecial <> wdPaneNone Then
ActiveWindow.Panes(2).Close
End If
If ActiveWindow.ActivePane.View.Type = wdNormalView Or ActiveWindow.ActivePane.View.Type = wdOutlineView Then
ActiveWindow.ActivePane.View.Type = wdPrintView
End If
ActiveWindow.ActivePane.View.SeekView = wdSeekCurrentPageHeader
ActiveDocument.AttachedTemplate.BuildingBlockEntries("Annual").Insert
Where:=Selection.Range, RichText:=True
ActiveWindow.ActivePane.View.SeekView = wdSeekMainDocument
End Sub
--------

I removed the line contuation marks for clarity here, when run it generates this error 5941 the requested member of the collection does not exist and then highlightes this line

ActiveDocument.AttachedTemplate.BuildingBlockEntries("Annual").Insert _
Where:=Selection.Range, RichText:=True

---------

Help please
 

Answer:Auto Generated Word Macro doesn't run (2007)

I get exactly the same error but If you delete

ActiveDocument.AttachedTemplate.BuildingBlockEntries("Annual").Insert
Where:=Selection.Range, RichText:=True

It does go to Headers and Footers, so it looks like the Macro cannot recreate the "Annual" selection for some reason. VBA expert(s) needed please!
 

1 more replies