Good link to learn how Excel macro can be used along with Outlook:
We all use VBA macro to automate reports and for that we are very much dependent on Google. Google provides lot of information but at times it’s difficult to locate the right piece of information. This blog is created to share some useful VBA codes which can be used by professionals in their work. You will find ready to use codes and formulas to make your job easy.
Tuesday, September 10, 2013
Sunday, September 8, 2013
Saturday, September 7, 2013
Thursday, September 5, 2013
Code to go to the top cell
VBA Code to go to the top cell in a sheet:
Private Sub Workbook_Open()
With ActiveWindow
.ScrollRow = 1
.ScrollColumn = 1
Call Cells(.ScrollRow, .ScrollColumn).Select
End With
End Sub
Tuesday, September 3, 2013
Get to last row in a column
How to get to the last row in a column using VBA:
Dim LastRow As Long
LastRow = Range("I" & Rows.Count).End(xlUp).Row
'I is the column and LastRow is a variable
Delete rows using Loop
VBA code to loop thru rows within column and delete rows containing a certain value:
Dim LastRow As Long
Dim I As Long
LastRow = Range("D" & Rows.Count).End(xlUp).Row
For I = LastRow To 2 Step -1 'Change the row number
Set rng = Range("D" & I)
If rng.Value= "ABC" Then 'Change the condition
rng.EntireRow.Delete
End If
Next I
Monday, September 2, 2013
Subscribe to:
Posts (Atom)