It is currently December 8th, 2021, 7:52 pm

## Nested Conditionals Limit

General topics related to Rainmeter.
Ben Hill
Posts: 20
Joined: November 30th, 2009, 1:05 am

### Nested Conditionals Limit

I know I saw some elite skinner mention this, but I can't find where.

I found that I could nest 8 conditionals, but 9 failed. (Nine ?'s, I guess that's nesting 8)

Is it correct that this is the limit in Rainmeter?
JamesAC
Developer
Posts: 318
Joined: July 14th, 2009, 5:57 pm

### Re: Nested Conditionals Limit

Ive found a similar issue, i managed 10 but couldnt do anymore.

This was my formula:

Code: Select all

``Formula=((E1D = MeasureDay) && (E1M = MeasureMonth) && (E1Y = MeasureYear)) ? 1 : (((E2D = MeasureDay) && (E2M = MeasureMonth) && (E2Y = MeasureYear)) ? 2 : (((E3D = MeasureDay) && (E3M = MeasureMonth) && (E3Y = MeasureYear)) ? 3 : (((E4D = MeasureDay) && (E4M = MeasureMonth) && (E4Y = MeasureYear)) ? 4 : (((E5D = MeasureDay) && (E5M = MeasureMonth) && (E5Y = MeasureYear)) ? 5 : (((E6D = MeasureDay) && (E6M = MeasureMonth) && (E6Y = MeasureYear)) ? 6 : (((E7D = MeasureDay) && (E7M = MeasureMonth) && (E7Y = MeasureYear)) ? 7 : (((E8D = MeasureDay) && (E8M = MeasureMonth) && (E8Y = MeasureYear)) ? 8 : (((E9D = MeasureDay) && (E9M = MeasureMonth) && (E9Y = MeasureYear)) ? 9 : (((E10D = MeasureDay) && (E10M = MeasureMonth) && (E10Y = MeasureYear)) ? 10 : 0 )))))))))``
+++ Divide By Cucumber Error. Please Reinstall Universe And Reboot +++
Quis custodiet ipsos custodes?
Ben Hill
Posts: 20
Joined: November 30th, 2009, 1:05 am

### Re: Nested Conditionals Limit

``Formula=((TotalTime>(#1stStartH#*60+#1stStartM#)) && (TotalTime<(#1stEndH#*60+#1stEndM#)))? 1 : (((TotalTime>(#2ndStartH#*60+#2ndStartM#)) && (TotalTime<(#2ndEndH#*60+#2ndEndM#)))? 2 : (((TotalTime>(#3rdStartH#*60+#3rdStartM#)) && (TotalTime<(#3rdEndH#*60+#3rdEndM#)))? 3 : (((TotalTime>(#4thStartH#*60+#4thStartM#)) && (TotalTime<(#4thEndH#*60+#4thEndM#)))? 4 : (((TotalTime>(#5thStartH#*60+#5thStartM#)) && (TotalTime<(#5thEndH#*60+#5thEndM#)))? 5 : (((TotalTime>(#LStartH#*60+#LStartM#)) && (TotalTime<(#LEndH#*60+#LEndM#)))? 0 : (((TotalTime>(#6thStartH#*60+#6thStartM#)) && (TotalTime<(#6thEndH#*60+#6thEndM#)))? 6 : (((TotalTime>(#7thStartH#*60+#7thStartM#)) && (TotalTime<(#7thEndH#*60+#7thEndM#)))? 7 : (((TotalTime>(#7thEndH#*60+#7thEndM#)))? 8 :9))))))))``