ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Memory In Excel? (https://www.excelbanter.com/excel-programming/332848-memory-excel.html)

TrippinAnts22

Memory In Excel?
 

Hey all. I have been using excel for some time, but have just started
getting into the programming and other sides of Excel. For a spread
sheet that I am working on, I currently get updated prices sent to me
every week and it is about 80 prices. What I would like to do is every
week when I get the sheet and have it update other things automatically,
I would like it to store the price in one column, and then update the
price in another column, and take the differential. Is this possible?

Example:

Stock Prices I get on 6/13 - store in Current Stock Price
Stock Prices I get on 6/20 - store in Current Stock Price, and move
6/13 to last week. I then want to subtract the two.
When 6/27 comes, I want to delete 6/13, move 6/20 to where 6/13 was,
and move 6/27 to 6/20. Is that possible?

Or, is it possible to take the date, and convert it somehow to a
number, and say if column A is less than column B,copy column B to
column A? if so could someone explain that as well. Thank you.

Thank you

Ben Farkas



--
TrippinAnts22
------------------------------------------------------------------------
TrippinAnts22's Profile:
http://www.excelforum.com/member.php...o&userid=24636
View this thread: http://www.excelforum.com/showthread...hreadid=382251


Mike NG

Memory In Excel?
 
On Sat, 25 Jun 2005 at 16:11:59, TrippinAnts22 (TrippinAnts22
) wrote:
Or, is it possible to take the date, and convert it somehow to a
number, and say if column A is less than column B,copy column B to
column A? if so could someone explain that as well. Thank you.

Dates are actually held as numbers - relative to the 1st Jan 1970 IIRC.
The decimal part then represents the time. Just assigning your date
variable to an integer variable should do the trick
--
Mike

TrippinAnts22[_2_]

Memory In Excel?
 

thanks, but how in a formula do you write something that says:


if date is less than another date, copy?
iknow the if statements, but how do you make it copy?


--
TrippinAnts22
------------------------------------------------------------------------
TrippinAnts22's Profile: http://www.excelforum.com/member.php...o&userid=24636
View this thread: http://www.excelforum.com/showthread...hreadid=382251


Mike NG

Memory In Excel?
 
On Sat, 25 Jun 2005 at 23:32:34, TrippinAnts22 (TrippinAnts22
) wrote:

thanks, but how in a formula do you write something that says:


if date is less than another date, copy?
iknow the if statements, but how do you make it copy?


Sorry you need to do this in visual basic

e.g. WorkSheets("Sheet1").Cells(1,1) = WorkSheets("Sheet2").Cells(1,1)


I do some share manipulation where my shares spreadsheet opens another
workbook, then I prefix WorkSheets with something like
WorkBooks("Prices") - Prices being the name of the XLS file containing
the new share data
--
Mike

TrippinAnts22[_3_]

Memory In Excel?
 

sorry, so one more question with this, i use what you said in VBA, but
just doing that, it woudlnt work. To actually have it have the if
statements, can you explain to me what i do? Ihave used vba a few
times, but not too much to be able towrite scripts on my own.

THank you,

Ben


--
TrippinAnts22
------------------------------------------------------------------------
TrippinAnts22's Profile: http://www.excelforum.com/member.php...o&userid=24636
View this thread: http://www.excelforum.com/showthread...hreadid=382251



All times are GMT +1. The time now is 07:16 PM.

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