Quantcast
Channel: Visual C forum
Browsing all 15302 articles
Browse latest View live

How to keep client socket connection open with winsock?

I'm trying to understand this standard socket example: // Receive data until the server closes the connection do { iResult = recv(ConnectSocket, recvbuf, recvbuflen, 0); if (iResult > 0)...

View Article


Can't compile with boost::log (Visual Studio 2013 Preview)

I can't compile my program, which uses boost::log. I'm using the Microsoft Visual Studio 2013 Preview.I can compile this same code (I'm developing on linux, mac, and windows) on Linux with g++ without...

View Article


can`t set an owner to file Question

Hello, guys. I`m trying to set owner to file using SetFileSecurity function.  but I can`t complete my task due to a error. Error code is 5. (no access) Look below the code hFile = CreateFile(filename,...

View Article

Any faster method to retrieve data instead of using GetFieldValue?

Hi,I'm using basic way to retrieve data, however it is too slow when i try to get more data, is there any better method? Here is my codes, ThanksszTSql.Format("SELECT TOP 3000 Id, Code, Class FROM...

View Article

How to accomplish something with editgrid?

I'm doing a simple interface with C++ MFC, and I want to add a table in it. I don't know which control shoud I use. Should I use EditGrid or something else? Could somebody help me? Thank you.

View Article


how to transfer files through wifi in MFC

how to transfer files through  wifi in MFC

View Article

How to establish a client websocket connection with winsock?

I have two functions for creating a socket and handshaking with a server:BOOL websocket::create() { int att = 0; // Initialize Winsock WSADATA wsaData; res = WSAStartup(MAKEWORD(2,2), &wsaData); if...

View Article

Thread/process atomicity of WriteFile() for files opened for append

Hi, We use the following Win32 API call sequence: // constructor code DWORD flagsAndAttributes = FILE_ATTRIBUTE_NORMAL | FILE_FLAG_WRITE_THROUGH; If ( useBufferedWrites ) {  flagsAndAttributes =...

View Article


How to make communication in different dialogues in MFC dialogue based...

In my MFC dialogue based application one situation is that first I open modeldialogue and click event of one of button of this dialogue ,it open main dialogue which contains Initinstance and...

View Article


LINK.EXE internal buffer size

Hello,We are working on an application built in using Perforce Jam and Visual Studio 6. My work consists in the compiler migration (from VC6 to VS2010). For one DLL, I have a bug with the VS2010 linker...

View Article

How do i except runtime DLLs from this Anti DLL Injection code?

Hello everyone, I am going to make a anti dll injection in order to protect my game client,but whenever i tried to use this code, some of runtime game dll will not be loaded, and the game will be...

View Article

#import .tlb file make compile error in a specific configuration and specific...

HiI make import in stdafx.h//----- Inventor interfaces include#pragmawarning(disable:4192 4049)#import<RxInventor.tlb>  rename_namespace("Inventor") named_guids raw_dispinterfaces...

View Article

Icon Shell Extension

Dear all,I want to make a shell extension that can display a single file as more than 1 icon. In other words, I want the .txt files to appear as 2 different icons (while it's only just 1 physical file...

View Article


send email from mfc application without involving OutLook

Hi  I want to send email directly from my mfc application without involving OutLook i also want to be able to send attachment any ideas will be appreciated 

View Article

C++ How to suppress *.lib automatically when I need to rebuild in debug or...

When I want to debug my application, I build in debug and I need to build my library in debug also. I cannot link my application in debug with the library in release because of the known run time link...

View Article


How can I find the source and destination port of a packet using Wininet?

Hi All,I wish to find the Source and Destination Port of a Packet (at the time of browsing) using Wininet. Is there any API do this or any sample code available?Thanks in advance.R-VR

View Article

Need help with SHA-1

I have two problems with the following code:1. This call returns the value of hashLen = 4 instead of 20 for SHA1CryptGetHashParam(hHash, HP_HASHSIZE, NULL, &hashLen, 0)2. The return value that I...

View Article


Reading a russian/english charecters

Hi,I have VS2012, using windows 8 Pro, and I am developing native c++, using MFC, a program to read a txt file which has english and russian text. The Russian text is coming out weird. The text file...

View Article

dialects of C++

was reading this: http://andrewgarrison.com/blog/porting-an-ios-app-to-windows-8/the code:void ReadFile(Platform::String^ fileName) { using namespace Windows::Storage; using namespace Concurrency; //...

View Article

VIsual C++ 2012: Can you compile MFC DLL/Library from source code?

I am curious if it's possible to compile the MFC source code to DLL/Library from what is provided with the Visual C++ 2012 install.If so, where would I find this information?Hoody Hoo!

View Article
Browsing all 15302 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>