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: 5
Default Control User Form object properties from VBA code

Hello all.

I have just spent the last 2.5 hours trying to figure out how to do this and
am at the end of my rope. Excel help is no use (big surprise!), my Excel
reference book contains no code examples (gotta get me a complete Excel VBA
Reference guide), and everything I have found on the Web doesn't apply to me
or is too confusing for an intermediate, occasional programmer like me. The
irony is that my need seems fairly simple.

I have an Excel 2007 spreadsheet. One of the cells has a list box (the
official property name is 'MyListBox') whose Input Range I want to change
based on a user's selection elsewhere in this form. Note that the list box
was added as a Form Object, NOT an ActiveX Object. The list box nor the cell
it is in will be selected at the time the code needs to change the list box's
properties.

What would the code look like to change the current Input Range from AA1:AA3
to AB1:AB3?

You see? Simple request!

Thanks in advance.


 
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
Object name on user form Alan Excel Programming 9 January 2nd 09 04:32 PM
User form Object corruption Datasort Excel Programming 3 January 19th 06 07:16 PM
user form & control properties Mike Molyneaux Excel Programming 0 April 1st 05 07:41 PM
user form properties not saving amescha Excel Programming 3 October 27th 04 09:03 PM
Changing control properties/code through code Ajit Excel Programming 3 October 18th 04 09:03 PM


All times are GMT +1. The time now is 08:53 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"