Yes. The Companies Act, 2008 (and its predecessor Companies Act, 1973) and Close Corporations Act, 1984 does not make a distinction between an active and inactive company or close corporation. Therefore, even if the company or close corporation was inactive, it is still legally required to file and pay annual returns.
Please note that the information provided does not constitute legal or professional advice, but rather the applicability of existing theory to a given practical situation. Due care is taken to ensure that the information is correct, but it remains subjective and an interpretation of application of information.