
Hi, I'm trying to bind Win32 API function RegCloseKey like this (I'm using VC 2005 Express): HKEY hKey; //--initialize hKey boost::function<LONG(void)> RegClose = boost::bind(&RegCloseKey, hKey); And I got the following error : 1>e:\kamil\library\boost\bind.hpp(66) : error C2825: 'F': must be a class or namespace when followed by '::' 1> e:\kamil\library\boost\bind\bind_template.hpp(15) : see reference to class template instantiation 'boost::_bi::result_traits<R,F>' being compiled 1> with 1> [ 1> R=boost::_bi::unspecified, 1> F=long (__stdcall *)(HKEY) 1> ] 1> e:\kamil\personal\function\function.cpp(10) : see reference to class template instantiation 'boost::_bi::bind_t<R,F,L>' being compiled 1> with 1> [ 1> R=boost::_bi::unspecified, 1> F=LONG (__stdcall *)(HKEY), 1> L=boost::_bi::list1<boost::_bi::value<HKEY >> 1> ] 1>e:\kamil\library\boost\bind.hpp(66) : error C2039: 'result_type' : is not a member of '`global namespace'' 1>e:\kamil\library\boost\bind.hpp(66) : error C2146: syntax error : missing ';' before identifier 'type' 1>e:\kamil\library\boost\bind.hpp(66) : error C2208: 'boost::_bi::type' : no members defined using this type 1>e:\kamil\library\boost\bind.hpp(66) : fatal error C1903: unable to recover from previous error(s); stopping compilation Any idea how to fix this ? ____________________________________________________________________________________ Building a website is a piece of cake. Yahoo! Small Business gives you all the tools to get online. http://smallbusiness.yahoo.com/webhosting