#define STRICT
#define _AFXDLL
#include "stdafx.h"
#include <tchar.h>
#include <AFXWIN.H>
#include <windows.h>
#include "Serial\Serial\Serial.h"
#include "Serial\Serial\SerialEx.h"
#include "Serial\Serial\SerialMFC.h"
#include "Serial\Serial\SerialWnd.h"
int WINAPI_tWinMain
(
HINSTANCE //hInst
HINSTANCE //hInstPrev
int
)
{
CSerial serial;
serial.Open(_T("COM4"));
serial.Setup (CSerial::EBaud9600, CSerial::EData8, CSerial::EParNone, CSerial::EStop1);
CSerial::SetupHandshaking;
serial.Write("Hello World");
serial.Close();
return 0;
}
along with the error code..
1>------ Build started: Project: SerialComm, Configuration: Debug Win32 ------
1> stdafx.cpp
1> SerialWnd.cpp
1>c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serial\serial\serialwnd.cpp(23): warning C4603: 'STRICT' : macro is not defined or definition is different after precompiled header use
1> Add macro to precompiled header instead of defining here
1> c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serial\serial\serialwnd.cpp(24) : use of precompiled header
1>c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serial\serial\serialwnd.h(25): fatal error C1083: Cannot open include file: 'stdafx.h': No such file or directory
1> SerialEx.cpp
1>c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serial\serial\serialex.cpp(23): warning C4603: 'STRICT' : macro is not defined or definition is different after precompiled header use
1> Add macro to precompiled header instead of defining here
1> c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serial\serial\serialex.cpp(24) : use of precompiled header
1>c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serial\serial\serialex.h(26): fatal error C1083: Cannot open include file: 'stdafx.h': No such file or directory
1> Serial.cpp
1>c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serial\serial\serial.h(22): fatal error C1083: Cannot open include file: 'stdafx.h': No such file or directory
1> SerialComm.cpp
1>c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serialcomm.cpp(2): warning C4603: 'STRICT' : macro is not defined or definition is different after precompiled header use
1> Add macro to precompiled header instead of defining here
1> c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serialcomm.cpp(5) : use of precompiled header
1>c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serialcomm.cpp(3): warning C4603: '_AFXDLL' : macro is not defined or definition is different after precompiled header use
1> Add macro to precompiled header instead of defining here
1> c:\users\jonbecher\documents\visual studio 2012\projects\serialcomm\serialcomm\serialcomm.cpp(5) : use of precompiled header
1>c:\program files\microsoft visual studio 11.0\vc\atlmfc\include\afx.h(24): fatal error C1189: #error : Building MFC application with /MD[d] (CRT dll version) requires MFC shared dll version. Please #define _AFXDLL or do not use /MD[d]
1> Serial.cpp
1>c1xx : fatal error C1083: Cannot open source file: '..\Serial\Serial\Serial.cpp': No such file or directory
1> Generating Code...
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========







