Hello all,
I have made one formula field namely OrderQty and its formula contains the simple airithmatic operations using the fields of stored procedure itself,but when i am trying to run the report i got the following error
"The String Is Non-Numeric"
Formula field's formula is as shown below....
stringVar OrderQty;
WhilePrintingRecords;
If {spSelectAutoPOItem.StandardPackingQty}>0 Then
If CDbl ({spSelectAutoPOItem.OrderQty}) > CDbl({spSelectAutoPOItem.ViableOrderQty}) And CDbl({spSelectAutoPOItem.ViableOrderQty}) > 0 Then
If {spSelectAutoPOItem.StandardPackingQty} Mod Cdbl( {spSelectAutoPOItem.ViableOrderQty}) = 0 Then
If CDbl({spSelectAutoPOItem.ViableOrderQty}) > {spSelectAutoPOItem.StandardPackingQty} Then
OrderQty := CStr({spSelectAutoPOItem.ViableOrderQty}) + {spSelectAutoPOItem.StockUnit}
Else
OrderQty := CStr({spSelectAutoPOItem.StandardPackingQty}) + {spSelectAutoPOItem.StockUnit}
Else
OrderQty := Cstr({spSelectAutoPOItem.StandardPackingQty}) + "/" + CStr({spSelectAutoPOItem.StandardPackingQty} * 2) + {spSelectAutoPOItem.StockUnit}
Else
If {spSelectAutoPOItem.StandardPackingQty} Mod CDbl({spSelectAutoPOItem.OrderQty}) = 0 Then
If CDbl ({spSelectAutoPOItem.OrderQty}) > {spSelectAutoPOItem.StandardPackingQty} Then
OrderQty := {spSelectAutoPOItem.OrderQty}
Else
OrderQty := CStr({spSelectAutoPOItem.StandardPackingQty}) + {spSelectAutoPOItem.StockUnit}
Else
OrderQty := CStr((CDbl({spSelectAutoPOItem.ViableOrderQty}) - CDbl ({spSelectAutoPOItem.OrderQty})) + CDbl ({spSelectAutoPOItem.OrderQty})) + "/" + CStr({spSelectAutoPOItem.StandardPackingQty} * 2) + {spSelectAutoPOItem.StockUnit}
Else
If CDbl ({spSelectAutoPOItem.OrderQty}) > CDbl({spSelectAutoPOItem.ViableOrderQty}) And ToNumber({spSelectAutoPOItem.ViableOrderQty}) > 0 Then
OrderQty := CStr(CDbl({spSelectAutoPOItem.ViableOrderQty})) + {spSelectAutoPOItem.StockUnit}
Else
OrderQty := {spSelectAutoPOItem.OrderQty};
OrderQty
Please do help me,it will be a favour for me....
Thanks in advance,waiting for the reply.....