You are here: Tips and Tricks > Approch to Decoding a Field

Approach to Decoding a Field

Start by considering the size. If the size is not fixed then review the standard Size Methods to see if one will work. Remember that the FromField method allows you to pick up the size from another field including possibly a variable; this offers deep flexibility in calculating field sizes. If you still cannot obtain the required size then you will need to write your own custom Size Method.

Second, consider the value. Given that you have the size, can the data just be pulled out of the layer data? If it cannot then you need to use a Retrieval Method. Again consider the standard set before deciding that you need to write your own.

Only at this point should you consider formatting and verification. Be particularly careful when formatting numeric values that can be negative.