+ Reply to Thread
Results 1 to 12 of 12

User form - Can't set ControlSource property. Invalid property value.

  1. #1
    Forum Contributor
    Join Date
    06-11-2009
    Location
    Cape Town
    MS-Off Ver
    Microsoft 365
    Posts
    854

    User form - Can't set ControlSource property. Invalid property value.

    I have a range name called MonthChosen but if I type this name in the in the Control Source property section of my UserForm3, I get the following error message: [Can't set ControlSource property. Invalid property value]? I have another UserForm1 in the same workbook that uses MonthChosen without a problem. There is no problem with the spelling.
    Thanks in advance

  2. #2
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: User form - Can't set ControlSource property. Invalid property value.

    do you have the correct workbook active when typing in the name?
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  3. #3
    Forum Contributor
    Join Date
    06-11-2009
    Location
    Cape Town
    MS-Off Ver
    Microsoft 365
    Posts
    854

    Re: User form - Can't set ControlSource property. Invalid property value.

    Thanks for your reply. Yes, I have only one workbook open.

  4. #4
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: User form - Can't set ControlSource property. Invalid property value.

    can you post the file-after removing all data?

  5. #5
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643
    Why are you using ControlSource?

    You could write a few lines of code to transfer data to/from a worksheet.

    That would give you more control over what's happening.
    If posting code please use code tags, see here.

  6. #6
    Forum Contributor
    Join Date
    06-11-2009
    Location
    Cape Town
    MS-Off Ver
    Microsoft 365
    Posts
    854

    Re: User form - Can't set ControlSource property. Invalid property value.

    Thanks for your reply Norie. I have tried to use code but receive an error message on line 5? Can you assist me with this?

    Please Login or Register  to view this content.
    Thanks in advance

  7. #7
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: User form - Can't set ControlSource property. Invalid property value.

    controlsource is a string
    Please Login or Register  to view this content.
    I agree with Norie though-better not to use controlsource at all

  8. #8
    Forum Contributor
    Join Date
    06-11-2009
    Location
    Cape Town
    MS-Off Ver
    Microsoft 365
    Posts
    854

    Re: User form - Can't set ControlSource property. Invalid property value.

    I still get an error message using this code on the following line: UserForm3.ListBox1.ControlSource = "Month_Chosen". The error message is:
    Could not set the ControlSource property. Invalid property value. Run-time error: 380

  9. #9
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643
    I wasn't suggesting using code to set the ControlSource.

    What I'm suggesting is using code to read/write between the userform/worksheet.

  10. #10
    Forum Contributor
    Join Date
    06-11-2009
    Location
    Cape Town
    MS-Off Ver
    Microsoft 365
    Posts
    854

    Re: User form - Can't set ControlSource property. Invalid property value.

    Can you explain how I would do that? I am trying to select an item from listbox1 on userform3 and have that selection placed in a cell that is named Month_Chosen?

  11. #11
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643
    That could be as simple as this.
    Please Login or Register  to view this content.
    That code could go in the listbox's Change or Click event, or elsewhere in the userform code.

  12. #12
    Forum Contributor
    Join Date
    06-11-2009
    Location
    Cape Town
    MS-Off Ver
    Microsoft 365
    Posts
    854

    Re: User form - Can't set ControlSource property. Invalid property value.

    Thank you very much.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Excel run-time error '381': Could not set the List property. Invalid property array index
    By eemiller1997 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 12-20-2012, 12:48 PM
  2. Replies: 2
    Last Post: 06-11-2012, 03:03 PM
  3. controlsource property for userform
    By just_some_guy in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-09-2010, 11:08 AM
  4. Invalid property error loading a form with a date selected form DTPicker
    By copernicus in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-20-2009, 04:17 PM
  5. Runtime Error 380 – Could not set the list property. Invalid property value
    By BernzG in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-21-2005, 05:10 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1