Results 1 to 4 of 4

Thread: Excel - UserForm Input

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2005
    Posts
    4

    Excel - UserForm Input

    Hi
    My problem is this
    On my sheet, i have a check box. when you check the checkbox, a userform pops up asking for some data. The user types the requested data into the textbox on the userform, then clicks the button. the data then appears in a specified cell.

    It works fine until the part where the data appears in the cell. How do i link th checkbox to the cell i want the data to appear in so the data appears in the right cell? (I have several checkboxes for several different cells, otherwise it would be easy) I tried using the LinkedCell property which didnt seem to work, and inttegers, but i couldnt access the integers in module1 from the userform1 code and Vice Versa. Im probably making a mountian out of a molehill with this, but hey!! Any help/simplifications would be greatly appreciated.

    Thanks
    nick

  2. #2
    Don't Panic! Ecniv's Avatar
    Join Date
    Nov 2000
    Location
    Amsterdam...
    Posts
    5,343

    Re: Excel - UserForm Input

    How do you get the checkbox to open the form?
    Can you pass the form a global variable or two with the last cell used?
    Or perhaps pass the form via a global variable the actual checkbox?
    If you get the checkbox, are there properties of the checkbox of cell location??

    BOFH Now, BOFH Past, Information on duplicates

    Feeling like a fly on the inside of a closed window (Thunk!)
    If I post a lot, it is because I am bored at work! ;D Or stuck...
    * Anything I post can be only my opinion. Advice etc is up to you to persue...

  3. #3

    Thread Starter
    New Member
    Join Date
    Jan 2005
    Posts
    4

    Re: Excel - UserForm Input

    I didnt think it was that hard.

    Code:
     Sub CheckBox1_Click()
    If Sheet1.CheckBoxes(1).Value = Checked Then
        UserForm1.Show
    End If
    I got to CheckBox1_Click by doing 'assign macro' and clicking 'New'.

    I'm not a very experienced programmer. Global Variable?

    Probably Obvious

  4. #4

    Thread Starter
    New Member
    Join Date
    Jan 2005
    Posts
    4

    Resolved Re: Excel - UserForm Input

    Thanks, i got it now. Thanks for your help

    Nick

Posting Permissions

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



Click Here to Expand Forum to Full Width