## wxURLDataObject

wxURLDataObject is a wxDataObject containing an URL and can be used e.g. when you need to put an URL on or retrieve it from the clipboard:

        wxTheClipboard->SetData(new wxURLDataObject(url));

Derived from

Under MSW:

wxDataObjectComposite
wxDataObject

Under the other platforms:

wxTextDataObject
wxDataObjectSimple
wxDataObject

Include files

<wx/dataobj.h>

See also

Clipboard and drag and drop overview,
wxDataObject

Members

wxURLDataObject::wxURLDataObject
wxURLDataObject::GetURL
wxURLDataObject::SetURL

### wxURLDataObject::wxURLDataObject

wxURLDataObject(const wxString& url = wxEmptyString)

Constructor, may be used to initialize the URL. If url is empty, SetURL can be used later.

### wxURLDataObject::GetURL

wxString GetURL() const

Returns the URL stored by this object, as a string.

### wxURLDataObject::SetURL

void SetURL(const wxString& url)

Sets the URL stored by this object.