ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How would I modify the following? (https://www.excelbanter.com/excel-programming/280853-how-would-i-modify-following.html)

BruceJ[_2_]

How would I modify the following?
 
Sub MinReport()
RC=
Sheets("15mintest").Select
Range("A2:G2").Select
Selection.Copy
ActiveCell.SpecialCells(xlLastCell).Select
Range().Select
ActiveSheet.Paste
Sheets("Master").Select
End Sub

What I want to do is make it so it does not interfer with what sheet I am
working on now.
Currently, it will select the sheet, paste data and then go back to Master
Can I do this with out interfering with the screen I am on, and Not
"selecting" the 15mintest sheet, just have it paste at the bottom of
15mintest?

Thanks
Bruce




J.E. McGimpsey

How would I modify the following?
 
one way:

Public Sub MinReport()
With Sheets("15mintest").Range("A2:G2")
.Parent.Range("A" & Rows.Count).End(xlUp).Offset( _
1, 0).Resize(1, 7).Value = .Value
End With
End Sub


In article <WTCnb.52055$Tr4.108464@attbi_s03,
"BruceJ" wrote:

Sub MinReport()
RC=
Sheets("15mintest").Select
Range("A2:G2").Select
Selection.Copy
ActiveCell.SpecialCells(xlLastCell).Select
Range().Select
ActiveSheet.Paste
Sheets("Master").Select
End Sub

What I want to do is make it so it does not interfer with what sheet I am
working on now.
Currently, it will select the sheet, paste data and then go back to Master
Can I do this with out interfering with the screen I am on, and Not
"selecting" the 15mintest sheet, just have it paste at the bottom of
15mintest?

Thanks
Bruce




steve

How would I modify the following?
 
Bruce,

Not too sure of how this is working - but amend this code to copy from
one sheet and paste to another without selecting anything... And it doesn't
matter what the active sheet is...

Sheets("Sheet1").Range("A2:G2").Copy _
Destination:= Sheets("Sheet2").Range("A1")

--
sb
"BruceJ" wrote in message
news:WTCnb.52055$Tr4.108464@attbi_s03...
Sub MinReport()
RC=
Sheets("15mintest").Select
Range("A2:G2").Select
Selection.Copy
ActiveCell.SpecialCells(xlLastCell).Select
Range().Select
ActiveSheet.Paste
Sheets("Master").Select
End Sub

What I want to do is make it so it does not interfer with what sheet I am
working on now.
Currently, it will select the sheet, paste data and then go back to Master
Can I do this with out interfering with the screen I am on, and Not
"selecting" the 15mintest sheet, just have it paste at the bottom of
15mintest?

Thanks
Bruce






BruceJ[_2_]

How would I modify the following?
 
I have tried the code (and also mine) and both of them don't seem to work
when called from the program! If I make a macro, and press the hot key, it
works, but when I move it into the actual CODE, it does not. Any ideas? It
makes it to the module, both msgboxes come up...


Public Sub showtimer()
MsgBox ("Notes Added!")
With Sheets("15min").Range("A2:G2")
.Parent.Range("A" & Rows.Count).End(xlUp).Offset(1, 0).Resize(1,
7).Value = .Value
End With
incrementTimer
lasttime = Sheets("15min").Range("A" & Rows.Count - 1) ' to see if new
records were added....
MsgBox (lasttime)
Call OntimeManager("ADD", nowplus, "showtimer", nowplus1)
End Sub

"J.E. McGimpsey" wrote in message
...
one way:

Public Sub MinReport()
With Sheets("15mintest").Range("A2:G2")
.Parent.Range("A" & Rows.Count).End(xlUp).Offset( _
1, 0).Resize(1, 7).Value = .Value
End With
End Sub


In article <WTCnb.52055$Tr4.108464@attbi_s03,
"BruceJ" wrote:

Sub MinReport()
RC=
Sheets("15mintest").Select
Range("A2:G2").Select
Selection.Copy
ActiveCell.SpecialCells(xlLastCell).Select
Range().Select
ActiveSheet.Paste
Sheets("Master").Select
End Sub

What I want to do is make it so it does not interfer with what sheet I

am
working on now.
Currently, it will select the sheet, paste data and then go back to

Master
Can I do this with out interfering with the screen I am on, and Not
"selecting" the 15mintest sheet, just have it paste at the bottom of
15mintest?

Thanks
Bruce







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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com