---
name: "XmTextFieldGetStringWcs"
section: "3"
platform: "linux"
package: "openmotif"
version: "2.3.8-4"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/XmTextFieldGetStringWcs"
---

# XmTextFieldGetStringWcs(3)

A TextField function that retrieves a copy of the wide character string value of a TextField widget

## NAME

**XmTextFieldGetStringWcs** — A TextField function that retrieves a copy of the wide character string value of a TextField widget

## SYNOPSIS

```
#include <Xm/TextF.h>
wchar_t * XmTextFieldGetStringWcs(
Widget widget);
```

## DESCRIPTION

**XmTextFieldGetStringWcs** retrieves a copy of the wide character string value of the TextField widget. The application is responsible for freeing the storage associated with the string by calling **XtFree**.

- *widget*

  Specifies the TextField widget ID

For a complete definition of TextField and its associated resources, see [**XmTextField**(3)](/XmTextField/3.md).

## RETURN

Returns the wide character string value of the TextField widget. The function returns an empty string if the length of the TextField widget's string is 0 (zero).

## RELATED

[**XmTextField**(3)](/XmTextField/3.md) and [**XmTextFieldGetString**(3)](/XmTextFieldGetString/3.md).
