2017년 4월 21일 금요일

Age Calculation - Age not reflecting correctly - aia attached.


I am trying to calculate age between two days. I've already checked one post and found the attached aia file which is almost working fine. It doesn't show the correct age when there is an increase in age and then a decrease. For ex: 1st time I give my age as 14/04/1987 - It gives correct age. Second Time when I enter some date like 01/01/1965. Here also I get the correct age. But for the third time when I give 01/01/1971 it doesn't show the correct age - The age is increased by 1 (Years = Years + 1 logic is triggered) of the previous age. 
Can you plz rectify the blocks... 


--
If you are asking for help, I recommend you to make it as easy for others to be able to help you ...
You probably will get more feedback then...

which means in your case post a screenshot of your relevant blocks...

To download the aia file, upload it to  App Inventor, open it, do some bug hunting for you, etc... this takes time, and most people will not do that...

-- 
This is a proper app to use ...

Also see the accompanying comments in this board.

Calendar time does not flow smoothly,
so don't be surprised at anomalies,
where time can seem to flow faster
in one direction between dates versus
the opposite direction, depending on
how you count it.

Date differences vary even by legal jurisdiction.

-- 
Sorry for that... Attached is the screenshot. 


-- 
I hope this helps you. I used text manipulation to do it. If you have a question, feel free to ask.


-- 
This version is easier to understand but not as accurate as the previous one. It may be off by a year some time. You chose which approach you like best. Thank you for giving me the opportunity to help.


-- 
Perfect Solution. 
Thank u very much :)

-- 

댓글 없음:

댓글 쓰기