# Calculate String Length > [HTML Version](calculatestringlength.htm) **xcall MIAMEX, MX\_GDICALC, MXGDI\_CALCLEN, handle, status, memo, length** The MXGDI\_CALCLEN operation is similar to MXGDI\_CALCRECT, except that it just determines how long the string will be when printed—i.e. does not consider the possibility of wrapping it to multiple lines. | **Parameter** | **Type** | **I/O** | **Description** | |------|------|------|------| | handle | B,4 | in | Device context handle (from MXGDI\_OPEN) | | status | F6 | out | [MX\_GDICALC Status Codes](mx_gdicalcstatuscodes.htm.md). | | memo | [String](string.htm.md) | in | Text string to consider. Should not contain any CRLF characters. | | length | Num | out | Returns the length (i.e. width) required to print _memo_ text in the current font and device context, in the _mapmode_ units specified in the MXGDI\_OPEN operation. |