+ Reply to Thread
Results 1 to 3 of 3

Populate a activex textbox from input boxes. Collect each line of address separately

  1. #1
    Registered User
    Join Date
    09-07-2021
    Location
    York
    MS-Off Ver
    2016
    Posts
    2

    Question Populate a activex textbox from input boxes. Collect each line of address separately

    I have two text boxes set to multi;line and vertical scroll bars. I need to make an idiot proof module that asks for each line of an address seperately via inpu boxes and then builds a line of text and line feeds that is fed to a text box which should automatcly show the address. Problwem. Runtime errors as no methoid I can find seems to allow the updating of the texboxes. The system will not recognise the textboxes no matter how I identify them. Very new to this. Is it even possible.
    Attached Files Attached Files

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,532

    Re: Populate a activex textbox from input boxes. Collect each line of address separately

    I corrected your code to work.

    Also, the textboxes are not set to multiline, and are not set for scroll bars. I updated them.

    I strongly recommend to everyone that they use Option Explicit and declare variables. Doing so prevents a lot of bugs and runtime errors.

    The best practice for a user interface like this is to use a UserForm and collect the data all at once, instead of repeatedly calling InputBox. I have set that up too.
    Attached Files Attached Files
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    09-07-2021
    Location
    York
    MS-Off Ver
    2016
    Posts
    2

    Thumbs up Re: Populate a activex textbox from input boxes. Collect each line of address separately

    Thanks Jeff. I never thought of using a userform as a way to get the address data. Sorry about the multiline and vertical scroll bars. They are set in my project but I forgot in the example. Another learning point.

+ 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] (ActiveX) Populate Listbox With Textbox
    By elsg in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 03-25-2015, 02:22 PM
  2. Replies: 1
    Last Post: 01-28-2015, 09:11 PM
  3. URGENT!! Input font size changes in spreadsheet activex textbox
    By manofcheese in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-18-2014, 01:56 PM
  4. Multi-Worksheet ActiveX Textbox to ActiveX Textbox Concatenate
    By HVE_Skynet in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-21-2014, 02:11 PM
  5. Activex Textbox input output value as numeric
    By mani_bbc05 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-17-2013, 03:44 AM
  6. [SOLVED] populate userform listbox from textbox input
    By cfinch100 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 04-05-2013, 10:05 AM
  7. Populate a column based on input from a textbox
    By AnthonyWB in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-09-2012, 03:39 PM

Tags for this Thread

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