Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using Procedural Code Within a Grid
Message
From
27/08/2002 12:46:16
Carmen Gassi
Perseus Software Systems
Oakville, Ontario, Canada
 
 
To
27/08/2002 12:15:02
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00694070
Message ID:
00694097
Views:
15
Hi Zlatin
Thank you for the suggestion, I believe this would work as well, but the table approach is quicker and codeless. Thanks for the suggestion.

Regards,
Carmen

>>Hello All
>> Is there a way to display a value in the column of a grid based on a case or an if..endif structure? For example, in my application, I am displaying the aged transaction history for customers. In the table, there is a field called "type" that describes the type of transaction in the A/R transaction file, "1" = Invoice, "2" = Adjustment, "8" = Cash Receipt, etc.. The data type is numeric. In the grid that displays the table, I would like to display "IN" if the type = 1, "CA" if the type = 8 etc. I do not know why the original designers of the application made this field numeric, I am converting this application from Clipper and would reduce my headaches a lot if I didn't have to mess too much with the tables. So is there a way to parse the value of the given field in the table and display the appropriate 2 character message. All suggestions appreciated.
>>
>>
>>Regards,
>>Carmen
>
>1. Create a property (to form, your grid class or your textbox class that you use in grid)
>2. Create Access method of this property in which to have your "Do CASE" code, (1-invoice, 2-Adjustment, etc.).
>3. Set the ControlSource of the column in which you want to display the value to the property
>
>HTH
Previous
Reply
Map
View

Click here to load this message in the networking platform