Stclements1
Board Regular
- Joined
- Sep 15, 2018
- Messages
- 150
- Office Version
- 365
- Platform
- Windows
I am not sure what the protocol on this site in terms of asking questions and how many per thread. I have two questions and if I have broken protocol then I apologise and if informed so will send a new thread with the seond question.
Q1 In cell E3 I have this code =IF(C2>0;D2+F2;TODAY()), Cell C2 has a value of 0 or 1, 0 meaning that the trade is open and 1 meaning it's closed. D2 is the date that determines the start date of a trade, and F2 calculates the differnec between the start date and the todays date, but when the value in C2 becomes 1 I want E2 to stop counting todays date and display the date at the point C2 changed value from 0 to 1. The code above doesn't seem to work.
Q2 If I have a spreadsheet that is ultimatley a monthly template that has multiple formulas and text data is it possible to somehow copy the spreadsheet data into a VBA module so it effectively writes the source code so that I have a macro that each month I can open a blank spreadsheet and just run the recorded macro, or do I have to input all the active cells and ranges individually?
Q1 In cell E3 I have this code =IF(C2>0;D2+F2;TODAY()), Cell C2 has a value of 0 or 1, 0 meaning that the trade is open and 1 meaning it's closed. D2 is the date that determines the start date of a trade, and F2 calculates the differnec between the start date and the todays date, but when the value in C2 becomes 1 I want E2 to stop counting todays date and display the date at the point C2 changed value from 0 to 1. The code above doesn't seem to work.
Q2 If I have a spreadsheet that is ultimatley a monthly template that has multiple formulas and text data is it possible to somehow copy the spreadsheet data into a VBA module so it effectively writes the source code so that I have a macro that each month I can open a blank spreadsheet and just run the recorded macro, or do I have to input all the active cells and ranges individually?