Create an enumeration (available in Access 2000 and higher)
For example...
CODE TO CALL CLASS MODULE
======================================================================
mobjExcel.SetCellFormatHorizontalTextAlignment_ByRange("aa", <param listing
displayed>)
Note: When the 2nd parameter is about to be set, the intell-sense gives you
a drop-down list of the entries to select.
CODE IN CLASS MODULE
======================================================================
Public Enum enumHorizontalAlignment
haAlignLeft = Excel.XlHAlign.xlHAlignLeft
haAlignRight = Excel.XlHAlign.xlHAlignRight
haCenter = Excel.XlHAlign.xlHAlignCenter
haCenterAcrossSelection = Excel.XlHAlign.xlHAlignCenterAcrossSelection
haDistributed = Excel.XlHAlign.xlHAlignDistributed
haFill = Excel.XlHAlign.xlHAlignFill
haGeneral = Excel.XlHAlign.xlHAlignGeneral
haJustify = Excel.XlHAlign.xlHAlignJustify
End Enum
Public Function GetCellFormatHorizontalTextAlignment_ByRange( _
ByVal Range As String) As enumHorizontalAlignment
:
: code removed
:
End Function
HTH
--
Rob
FMS Professional Solutions Group
http://www.fmsinc.com/consulting
Software Tools for .NET, SQL Server, Visual Basic & Access
http://www.fmsinc.com
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-