Hello. I am using InternetWriteFile API to upload a file in site of my own IIS(i.e. on my own PC). The name of the file to upload is uploaded.txt which is 25 bytes in size. But when I see the directory of my website then it show name of the file & it's size is zero bytes. Why aren't the contents of the source file written. I've all the rights.
So whats the problem?
I am sending attached file for win32 project. IF IT DOESN'T HAPPEN BCUZ OF FIREWALL, THEN I am sending source code of the function which uses this API.
////// function body starts //////////
void MyhttpSendRequestWrite(HWND hwnd){
HINTERNET hInternetSession, hURL, hConnect, hHttpRequest;
char buff[3000] = "This is the uploaded file";
DWORD bytesWritten = 10, dwContext, err;
I want information on InternetWriteFile not HttpSendRequest. InternetWriteFile is not working & giving this error ERROR_INTERNET_INCORRECT_HANDLE_STATE.
If u can modify my code or u can give me a small code whose InternetWriteFile API works correctly then plz post.
Sorry ,My english is pool.....
I use above code to write file to http server,but receive 401.3 error,ACL not allow me to write.
So I use Administrator to write ,but the error still occurs,why?Someone can help me?
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.