Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Samir Ibrahim
  Where is Samir Ibrahim?
 Chekka
 Lebanon
 Samir Ibrahim
 To: Russell Hill
  Where is Russell Hill?
 Sydney
 Australia
 Russell Hill
 Tags
Subject: RE: Grid zeros
Thread ID: 188908 Message ID: 188912 # Views: 1 # Ratings: 0
Version: Visual FoxPro 9 Category: Grids
Date: Tuesday, August 12, 2008 3:34:54 PM         
   


> Hi all,
>
> When I use the following SQL SELECT as the source for a Grid, I get many zero values associated with CLAIM.
>
>
SELECT KEYID, NAME, WEIGHT, ALLOWANCE AS CLAIM, GROUPDEF ;
>   FROM &client_filename ;
>  WHERE CLIENTKEY = get_client ;
>   INTO CURSOR TempCursor

> By that I mean that the CLAIM column of the Grid might appear as follows:
>
>
....	CLAIM	....
> ....	  0.0	....
> ....	 -1.5	....
> ....	  0.0	....
> ....	  0.0	....
> ....	  0.0	....
> ....	 -2.0	....

> I want these 0.0 values to appear as "blanks", much like they do in Excel if Tools .. Options .. Zero Values is unchecked.
>
> I can get the required result by altering the SQL SELECT as follows:
>
>
SELECT KEYID, NAME, WEIGHT, IIF(ALLOWANCE=0,SPACE(4),STR(ALLOWANCE,4,1)) AS CLAIM, GROUPDEF ;
>   FROM &client_filename ;
>  WHERE CLIENTKEY = get_client ;
>   INTO CURSOR TempCursor

> but I would prefer to solve the issue at the Grid level if possible.
>
> Is there any property of a Grid I can use? If not, is there any way other than altering the SQL SELECT?
>
> Thanks,
>
> Russell.

SET NULLDISPLAY TO ' '

Samir R. Ibrahim
Good things Take time, Great things happend all at once.

My WebLog
My Website: www.cdcity.org

ENTIRE THREAD

Grid zeros Posted by Russell Hill @ 8/12/2008 3:20:14 PM
RE: Grid zeros Posted by Mustapha Bihmouten @ 8/12/2008 3:31:26 PM
RE: Grid zeros Posted by Russell Hill @ 8/12/2008 11:40:26 PM
RE: Grid zeros Posted by Samir Ibrahim @ 8/12/2008 3:34:54 PM
RE: Grid zeros Posted by Mustapha Bihmouten @ 8/12/2008 3:43:22 PM
RE: Grid zeros Posted by Samir Ibrahim @ 8/13/2008 9:42:28 AM
RE: Grid zeros Posted by surinder singh @ 8/12/2008 3:51:16 PM
RE: Grid zeros Posted by Mustapha Bihmouten @ 8/12/2008 4:06:57 PM
RE: Grid zeros Posted by Samir Ibrahim @ 8/13/2008 10:12:28 AM
RE: Grid zeros Posted by Samir Ibrahim @ 8/13/2008 10:29:08 AM
RE: Grid zeros Posted by Barbara Peisch @ 8/12/2008 8:52:30 PM
RE: Grid zeros Posted by Russell Hill @ 8/12/2008 11:40:00 PM