export to excel, lower slider size

  • Thread starter OTWarrior via AccessMonster.com
  • Start date
O

OTWarrior via AccessMonster.com

when i export a query to an excel file, the horizontal slider at the bottom
overs everything but the first worksheet, and i have to manually resize it.

Is there any way of setting the size from access, or would I have to have a
macro held in the file that access calls (if so, how do i call an external
macro?)

Any help is greatly appreciated
 
M

mcescher

when i export a query to an excel file, the horizontal slider at the bottom
overs everything but the first worksheet, and i have to manually resize it.

Is there any way of setting the size from access, or would I have to have a
macro held in the file that access calls (if so, how do i call an external
macro?)

Any help is greatly appreciated

Public Function testExcelSize()
Dim xla As Excel.Application
Dim xlb As Excel.Workbook
Dim xls As Excel.Worksheet
Set xla = Excel.Application
Set xlb = xla.Workbooks.Open("c:\test1.xls")
Set xls = xlb.Worksheets(1)
xla.Visible = True
xla.ActiveWindow.TabRatio = 1
'xla.ActiveWorkbook.SaveAs strFullName
'xla.ActiveWorkbook.Save
End Function


The TabRatio line above sets the width of the scrollbar, and is set as
a ratio of tab area to scrollbar area. Some examples follow.

1 = 100% of the tab area is showing (no scroll bar)
..75 = 75% of the tab area is showing. 25% of the scroll bar shows.
0 = 0% of the tab area is showing. Only the scroll bar is visible.

HTH,
Chris M.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top