error C2146: syntax error : missing ';' before identifier 'TCHAR'
unexpected end of file found就是这两句话有问题
TCHAR szAppName[]="SDKAutoOff";
TCHAR time[4];
int WINAPI WinMain (HINSTANCE hInstance,NULL,PSTR szCmdLine, int iCmdShow)

解决方案 »

  1.   

    它的意思是不认识TCHAR,但又不好意思直说。说明TCHAR的头文件include了吗?
      

  2.   

    我已经定义了#include<windows.h>
    #include"resource.h"
    #include<string.h>
    可是问题还在啊??
      

  3.   

    char szAppName[]="SDKAutoOff";
    char time[4];
      

  4.   

    楼上的,我照你那样改成个char又有错误
    waring C4518: 'char ' : storage-class or type specifier(s) unexpected here; ignoredsyntax error : missing ';' before identifier 'szAppName'
      

  5.   

    你有msdn么?自己查查不就的了
      

  6.   

    你在sdk下编程,不能这样写吧,我觉得你还是老实的用c进行调用吧
      

  7.   

    #include<tchar.h>试试
    其实不用UNICODE时,TCHAR就是char
      

  8.   

    改成char *szAppName="SDKAutoOff";试试
    C下对[]敏感吧
      

  9.   

    把程序发给我,我可以帮你调试。[email protected]
      

  10.   

    改成:char szAppName[]=Text("SDKAutoOff");
      

  11.   

    对不起,写错了
    TCHAR szAppName[]=Text("SDKAutoOff");
      

  12.   

    first, 
    TCHAR szAppName[] = _T("SDKAutoOff");
    second,
    make sure your sdk source file has an extension of ".cpp";