IntroductionGetting StartedAll PostsNotesAbout The Author
Friday, September 25, 2009
RSS
Controling The VBE
Friday, September 25, 2009 - 1:43 PM
This is useful for hiding the VBE after code stops (do to a "Stop" statement, because the user interrupted the code, or because of an error).


Public
gvTestVBEAccess As Boolean


Public Function HideVBE()
    On Error Resume Next
    If fTestVBEAccess Then Application.VBE.MainWindow.Visible = False
End Function


Private Function fTestVBEAccess()
As Boolean
'returns true if the project isn't locked
'uses gvTestVBEAccess public boolean for sake of speed
   
Creating Outlook Messages With HTML Formatted Ranges
Friday, September 25, 2009 - 1:41 PM

Public Function CreateHTMLTable$(strRangeReference$, Optional WSName, Optional WBName, Optional HTMFilePath$, Optional HTMFileName$, _
    Optional TableName$)
'converts a range to HTML format, retaining all Excel formatting, and sends in an Outlook message
'requires references to Microsoft Outlook Object Library (msoutl9olb)
' and Microsoft Scripting Runtime (SCRRUN.DLL)
               

'uses TestLen

Reliable Worksheet Filtering With VBA
Friday, September 25, 2009 - 1:37 PM
Also see "cMatch and rMatch Functions". They can be used to identify column and row numbers to use for filtering, assuming there are no empty column or row headers in the filter range. (Check back soon for code to account for missing column and row headers.)

Filtering is also useful for charts because when rows and columns of data are filtered/hidden, the data series and points they contain are not displayed in charts using that data.


Option Explicit
Option Base
1


Public Const Show = True, Hide =
cMatch And rMatch Functions
Friday, September 25, 2009 - 1:06 PM
These functions facilitate using the extremely useful built-in 'match' function to identify column or row numbers for a supplied header. These functions accomplish the same objective as using named ranges for each column, but in an easier and better way. Header names may also be stored as public variables in your declarations module to prevent typos.

These functions can be used to identify column and row numbers to use for filtering, assuming there are no empty column or row headers in
4 records total        

January, 2009
February, 2009
March, 2009
April, 2009
May, 2009
June, 2009
July, 2009
August, 2009
September, 2009
October, 2009
November, 2009
December, 2009
IntroductionGetting StartedAll PostsNotesAbout The Author