2 |
|
// |
3 |
|
// Douglas Thrift |
4 |
|
// |
5 |
< |
// $Id: VTBFileUtil2.h,v 1.15 2003/09/03 04:12:41 douglas Exp $ |
5 |
> |
// $Id: VTBFileUtil2.h,v 1.17 2003/09/09 01:43:28 douglas Exp $ |
6 |
|
|
7 |
|
#ifndef _VTBFileUtil_h_ |
8 |
|
#define _VTBFileUtil_h_ |
14 |
|
#include <iostream> |
15 |
|
#include <string> |
16 |
|
#include <sstream> |
17 |
+ |
#include <fstream> |
18 |
|
#include <cctype> |
19 |
|
#include <vector> |
20 |
|
#include <set> |
100 |
|
+ (rect.bottom / 2), 0, 0, SWP_NOSIZE); |
101 |
|
} |
102 |
|
|
103 |
< |
inline void error(HWND parent = NULL) |
103 |
> |
inline void error(HWND parent = NULL, LONG code = ERROR_SUCCESS) |
104 |
|
{ |
105 |
|
LPVOID message; |
106 |
|
|
107 |
< |
FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | |
108 |
< |
FORMAT_MESSAGE_FROM_SYSTEM, NULL, GetLastError(), 0, |
107 |
> |
FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, |
108 |
> |
NULL, code == ERROR_SUCCESS ? GetLastError() : code, 0, |
109 |
|
LPTSTR(&message), 0, NULL); |
110 |
|
MessageBox(parent, LPCTSTR(message), programName.c_str(), MB_ICONERROR); |
111 |
|
LocalFree(message); |