Macro Help

  • Thread starter Thread starter David M
  • Start date Start date
D

David M

Hello,

In my data sheet, I have a series of formulas that need to
be copied for each record entered. Sine this document
lives and grows each day, I enter my initial data, date,
incident number etc, then I take the above row , select H
thru AG and copy it down to the next row to perform the
functions for that entry...I would like to be able to have
a Macro or a funtion to do this so I won't have to select
then drag down. Any ideas on how I can do this by clicking
a button?

Thanx

David
 
this might give you an idea
Sub newline()
Cells([checksA].Rows.Count + 7, 1).Select
With ActiveCell
..Offset(0) = .Offset(-1)
..Offset(0, 4) = 1
End With
End Sub
 
Thanx Don...do I copy this into the VB editor into the
General section for the datasheet name private sub or just
sub...forgive the unclearity because I am new to writing
VBA code..getting better bur still very much newbie..

D
-----Original Message-----
this might give you an idea
Sub newline()
Cells([checksA].Rows.Count + 7, 1).Select
With ActiveCell
..Offset(0) = .Offset(-1)
..Offset(0, 4) = 1
End With
End Sub

--
Don Guillett
SalesAid Software
(e-mail address removed)
Hello,

In my data sheet, I have a series of formulas that need to
be copied for each record entered. Sine this document
lives and grows each day, I enter my initial data, date,
incident number etc, then I take the above row , select H
thru AG and copy it down to the next row to perform the
functions for that entry...I would like to be able to have
a Macro or a funtion to do this so I won't have to select
then drag down. Any ideas on how I can do this by clicking
a button?

Thanx

David


.
 
Can you do me one favor and please explain this more
because I astill very new to VBA coding....

D
-----Original Message-----
this might give you an idea
Sub newline()
Cells([checksA].Rows.Count + 7, 1).Select
With ActiveCell
..Offset(0) = .Offset(-1)
..Offset(0, 4) = 1
End With
End Sub

--
Don Guillett
SalesAid Software
(e-mail address removed)
Hello,

In my data sheet, I have a series of formulas that need to
be copied for each record entered. Sine this document
lives and grows each day, I enter my initial data, date,
incident number etc, then I take the above row , select H
thru AG and copy it down to the next row to perform the
functions for that entry...I would like to be able to have
a Macro or a funtion to do this so I won't have to select
then drag down. Any ideas on how I can do this by clicking
a button?

Thanx

David


.
 
It can be a general module or a sheet module. It can be private or public.
Mine used a defined name for the range so you should change yours to
Cells([checksA].Rows.Count + 7, 1).Select
range("a" & cells(rows.count,"a").end(xlup).row).select
Then you should goto the regular (not vba help) HELP index and learn how the
INDEX function works to modify to suit your needs.

--
Don Guillett
SalesAid Software
(e-mail address removed)
David M said:
Thanx Don...do I copy this into the VB editor into the
General section for the datasheet name private sub or just
sub...forgive the unclearity because I am new to writing
VBA code..getting better bur still very much newbie..

D
-----Original Message-----
this might give you an idea
Sub newline()
Cells([checksA].Rows.Count + 7, 1).Select
With ActiveCell
..Offset(0) = .Offset(-1)
..Offset(0, 4) = 1
End With
End Sub

--
Don Guillett
SalesAid Software
(e-mail address removed)
Hello,

In my data sheet, I have a series of formulas that need to
be copied for each record entered. Sine this document
lives and grows each day, I enter my initial data, date,
incident number etc, then I take the above row , select H
thru AG and copy it down to the next row to perform the
functions for that entry...I would like to be able to have
a Macro or a funtion to do this so I won't have to select
then drag down. Any ideas on how I can do this by clicking
a button?

Thanx

David


.
 
Oaky...just so I am clear .... learn better with a
visual....I know it is simple and I am trying to get past
my fear of programming...getting there but not quite yet..

If I want to create a macro using your code to select and
copy H2-AE2 down to H3-AE3, what would it look like....I

Thanx

D
-----Original Message-----
It can be a general module or a sheet module. It can be private or public.
Mine used a defined name for the range so you should change yours to
Cells([checksA].Rows.Count + 7, 1).Select
range("a" & cells(rows.count,"a").end(xlup).row).select
Then you should goto the regular (not vba help) HELP index and learn how the
INDEX function works to modify to suit your needs.

--
Don Guillett
SalesAid Software
(e-mail address removed)
Thanx Don...do I copy this into the VB editor into the
General section for the datasheet name private sub or just
sub...forgive the unclearity because I am new to writing
VBA code..getting better bur still very much newbie..

D
-----Original Message-----
this might give you an idea
Sub newline()
Cells([checksA].Rows.Count + 7, 1).Select
With ActiveCell
..Offset(0) = .Offset(-1)
..Offset(0, 4) = 1
End With
End Sub

--
Don Guillett
SalesAid Software
(e-mail address removed)
"David M" <[email protected]> wrote
in
message
Hello,

In my data sheet, I have a series of formulas that
need
to
be copied for each record entered. Sine this document
lives and grows each day, I enter my initial data, date,
incident number etc, then I take the above row ,
select
H
thru AG and copy it down to the next row to perform the
functions for that entry...I would like to be able to have
a Macro or a funtion to do this so I won't have to select
then drag down. Any ideas on how I can do this by clicking
a button?

Thanx

David


.


.
 
Back
Top