Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Forms Controls

I have an excel spreadsheet that is using the Forms Dropdown box and it gets
its data from a range of cells. I would like to know how to capture the
value of the text when it changes to something else. I would like to use VBA
to do this. I know if I used the Controls dropdown box that would be easier
but this is how this one is.

If there is no way that I can do that can someone tell me how to set the
Controls Dropdown to accomplish the same thing the form control is doing.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Forms Controls

Assign the dropdown macro to

Msgbox ActiveSheet.DropDowns("Drop Down 1").Value

will work as long as the value is changed by clicking the dropdown, not by
changing the linked cell that changes the value in the control.


"Larry Dodd" wrote in message
...
I have an excel spreadsheet that is using the Forms Dropdown box and it

gets
its data from a range of cells. I would like to know how to capture the
value of the text when it changes to something else. I would like to use

VBA
to do this. I know if I used the Controls dropdown box that would be

easier
but this is how this one is.

If there is no way that I can do that can someone tell me how to set the
Controls Dropdown to accomplish the same thing the form control is doing.




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 252
Default Forms Controls

Assuming your Forms dropdown has its Link cell set to A1, and the input range
is set to "myList",

then in cell B1 enter:
=INDEX(myList,A1)

This will convert the number value of cell A1 back into the actual value
from your named range.

The controls dropdown bypasses this step. You set the Linked Cell in the
control Properties to A1 and the actual value from the list is returned to
the LinkedCell.


"Larry Dodd" wrote:

I have an excel spreadsheet that is using the Forms Dropdown box and it gets
its data from a range of cells. I would like to know how to capture the
value of the text when it changes to something else. I would like to use VBA
to do this. I know if I used the Controls dropdown box that would be easier
but this is how this one is.

If there is no way that I can do that can someone tell me how to set the
Controls Dropdown to accomplish the same thing the form control is doing.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Forms Controls

You could always set the linked cell of the control, and read that value.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Larry Dodd" wrote in message
...
I have an excel spreadsheet that is using the Forms Dropdown box and it

gets
its data from a range of cells. I would like to know how to capture the
value of the text when it changes to something else. I would like to use

VBA
to do this. I know if I used the Controls dropdown box that would be

easier
but this is how this one is.

If there is no way that I can do that can someone tell me how to set the
Controls Dropdown to accomplish the same thing the form control is doing.




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,327
Default Forms Controls

The Forms dropdown returns its listindex (1-based) into the linked cell, not
its text. So this requires either an INDEX formula in a helper cell or a VBA
macro assigned to the dropdown:

Sub DropClick()
ActiveSheet.Range("B2").Value = _
ActiveSheet.DropDowns(1).List(ActiveSheet.DropDown s(1).Value)
End Sub

HTH. Best wishes Harald

"Bob Phillips" skrev i melding
...
You could always set the linked cell of the control, and read that value.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Larry Dodd" wrote in message
...
I have an excel spreadsheet that is using the Forms Dropdown box and it

gets
its data from a range of cells. I would like to know how to capture the
value of the text when it changes to something else. I would like to use

VBA
to do this. I know if I used the Controls dropdown box that would be

easier
but this is how this one is.

If there is no way that I can do that can someone tell me how to set the
Controls Dropdown to accomplish the same thing the form control is

doing.






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
ActiveX to Forms controls Sian Excel Discussion (Misc queries) 2 January 31st 08 12:22 AM
Excel forms controls [email protected] Excel Discussion (Misc queries) 1 March 18th 07 04:37 AM
Forms controls Catalin Excel Worksheet Functions 2 May 11th 06 03:44 PM
diference between FORMS & CONTROLS Marek Excel Programming 3 September 5th 04 07:53 AM
Forms Controls Chuck Taylor Excel Programming 2 December 1st 03 01:42 PM


All times are GMT +1. The time now is 02:16 PM.

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"