+ Reply to Thread
Results 1 to 8 of 8

Create table within a userform

  1. #1
    Forum Contributor
    Join Date
    11-09-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    391

    Create table within a userform

    Hi All,

    I was wandering is there a way to create a table within a userform to paste data in it?

    Thanks

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

    Re: Create table within a userform

    There is no built-in "table" control that can be used in a userform. There are ways you can use textboxes to look like a table, but you can't paste an entire table that way. You can only paste one value at a time.

    Can you be more specific about what you want this table to look like and what you want to paste into it?
    Jeff
    | | |·| |·| |·| |·| | |:| | |·| |·|
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Forum Contributor
    Join Date
    11-09-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    391

    Re: Create table within a userform

    Thank you for your reply. I thought so but I was hoping to get an intelligent way to what I am willing to do.

    Basically I have a spreadsheet with 365 rows and 48 columns of data. I was looking for a way to be able to copy and paste these data into a table within a userform and write some vba codes to do some calculations. there could be few different spreadsheets that the calculations need to be link together so I was hoping something like a userform with an OK button to allow me paste data in it and by pressing OK do the calculations clear the table for the next set of data. I hope I am clear on this.

    Quote Originally Posted by 6StringJazzer View Post
    There is no built-in "table" control that can be used in a userform. There are ways you can use textboxes to look like a table, but you can't paste an entire table that way. You can only paste one value at a time.

    Can you be more specific about what you want this table to look like and what you want to paste into it?

  4. #4
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2502
    Posts
    26,995

    Re: Create table within a userform

    I would use a userform together with a worksheet, instead of trying to simulate a worksheet in the form. A non-modal form could direct the user to a worksheet for pasting data and go back and forth between that and the form. I'll see if I can do a quick mock-up for you.

  5. #5
    Forum Contributor
    Join Date
    11-09-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    391

    Re: Create table within a userform

    Thank you very much 6StringJazzer
    I really appreciate that

    Quote Originally Posted by 6StringJazzer View Post
    I would use a userform together with a worksheet, instead of trying to simulate a worksheet in the form. A non-modal form could direct the user to a worksheet for pasting data and go back and forth between that and the form. I'll see if I can do a quick mock-up for you.

  6. #6
    Forum Contributor
    Join Date
    11-09-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    391

    Re: Create table within a userform

    Alternatively is it possible to browse a file and get a sum of each row of the source file and paste the value into a destination file? i.e. instead of importing all the values in attached I am looking for a way to browse the file and paste the colum AX (highlighted) into a new spreadsheet.
    Attached Files Attached Files

  7. #7
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2502
    Posts
    26,995

    Re: Create table within a userform

    This is just a demo to illustrate the idea. You haven't given any information about your data organization, worksheets, etc., so I can't give you a solution specific to your problem.

    Go to Form1
    Select the block of numbers
    Click "Open Form"
    Click "Paste"

    The data will be copied from the current selection, and pasted to the Table sheet
    Attached Files Attached Files

  8. #8
    Forum Contributor
    Join Date
    11-09-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2013
    Posts
    391

    Re: Create table within a userform

    Thanks though,

    it is a bit different as the data would be paste from different workbook but it may give me some other ideas as well.

    Quote Originally Posted by 6StringJazzer View Post
    This is just a demo to illustrate the idea. You haven't given any information about your data organization, worksheets, etc., so I can't give you a solution specific to your problem.

    Go to Form1
    Select the block of numbers
    Click "Open Form"
    Click "Paste"

    The data will be copied from the current selection, and pasted to the Table sheet

+ 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. Need help with dynamic userform to create a pivot table
    By BG1983 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-01-2016, 06:43 PM
  2. How to create a dynamic macro that will create pivot table
    By thlee1122 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-08-2015, 11:49 PM
  3. Create a macro to create a pivot table in a worksheet
    By Triscia in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-15-2015, 10:53 AM
  4. Replies: 3
    Last Post: 11-09-2014, 08:57 PM
  5. [SOLVED] Create Macro, Userform or a searchbox to search data from table in excel in diff sheets
    By hanif in forum Excel Programming / VBA / Macros
    Replies: 19
    Last Post: 03-25-2014, 06:21 AM
  6. UserForm: i want to create a adjustable (Resizer) userform
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 03-23-2014, 09:37 AM
  7. Create Pivot Table from Userform Search
    By paulstan in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-06-2011, 06:52 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