Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 40
Default Embedding spreadsheet in a user form

I am writing a complex VBA program. I know how to protect a worksheet from
data and format and structure changes, but is there any way to make the user
unable to change the size and screen location of a currently displayed
worksheet? Is there any way to embed a worksheet onto a user form so that it
occupies a certain position on the user form. I desire a situation in which
a "window" on the user form contains a worksheet. Within this "window" the
user can move the cursor in the worksheet and the worksheet's scroll-bars are
displayed and active and the PageUP and PageDown controls work, but the user
can not change any of the data or formatting or structure af the worksheet,
and he cannot change its size or location within the worksheet's "window" on
the user form. In other words, I want something like a list box but I want
to have the formatting and display options (such as text-wrap, color,
co-lwidth, font, etc.) which, as far as I know, are only available on a
worksheet.

Any suggestions as to how to get this would be appreciated.




--
-regards
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,290
Default Embedding spreadsheet in a user form


There is a "spreadsheet" control you can add to a userform.
It looks like, um, a spreadsheet and may do what you want (you will have to experiment).
You can add it to the tool box using "additional controls".
Find that by right-clicking the tool box.
The one you want is "Microsoft Office Spreadsheet xx.o"
A nice feature, is that it comes with its own help.
Click the "?" at the top right after it is added to the userform.
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware
(Excel Add-ins / Excel Programming)



"GeorgeJ"
wrote in message
I am writing a complex VBA program. I know how to protect a worksheet from
data and format and structure changes, but is there any way to make the user
unable to change the size and screen location of a currently displayed
worksheet? Is there any way to embed a worksheet onto a user form so that it
occupies a certain position on the user form. I desire a situation in which
a "window" on the user form contains a worksheet. Within this "window" the
user can move the cursor in the worksheet and the worksheet's scroll-bars are
displayed and active and the PageUP and PageDown controls work, but the user
can not change any of the data or formatting or structure af the worksheet,
and he cannot change its size or location within the worksheet's "window" on
the user form. In other words, I want something like a list box but I want
to have the formatting and display options (such as text-wrap, color,
co-lwidth, font, etc.) which, as far as I know, are only available on a
worksheet.

Any suggestions as to how to get this would be appreciated.
--
-regards
  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 40
Default Embedding spreadsheet in a user form

Thank you Jim. I was unaware that one could add more types of controls by
right clicking the control box. However, I was *not* able to find the one
you referred to, specifically "Microsoft Office Spreadsheet xx.o". When I
right clicked in the control box there appeared a drop down list of
additional possible controls. They were arranged alphabetically and the
only ones starting with "Microsoft Office" were of the form "Microsoft Office
Outlook ...". I didn't see any additional controls that contained the word
"spreadsheet". I am using Excel 2007.

I would like to resubmitt my original question. Is it possible to lock a
worksheet so that

a) the user cannot move the cursor outside of a certain row range and a
certain column range ?

b) the use cannot change the location on the screen of the window displaying
the worksheet, and he cannot change the size of the window displaying the
worksheet?

Thanks
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,290
Default Embedding spreadsheet in a user form


You may want to start over with a new post.
I would not have attempted to answer your question if you had mentioned XL2007.
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware
(Excel Add-ins / Excel Programming)



"GeorgeJ"
wrote in message
Thank you Jim. I was unaware that one could add more types of controls by
right clicking the control box. However, I was *not* able to find the one
you referred to, specifically "Microsoft Office Spreadsheet xx.o". When I
right clicked in the control box there appeared a drop down list of
additional possible controls. They were arranged alphabetically and the
only ones starting with "Microsoft Office" were of the form "Microsoft Office
Outlook ...". I didn't see any additional controls that contained the word
"spreadsheet". I am using Excel 2007.

I would like to resubmitt my original question. Is it possible to lock a
worksheet so that

a) the user cannot move the cursor outside of a certain row range and a
certain column range ?

b) the use cannot change the location on the screen of the window displaying
the worksheet, and he cannot change the size of the window displaying the
worksheet?

Thanks
Reply
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
How do I fill a cell in a user form from a selection on same form? Terry Tipsy Excel Discussion (Misc queries) 4 June 11th 07 02:59 PM
Put "put user form" in spreadsheet Keith New Users to Excel 3 April 8th 07 07:00 PM
User form and hiding spreadsheet Chip Smith Excel Discussion (Misc queries) 0 March 29th 06 07:46 PM
Embedding excel charts in my C# windows form Matt Kosorok Charts and Charting in Excel 0 May 11th 05 05:02 PM
Embedding a file into an Excel spreadsheet? Ranjan Excel Worksheet Functions 0 March 24th 05 12:45 PM


All times are GMT +1. The time now is 11:13 AM.

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

About Us

"It's about Microsoft Excel"