sql.Format("insert   into   Grade   values(%d,'%s','%s',%f)", i, p1, p2, f); 

解决方案 »

  1.   

    太谢谢了楼上的啦,我搞了几个小时都没搞出来,嘿嘿 !!~
    还有个问题,UpdateData()这个函数在什么时候返回的为真啊!
      

  2.   

    virtual BOOL OnInitDialog( );
    Specifies whether the application has set the input focus to one of the controls in the dialog box. If OnInitDialog returns nonzero, Windows sets the input focus to the first control in the dialog box. The application can return 0 only if it has explicitly set the input focus to one of the controls in the dialog box.
      

  3.   

    UpdateData()
    函数执行正确时返回真
    一般不用考虑这个