我可以帮助您翻译中文,本文涉及IT技术。您需要编写一个函数,它接受一个类名并返回相应的TClass。我注意到,如果未注册该类名,则System.Classes.GetClass函数不起作用。
例子:
之前的代码总是显示:
例子:
if(GetClass('TButton') = nil)
then ShowMessage('TButton not found!')
else ShowMessage('TButton found!');
之前的代码总是显示:
有什么遗漏吗?找不到TButton!