Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 70
Default Run-time error '380'

Hi,
I have a userform with a combobox on it. Upon activation I want it to have
the value from a cell on the worksheet. However sometimes the below code
works and sometimes not:

ComboBox1.Value = Sheets("Brand_Data").Range("A1").Value

I get the "Could not set the Value Property. Invalid proderty value"
message. However when I reset and load the userfrom again it always works...
can anyone make sense of it?

Thanks,
Ozgur
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Run-time error '380'

I would guess the text of "Sheets("Brand_Data").Range("A1").Value" is not in
the list of the combobox and the combobox.Style is set to
2-fmStyleDropDownList.
This mean the user is limited to selecting values from the list and that you
must set the combobox.Value to a list value.

NickHK

"Ozgur Pars" wrote in message
...
Hi,
I have a userform with a combobox on it. Upon activation I want it to have
the value from a cell on the worksheet. However sometimes the below code
works and sometimes not:

ComboBox1.Value = Sheets("Brand_Data").Range("A1").Value

I get the "Could not set the Value Property. Invalid proderty value"
message. However when I reset and load the userfrom again it always

works...
can anyone make sense of it?

Thanks,
Ozgur



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
ControlSource and Localization Issue?? (run-time error '380' Could not set the ControlSource property) TCook Excel Programming 1 March 4th 07 08:12 AM
Run-Time Error '380' Fred Holmes Excel Programming 0 October 27th 06 04:49 PM
run-time error '1004': Application-defined or object-deifined error [email protected] Excel Programming 5 August 10th 05 09:39 PM
Run-time error '380' Nocky Excel Programming 0 October 26th 04 12:50 AM
Befuddled with For Next Loop ------ Run - Time Error '13' Type Mismatch Error rdavis7408 Excel Programming 1 August 25th 04 03:54 AM


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