1) Paste range into userform listbox? 2)Copy listbox range to cells on sheet?

xlyfe

Board Regular
Joined
Aug 28, 2020
Messages
55
Office Version
  1. 365
Platform
  1. Windows
Hello,

I'm wondering if anybody knows if it's possible to paste a range of cells into a userform, and then when a "Submit" button is pressed on the userform, the userform values are then copied to a specific cell in a new workbook. But the trick here would be that when it's pasted into the new sheet, it would have to remember how many columns and rows of data the original values came from, so that it's pasted in the same format on the sheet.

Basically trying to mimic a keyboard 'Ctrl+C' and 'Ctrl-V' gesture from one worksheet to another, but instead of pasting directly into the new worksheet cell, doing so into a userform field of some sort.

Is this possible?
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Do you want to change the values presented on the userform? If so, I'm only seeing using a textbox for each value.
Why don't you just simple have a nice formatt on the sheet, and copy directly from the sheet? It is way, way easier and more simple.
 
Upvote 0
Do you want to change the values presented on the userform? If so, I'm only seeing using a textbox for each value.
Why don't you just simple have a nice formatt on the sheet, and copy directly from the sheet? It is way, way easier and more simple.
The values will never change from the copied range to the pasted range. Only thing I need it to remember is how many rows and columns of data were copied so that it pastes the same amount of rows and cols into the new sheet.

The range I'm copying from is presented in a way that doesn't work for this new workbook.
Currently, the process is to copy a range manually (ctrl c) from Workbook 1, then paste into a cell on Workbook 2. These pasted values are then torn apart and reorganized by formulas located within multiple columns to the right, so that it's more graphically presentable for an outside party.

I was hoping that I could make the new Workbook 2 visually smaller (width-wise) by hiding all of the columns which currently contain these pasted values from Workbook 1. So that all the end user sees is the pasted data restructured by the formulas.

I apologize if my descriptions are confusing.
I do appreciate the time of brainstorming with me tho. :giggle:
 
Last edited:
Upvote 0
Or maybe I can just have the copied range, be pasted into a specific cell in the new worksheet by assigning a 'Crtl-V' command to a command button on a userform showing on the new workbook? So that it maintains how many rows and cols the original range had? :unsure:
 
Upvote 0
The values will never change from the copied range to the pasted range. Only thing I need it to remember is how many rows and columns of data were copied so that it pastes the same amount of rows and cols into the new sheet.

The range I'm copying from is presented in a way that doesn't work for this new workbook.
Currently, the process is to copy a range manually (ctrl c) from Workbook 1, then paste into a cell on Workbook 2. These pasted values are then torn apart and reorganized by formulas located within multiple columns to the right, so that it's more graphically presentable for an outside party.

I was hoping that I could make the new Workbook 2 visually smaller (width-wise) by hiding all of the columns which currently contain these pasted values from Workbook 1. So that all the end user sees is the pasted data restructured by the formulas.

I apologize if my descriptions are confusing.
I do appreciate the time of brainstorming with me tho. :giggle:
OK, I'd eliminate the useform off the equation. From my perspective it is common, at least for me, to copy raw data to a new workbook, and from that point, formatt the data to what I want, but already on the new workbook. My advice is always not to get complicated. Although, what you are presenting is very vague. Try to show the sheets or an example, prefencially using XL2BB. ;)
 
Upvote 0
Or maybe I can just have the copied range, be pasted into a specific cell in the new worksheet by assigning a 'Crtl-V' command to a command button on a userform showing on the new workbook? So that it maintains how many rows and cols the original range had? :unsure:

Basically pasting the current windows clipboard to a specific cell assigned to a button? Hmm...
 
Upvote 0
Or maybe I can just have the copied range, be pasted into a specific cell in the new worksheet by assigning a 'Crtl-V' command to a command button on a userform showing on the new workbook? So that it maintains how many rows and cols the original range had? :unsure:

Basically pasting the current windows clipboard to a specific cell assigned to a button? Hmm...
You don't need an userform for that, just a button on the sheet of origin. Show what you want, even with a few rows...
 
Upvote 0
Figured it out after our chat. Thanks tico.

VBA Code:
Private Sub PasteLumberBtn_Click()
    Range("C4").Select
    ActiveSheet.Paste
End Sub
 
Upvote 0

Forum statistics

Threads
1,215,028
Messages
6,122,749
Members
449,094
Latest member
dsharae57

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top