Im trying to create a boost thread which executes the following static function.

Updater::UpdateTrack(const std::string& sFolder)
{
  //Do something
}

I cant seem to figure out how to pass the argument to the function i tried the following:

m_UpdateThread = boost::thread(&Updater::UpdateTrack,"test");
m_UpdateThread = boost::thread(boost::bind(&Updater::UpdateTrack,"test"));

Hope someone can point me in the right direction

m_UpdateThread = boost::thread(&Updater::UpdateTrack,"test");

Did work after all im sorry i must of messed something up

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.