The object at dereference depth 1 is being used before it was constructed/allocated. Please make sure that the object is allocated before using it

Why do you use “;” without “begin…end” ?