# Cannot seem to verify a statement on Excel

I have created an automated schedule maker but keep getting a blue dot and 0 (False) as a outcome of my IF statement..

The thing I am wondering is: Is it possible to have an IF statement where the false value gives you back the same result you initially begin with and are testing (within the same cell).

http://www.filedropper.com/swedbankschema

The sheet named "Real Test" and cell C2 is where my error is occurring.

Any tips or help will be deeply appreciated :)
###### Who is Participating?

Commented:
I don't think it is a good idea to use randbetween formulas to calculate this, because the list will change on every entry (calculation) in the sheet, even if it was possible to let the cell refer back to itself with a circular reference.
It is possible on very rare conditions (iteration convergence) to use circular reference, but normally the result is unpredictable, so I would never use it.

Here is another solution with a macro, where Shift Leader is found randomly, and Reserve also randomly, but excluding the already found Leader.
Accept macros on open.
It will only update the list when you press the button "Make new list".
With a twist, so all workers are assigned as uniformly as possible.
Meaning that all 7 workers are used once as Leader and Reserve every 7 days.

I have changed the formulas for Total Shifts, Total Reserve and Weekends in columns K to M.
Swedbank-Schema.xlsm
0

OwnerCommented:
C2 of Real Test has a circular reference
=(INDEX(\$I\$2:\$I\$8,RANDBETWEEN(1,COUNTA(\$I\$2:\$I\$8)),1)),IF(B2<>C2,INDEX(\$I\$2:\$I\$8,RANDBETWEEN(1,COUNTA(\$I\$2:\$I\$8)),1),E2)
0

Author Commented:
Completely makes sense.

You're correct, the constant change with every calculation was going to be my next step to solve.

I hadn't considered joining up K to M to what the schedule was giving me at the time...
My logic was all over the place now that I reflect upon my sheet.

Going to read up more on the statements used in your amended xlsm.
Stort tack till dig, hjälpte jättemycket! :)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.