FIX: @ ... GET Check Box with a "" Prompt Causes GP Fault

ID: Q108712

2.50 2.50a 2.50b WINDOWS kbprg kbfixlist kbbuglist

The information in this article applies to:

SYMPTOMS

FoxPro for Windows causes a general protection (GP) fault when calling a valid function that contains a null string in the PROMPT clause.

RESOLUTION

To avoid this error, place a blank space between the quotation marks after the PROMPT clause. For example:

   SHOW OBJECT 2 PROMPT " "

STATUS

Microsoft has confirmed this to be a problem in FoxPro versions 2.5, 2.5a, and 2.5b for Windows. This problem has been corrected in FoxPro version 2.6 for Windows.

MORE INFORMATION

Steps to Reproduce Problem

WARNING: Close all running applications and save your data before running this code.

   CLEAR
   @ 5,5 GET check1;
      FUNCTION '*C \<Check this box twice to reproduce error';
      SIZE 2,8;
      VALID v1();
      DEFAULT 0
   @ 10,5 GET check2;
      FUNCTION '*C \<Test';
      SIZE 2,8;
      DEFAULT 0
   READ CYCLE
   CLEAR
   RETURN

   FUNCTION v1
   SHOW OBJECT 2 PROMPT ""   && Remark this line and un-remark the next
   *SHOW OBJECT 2 PROMPT " "   && to correct the problem.
   RETURN .T.

Additional reference words: FoxWin 2.50 2.50a 2.50b buglist2.50 buglist2.50a buglist2.50b checkbox gpf prompt valid fixlist2.60 KBCategory: kbprg kbfixlist kbbuglist KBSubcategory: FxprgGeneral Solution Type : kbfix

Last Reviewed: October 14, 1997