+ Reply to Thread
Results 1 to 7 of 7

How to hide Userform Option button and send userform textbox data via external email?

  1. #1
    Forum Contributor
    Join Date
    10-25-2016
    Location
    Derby, England
    MS-Off Ver
    MS 2013
    Posts
    228

    How to hide Userform Option button and send userform textbox data via external email?

    Hi,

    I would really appreciate it if someone could help me please?

    I’m trying to setup a userform that once it’s filled out it will send me an email with the data via the submit button.

    I’ve managed to do most of it (the easier parts) but I’ve come across a few issues in 2 different parts.

    First Part:

    1. When the userform is opened, I would like it to hide the combobox and label (Existing Operators Initials).
    2. It stays hidden if the “New Operator” Option Button1 is selected.
    3. If Option Button2 is selected then I would like the comboBox and Label (Existing Operators Initials) to appear so they can select their initials.

    Second Part:

    I’ve copied a VBA code off youtube that sends the email and it kind of works because it tries to load outlook. The problem I’ve got is at my work, I have to go through the web to log into my email account. For whatever reason our emails stopped working through the outlook app about a year ago.

    So I was wondering if it’s possible to alter my code so it can load outlook via the web?

    I hope this all makes sense.

    Kind Regards

    Dan
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    02-14-2009
    Location
    .
    MS-Off Ver
    ................
    Posts
    2,840

    Re: How to hide Userform Option button and send userform textbox data via external email?

    For the first part, all controls have a Visible property. Set it False for the 2 controls in the Userform.Initialize event and True/False in the Option button Click events.

  3. #3
    Forum Contributor
    Join Date
    10-25-2016
    Location
    Derby, England
    MS-Off Ver
    MS 2013
    Posts
    228

    Re: How to hide Userform Option button and send userform textbox data via external email?

    Hi Cytop,

    Thanks for you reply.

    I've done the false part of your message but i am struggling with it from the Initialize part.

    Please could you give me a little more info?

    Kind Regards
    Dan

  4. #4
    Forum Expert
    Join Date
    02-14-2009
    Location
    .
    MS-Off Ver
    ................
    Posts
    2,840

    Re: How to hide Userform Option button and send userform textbox data via external email?

    Your workbook updated.

    Slight change to my first post. Instead of hiding the controls in the Initialize event, the Visible property is set False in the Dev environment and the 'New Operator' option value is set True. Then clicking on the 'Existing Op' option will show the controls and clicking back on the 'New Op' option will hide them.
    Attached Files Attached Files
    Last edited by cytop; 07-15-2017 at 08:12 AM. Reason: Typo

  5. #5
    Forum Contributor
    Join Date
    10-25-2016
    Location
    Derby, England
    MS-Off Ver
    MS 2013
    Posts
    228

    Re: How to hide Userform Option button and send userform textbox data via external email?

    Hi Cytop,

    That's perfect for my first problem. Thank You.

    Kind Regards

    Dan

  6. #6
    Forum Expert
    Join Date
    02-14-2009
    Location
    .
    MS-Off Ver
    ................
    Posts
    2,840

    Re: How to hide Userform Option button and send userform textbox data via external email?

    Sorry I can't help with the 2nd part - me and coding for the internet are 2 things that are mutually exclusive...

    I might suggest you mark this as solved and start another thread for that issue on its own - it's always a good idea to limit a thread to just one issue as sometimes threads with multiple issues and a couple of replies get 'overlooked'.

  7. #7
    Forum Contributor
    Join Date
    10-25-2016
    Location
    Derby, England
    MS-Off Ver
    MS 2013
    Posts
    228

    Re: How to hide Userform Option button and send userform textbox data via external email?

    Hi Cytop,

    That's OK, you've been very helpful with the first part.

    I did think when I first posted the 2 issues together I could get messy but now you've confirmed it, I'll do it.

    Thanks again

    Dan

+ 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. Send Userform Data via Outlook Email
    By dan.jones in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-19-2015, 06:33 AM
  2. Send Email using UserForm Data
    By Rosco88 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-07-2015, 10:51 AM
  3. [SOLVED] VBA Line to Send Userform Info to Parent Userform Textbox
    By excelforumkeys in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-01-2014, 04:28 PM
  4. [SOLVED] Send Email button with data from Userforms textbox, and comboboxes
    By JQ113 in forum Outlook Programming / VBA / Macros
    Replies: 7
    Last Post: 03-25-2014, 09:20 PM
  5. [SOLVED] VBA for Option Button on Userform to send data to Multiple Spreadsheets
    By rcfrench in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 03-08-2013, 11:43 AM
  6. Use data from a UserForm to send email
    By tanktata in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 06-11-2011, 03:11 PM
  7. Userform Option Button to Show/Hide Another Option Button on same Userform
    By R_S_6 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-26-2010, 09:44 AM

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