Trying to work with the C ++ curl library in the windows form C ++ project
CURL *curl; CURLcode result; //инициализируем curl curl = curl_easy_init(); On the line curl = curl_easy_init(); errors start as if lib is not connected. In the windows form, how else do the lib components connect? Connected through the program and the project settings did not help. visual studio 2010 C ++ /
1> CurlFormTest.obj: error LNK2031: Could not create P or Invoke for "extern" C "enum CURLcode __clrcall curl_global_init (long)" (? Curl_global_init @@ $$ J0YM? AW4CURLcode @@ J @ Z); there is no calling agreement in the metadata
1> CurlFormTest.obj: error LNK2028: link to the unresolved (0A00001A) lexeme "extern" C "enum CURLcode __clrcall main (cli :: array ^) "(? main @@ $$ HYMHP $ 01AP $ AAVString @ System @@@ Z)
When they answered my question, everything turned out, but when I ran into such a problem again I forgot how to fix it and read again the answer was difficult to find the right setting, so I decided for myself and others to make a graphical hint, here.
After setting the curl works. Attention for Debug and Ralase Nasta need to separately. In my opinion it is better to choose realase
WebClient,WebRequest,HttpClient, and RestSharp classes instead. - Alexander Petrovcurl_global_init(CURL_GLOBAL_ALL), and see if it returns an error. - enshirokov 5:02 pm