title: unresolved external symbol "public: void __thiscall..."
body: <p>I'm using <code>boost::function</code> to enable the passing of a function to a <code>Button</code> constructor so it holds that function. Calling it whenever it is activated.</p>
  
  <pre><code>typedef boost::function&lt; void() &gt; Action;
  </code></pre>
  
  <p>In my TitleState I've constructed a Button like this.</p>
  
  <pre><code>  m_play( 
      ButtonAction, // This is where I pass a function to Button's Action argument
      sf::Vector2f( 500, 400 ), 
      sf::IntRect( 500, 400, 700, 500 ) 
    )
  </code></pre>
  
  <p>where ButtonAction is a <code>static void</code> function privately held in TitleState's header, defined in the implementation file as simply outputting to the console via std::cout (just as a test for whether it is working).</p>
  
  <p>In my code, if the mouse clicks a button in TitleState's <code>HandleEvents</code> function, the program calls that button's <code>Activate</code> function which looks like this.</p>
  
  <pre><code>void Button::Activate() const {
    m_action(); // m_action is the Action member that holds the ButtonAction I passed earlier
  }
  </code></pre>
  
  <p>The problem is that, when the program tries to link I get this error....</p>
  
  <p><code>unresolved external symbol "public: void __thiscall Button::Activate(void)" (?Activate@Button@@QAEXXZ) referenced in function "public: virtual void __thiscall TitleState::HandleEvents(void)" (?HandleEvents@TitleState@@UAEXXZ)</code></p>
  
  <p>I'm not sure what the problem is besides that the linker can't find the definition of the function. Everything is <code>#included</code> or declared properly. Any assistance is appreciated. Thanks.</p>
  
  <p>P.S. When I used the BoostPro installer, I only installed the single-threaded stuff and none of the multi-threaded stuff. Could this be a reason why it isn't working? I read that linker problems can occur when libraries are linking in different ways. If this could be an issue, I'll add that I'm also using the SFML library.</p>