主题:利用MoveBy实现查找功能的问题
本来的构想是,从一个Edit输入一个整数,点击button,执行在数据库中的查找。
代码,如下
void __fastcall TForm1::Button7Click(TObject *Sender)
{
Edit1-> Text;
Table1->MoveBy(Text-1);
}
编译,运行都没有毛病,但只要一使用这个共能,就有如下,错误提示:
Project Project1.exe raised exception class EVariantTypeCastError with
message 'Could not convert variant fo type (String) into type (Double)'.
Process stopped. Use Step or Run to continue.
不能把String转换成Double,初学乍练,哪位高人,给说说应该怎么办??
代码,如下
void __fastcall TForm1::Button7Click(TObject *Sender)
{
Edit1-> Text;
Table1->MoveBy(Text-1);
}
编译,运行都没有毛病,但只要一使用这个共能,就有如下,错误提示:
Project Project1.exe raised exception class EVariantTypeCastError with
message 'Could not convert variant fo type (String) into type (Double)'.
Process stopped. Use Step or Run to continue.
不能把String转换成Double,初学乍练,哪位高人,给说说应该怎么办??