ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   need help please..... (https://www.excelbanter.com/excel-worksheet-functions/129138-need-help-please.html)

fiur

need help please.....
 
Hi my question are....
in cell A1 i type a number
that number should show up in cell (lets say c2)
When I type another number in A1 that number should show up in cell c3 and
so on.....

(the number in cell A1 is based on a calculation of several cells and will
change in a function of that calculation...)
The only thing I need answer on is: how to copy the current value of A1 over
to C1
and the new value of A1 into C2 and so on........

galimi

need help please.....
 
Code similar to the following on a sheet with the codename Sheet1 should do
what you want:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Row = 1 And Target.Column = 1 Then

Set Rng = Sheet1.Range("c2")

Do Until Rng.Value = ""
Set Rng = Rng.Offset(1)
Loop

Rng.Value = Target.Value

End If
End Sub
--
http://HelpExcel.com




"fiur" wrote:

Hi my question are....
in cell A1 i type a number
that number should show up in cell (lets say c2)
When I type another number in A1 that number should show up in cell c3 and
so on.....

(the number in cell A1 is based on a calculation of several cells and will
change in a function of that calculation...)
The only thing I need answer on is: how to copy the current value of A1 over
to C1
and the new value of A1 into C2 and so on........


fiur

need help please.....
 
Thanx alot for a quick reply!!!! wow
but I'm a newbie to this.... how do I "Code" on a sheet....
I can only add formulas and stuff never added "codes".....?

"galimi" wrote:

Code similar to the following on a sheet with the codename Sheet1 should do
what you want:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Row = 1 And Target.Column = 1 Then

Set Rng = Sheet1.Range("c2")

Do Until Rng.Value = ""
Set Rng = Rng.Offset(1)
Loop

Rng.Value = Target.Value

End If
End Sub
--
http://HelpExcel.com




"fiur" wrote:

Hi my question are....
in cell A1 i type a number
that number should show up in cell (lets say c2)
When I type another number in A1 that number should show up in cell c3 and
so on.....

(the number in cell A1 is based on a calculation of several cells and will
change in a function of that calculation...)
The only thing I need answer on is: how to copy the current value of A1 over
to C1
and the new value of A1 into C2 and so on........


fiur

need help please.....
 
Okay I manage to figure out how to add that code.... but here is another
question....
the value is based on two other condition :
lets say it will be like this:
A1=1 A2=2 then copy the value in C2 into D1
A1=1 A2=3 then copy the value in C2 into D2
A1=2 A2=1 then coopy the value in C2 into D3
and so on.........
How do I do that ???

"galimi" wrote:

Code similar to the following on a sheet with the codename Sheet1 should do
what you want:

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Row = 1 And Target.Column = 1 Then

Set Rng = Sheet1.Range("c2")

Do Until Rng.Value = ""
Set Rng = Rng.Offset(1)
Loop

Rng.Value = Target.Value

End If
End Sub
--
http://HelpExcel.com




"fiur" wrote:

Hi my question are....
in cell A1 i type a number
that number should show up in cell (lets say c2)
When I type another number in A1 that number should show up in cell c3 and
so on.....

(the number in cell A1 is based on a calculation of several cells and will
change in a function of that calculation...)
The only thing I need answer on is: how to copy the current value of A1 over
to C1
and the new value of A1 into C2 and so on........


Bernd

need help please.....
 
Hello,

Select cells D1:D999, for example, and insert as array formula:
=IF(ROW(INDIRECT("1:999"))=$A$1*3+$A$2-4,$C$2,"")

[enter with CTRL + SHIFT + ENTER]

Please notice that all other cells in column D will be reset to "" if
corresponding condition of A1:A2 does not apply.

Regards,
Bernd


fiur

need help please.....
 
ty do you know how I keep the other cells in "d" ??

"Bernd" wrote:

Hello,

Select cells D1:D999, for example, and insert as array formula:
=IF(ROW(INDIRECT("1:999"))=$A$1*3+$A$2-4,$C$2,"")

[enter with CTRL + SHIFT + ENTER]

Please notice that all other cells in column D will be reset to "" if
corresponding condition of A1:A2 does not apply.

Regards,
Bernd



Bernd

need help please.....
 
Hello,

You will need a macro then, I think.

Regards,
Bernd



All times are GMT +1. The time now is 01:34 PM.

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