Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default user form to copy and paste from source to destination

I have 2workbooks - a source data workbook and a destination dat
modelling workbook. Every month I need to copy select columns from on
workbook to the other - the complication is that they are laid ou
differently eg column A (source) needs to be pasted over the older dat
of column J (destination).

Most of the time the copy and paste format doesn't change so i woul
like to have defaults set but have the option to change where to past
to, if the source changes as I have no control over that workbook.

I would also like to do this in one step if the default is true.

Can I have a user form which allows me to select the source columns an
paste into the destination columns through check boxes or drop dow
lists and if so, how would i do this

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default user form to copy and paste from source to destination

as a first step use:


Sub Trythis()

Dim UserRange As Range
Dim UserDestination As Range

On Error Resume Next
Set UserRange = Application.InputBox _
(Prompt:="Select you source data Range", _
Title:="Listen to me:", _
Default:=Selection.Address, _
Type:=8)

On Error GoTo 0
If UserRange Is Nothing Then
MsgBox "Bay Bay!"
End
End If
Set UserDestination = Application.InputBox _
(Prompt:="Select you Destination data Range", _
Title:="Listen to me:", _
Default:=Selection.Cells(1).Address, _
Type:=8)

If UserDestination Is Nothing Then
MsgBox "Bay Bay!"
End
End If

UserRange.Copy UserDestination
End Su

--
Message posted from http://www.ExcelForum.com

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default user form to copy and paste from source to destination

Thanks for this except i think i may need some more instructions on ho
to incorporate the code.

When I create the User form - what do you suggest? Is this meant t
work with check boxes and drop downs?

I am imagining a user form which goes to the source sheet and allow
you to select one of the columns, and then allows you to select th
paste column from the destination.

thank

--
Message posted from http://www.ExcelForum.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I copy & paste and keep the source formatting? dmk Excel Discussion (Misc queries) 2 August 6th 08 04:52 PM
Copy Source Cells to Destination Cells Only when a Change Occurs excel student Excel Discussion (Misc queries) 2 July 13th 08 04:13 AM
Excel-how to link source workbook to copy of destination workbook D Lynn Excel Worksheet Functions 1 May 29th 08 05:36 PM
Paste names from a source workbook to a destination kerfloo Excel Discussion (Misc queries) 0 January 31st 08 04:55 PM
How do I copy & paste formulas without them linking to the source Ineluctable Excel Discussion (Misc queries) 8 December 11th 05 08:49 PM


All times are GMT +1. The time now is 05:05 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"