is there any function to identify whole number, field name and data type in progress4gl?
K kalaiarasan Member Oct 14, 2016 #1 is there any function to identify whole number, field name and data type in progress4gl?
ForEachInvoiceDelete Active Member Oct 14, 2016 #2 Might be me but i need a little more context. You can use the VST information to grab field information like name and data-type. If you're using buffers you can query attributes to get the information. ---- >Buffer-field object handle
Might be me but i need a little more context. You can use the VST information to grab field information like name and data-type. If you're using buffers you can query attributes to get the information. ---- >Buffer-field object handle
K kalaiarasan Member Oct 14, 2016 #3 Actually i am trying to identify Whole number (i.e) 15312 , 1, 1321324, 454 (may be one\more number of digits ) So is any function for Whole number ?
Actually i am trying to identify Whole number (i.e) 15312 , 1, 1321324, 454 (may be one\more number of digits ) So is any function for Whole number ?
Rob Fitzpatrick ProgressTalk.com Sponsor Oct 14, 2016 #4 kalaiarasan said: Actually i am trying to identify Whole number (i.e) 15312 , 1, 1321324, 454 (may be one\more number of digits ) Click to expand... I assume you're looking for whole numbers in decimals. Try this: Code: function isWhole returns logical (p-dec as decimal): return (p-dec >=0 and p-dec = truncate( p-dec, 0 ) ). end function. display isWhole( 3.5 ) /* no */ isWhole( 4 ) /* yes */ isWhole( -1 ) /* no */ isWhole( 0 ) /* yes */ . ┌───────────────┐ │no yes no yes│ └───────────────┘
kalaiarasan said: Actually i am trying to identify Whole number (i.e) 15312 , 1, 1321324, 454 (may be one\more number of digits ) Click to expand... I assume you're looking for whole numbers in decimals. Try this: Code: function isWhole returns logical (p-dec as decimal): return (p-dec >=0 and p-dec = truncate( p-dec, 0 ) ). end function. display isWhole( 3.5 ) /* no */ isWhole( 4 ) /* yes */ isWhole( -1 ) /* no */ isWhole( 0 ) /* yes */ . ┌───────────────┐ │no yes no yes│ └───────────────┘