菜鸟问:如何解决might not have been initialized问题?(我没分了,见谅)
procedure TForm1.ComboBox2Change(Sender: TObject);
var c:integer;
begin
if edit11.Text<>''
then
c:=strtoint(edit11.Text)*strtoint(combobox2.Text);
edit12.Text:=inttostr(c);
end;
错误提示:
[Warning] Unit1.pas(315): Variable 'c' might not have been initialized
==================
我查到了是这个意思:但我还是不知道怎么避免,请教我~~
Variable '<Name>' might not have been initialized 变量名<NAME>可能没有初始化