Helix Core is now P4. Product user interfaces will be updated soon. Learn more >>

C/C++ API Documentation | 2025.2

# StrPtr::Text()

Return the `char *` containing this `StrPtr`'s text.

Virtual? | No |
Class | `StrPtr` |
Arguments | None |
Returns | `char *` | This `StrPtr`'s buffer

## Notes

`StrPtr::Text()` and `StrPtr::Value()` are exactly equivalent. Their most typical use is converting a `StrPtr` to a `char *` for functions outside of the client API to use.

## Example

Copy

    #include &lt;stdhdrs.h&gt;
    #include &lt;strbuf.h&gt;

    int main( int argc, char **argv )
    {
        StrBuf str1;

        str1.Set( "the quick brown fox jumps over the lazy dog" );

        printf( "%s\n", str1.Text() );

        return 0;
    }

Executing the preceding code produces the following output:

    the quick brown fox jumps over the lazy dog

Your search for returned results