Note that there are some explanatory texts on larger screens.

plurals
  1. PODisplaying a value in a text box-Error
    text
    copied!<p>I have size_t sums[4] = {0, 0, 0, 0};</p> <p>and a text box in which I am trying to display the value that I get after I've done some operations on it. The value is in sums[i] , however now I want to display the value in the textbox, I am doing this:</p> <pre><code> *TextBox4 &lt;&lt; "hello" &lt;&lt; size_t sums; frame-&gt;Connect(TEXT_BOX4, wxEVT_COMMAND_BUTTON_CLICKED | wxEVT_COMMAND_ENTER, (wxObjectEventFunction) &amp; MyFrame::OnGenerateKey); TextBox4 = new wxTextCtrl(this, TEXT_BOX4, wxT(""), wxPoint(200, 200), wxSize(200, 20), wxTE_PROCESS_ENTER | wxTE_READONLY | wxTE_LEFT, wxDefaultValidator, wxT("WxTextBox4")); </code></pre> <p>however it generates the following errors</p> <pre><code> base.cpp:212:22: error: ambiguous overload for 'operator&lt;&lt;' in '*((MyFrame*)this)-&gt;MyFrame::TextBox4 &lt;&lt; sum' base.cpp:212:22: note: candidates are: C:\wxWidgets-2.8.12\include/wx/textctrl.h:419:17: note: wxTextCtrl&amp; wxTextCtrlBase::operator&lt;&lt;(const wxString&amp;) C:\wxWidgets-2.8.12\include/wx/textctrl.h:420:17: note: wxTextCtrl&amp; wxTextCtrlBase::operator&lt;&lt;(int) C:\wxWidgets-2.8.12\include/wx/textctrl.h:421:17: note: wxTextCtrl&amp; wxTextCtrlBase::operator&lt;&lt;(long int) C:\wxWidgets-2.8.12\include/wx/textctrl.h:422:17: note: wxTextCtrl&amp; wxTextCtrlBase::operator&lt;&lt;(float) C:\wxWidgets-2.8.12\include/wx/textctrl.h:423:17: note: wxTextCtrl&amp; wxTextCtrlBase::operator&lt;&lt;(double) C:\wxWidgets-2.8.12\include/wx/textctrl.h:424:17: note: wxTextCtrl&amp; wxTextCtrlBase::operator&lt;&lt;(wxChar) </code></pre> <p>Please help me.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload