LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default A mixed bag of questions

Terry,

1. Is there some elegant way to cause no cell/range to be selected on a
sheet regardless of the state of the sheet and it's contents vis-a-vis
visibility, protection, etc?


No. You have to set the EnableSelection property to xlNoSelection and then
protect the sheet. Otherwise, some cell must be selected. Assuming you're
talking about programmatically controlling Excel, you can select some cell
off the visible range (accessible via ActiveWindow.VisibleRange), or select
a cell in a hidden row or column. Not very elegant, but it may be suitable
for your needs.

2. Is there any way at all to cause no cell/range to be selected on a

sheet?

See above.

3. Is there any way to import/export VBA code as plain text?


Yes. To export a module, use

ActiveWorkbook.VBProject.VBComponents("Module1").E xport _
filename:= "C:\filename.bas"

To import a module, use

ActiveWorkbook.VBProject.VBComponents.Import _
Filename:="C:\filename.bas"

For more info about working with the VBA Editor via VBA code, see
www.cpearson.com/excel/vbe.htm .

4. Is there any way to control the visibility of application features,

like
formula bars, command bars, etc in a manner that is session temporary? In
other words, is there a way to set them to whatever strikes your fancy

such
that they resume the way they were the next time someone runs Excel

without
having to reset them upon close?



No.

5. It would seem that one cannot invoke Printout on a sheet that's not
visible. Is this the case?


That is the case. You can turn off screen updating, make the sheet visible,
print it, the hide the sheet. E.g.,

Application.ScreenUpdating = False
Worksheets(2).Visible = True
Worksheets(2).PrintOut
Worksheets(2).Visible = False
Application.ScreenUpdating = True

6. It would seem that one cannot cause to be selected a cell/range on a
sheet that is not the active sheet or hidden or something, is this

correct?

That is correct. Remember, however, it is almost never necessary to select
anything in VBA.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
www.cpearson.com



"Terry von Gease" wrote in message
...
Apropos of nothing....

1. Is there some elegant way to cause no cell/range to be selected on a
sheet regardless of the state of the sheet and it's contents vis-a-vis
visibility, protection, etc?

2. Is there any way at all to cause no cell/range to be selected on a

sheet?

3. Is there any way to import/export VBA code as plain text?

4. Is there any way to control the visibility of application features,

like
formula bars, command bars, etc in a manner that is session temporary? In
other words, is there a way to set them to whatever strikes your fancy

such
that they resume the way they were the next time someone runs Excel

without
having to reset them upon close?

5. It would seem that one cannot invoke Printout on a sheet that's not
visible. Is this the case?

6. It would seem that one cannot cause to be selected a cell/range on a
sheet that is not the active sheet or hidden or something, is this

correct?

Experimentation into these matters tends to be somewhat less than
definitive. Hence the questions. We here at the home appreciate your
patience.

--
Terry

"I said I never had much use for one,
I never said I didn't know how to use one."
M. Quigley




 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Answers to questions posing more questions in a workbook sbelle1 Excel Worksheet Functions 2 August 8th 09 01:02 AM
View Questions and Answer to questions I created Roibn Taylor Excel Discussion (Misc queries) 4 July 24th 08 12:05 AM
in excel: @ and " are mixed up? Gorilla_Bear Setting up and Configuration of Excel 1 May 29th 08 01:48 AM
Mixed 3D Charts Mark Ivey Charts and Charting in Excel 1 October 5th 06 08:12 PM
Mixed Cell prbucci Excel Worksheet Functions 2 January 13th 06 03:04 AM


All times are GMT +1. The time now is 11:49 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"