LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Junior Member
 
Posts: 8
Post Help merging two VBA codes

Hi,

I'm having a bit of difficulty merging two different VBA functions into one button.

This the the button code:

Select Code copy to clipboard
Private Sub CommandButton2_Click()

With Sheets("Recommendations Calc").Range("A" & Rows.Count).End(xlUp)
.Offset(1, 0).Value = Sheets("Decision Matrix").Range("C2").Value
.Offset(1, 1).Value = Sheets("Decision Matrix").Range("h55").Value
.Offset(1, 4).Value = Sheets("Decision Matrix").Range("I55").Value
deletedup '<--call the macro to delete the dup. and put the last data entry.
End With

End Sub


And this is the other VBA code:


Select Code copy to clipboard
Sub thebigcopy()
'
' thebigcopy Macro
'

'
ActiveWindow.SmallScroll Down:=-21
Columns("A:B").Select
Selection.Copy
Sheets("Recommendations").Select
Columns("A:B").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Sheets("Recommendations Calc").Select
Columns("E:E").Select
Application.CutCopyMode = False
Selection.Copy
Range("C37").Select
Sheets("Recommendations").Select
Columns("E:E").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
End Sub



I want to merge the 2nd code into the 1st button VB code

Can anyone help me?

Thank You!!
 
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
Need some help with codes Tom Excel Discussion (Misc queries) 2 August 16th 07 01:09 AM
When merging information not merging correctly Bridgett Excel Worksheet Functions 0 December 9th 05 10:12 PM
Merging Two Codes Into one code LoveCandle[_18_] Excel Programming 11 November 27th 05 04:13 AM
re : Help Need on my codes ddiicc Excel Programming 2 August 17th 05 05:37 AM
Sorting, Merging, and Re-merging Abi Excel Worksheet Functions 2 June 15th 05 08:21 PM


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

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

About Us

"It's about Microsoft Excel"