Thread: Expected type for parameter 2, but found '_TCHAR'

  1. #1
    Registered User
    Join Date
    Aug 2011

    Expected type for parameter 2, but found '_TCHAR'

    Why do I get that error when I try to compile this code

    int _stdcall _tmain(int argc, _TCHAR* argv[])

  2. #2
    Registered User
    Join Date
    Jun 2005
    This is not a C problem. It belongs in a windows programming forum.

    Odds are you've configured your compiler (or used compilation options) to turn off Microsoft extensions, or you are using a compiler that does not support such extensions.

    That's only a guess though - you haven't really provided enough information (the compiler and compiler settings you have in play is an important consideration).
    Right 98% of the time, and don't care about the other 3%.

    If I seem grumpy or unhelpful in reply to you, or tell you you need to demonstrate more effort before you can expect help, it is likely you deserve it. Suck it up, Buttercup, and read this, this, and this before posting again.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Expected constructor, destructor, type conversion
    By SterlingM in forum C++ Programming
    Replies: 6
    Last Post: 03-26-2010, 01:16 PM
  2. compiler not inferring template type as expected
    By Elkvis in forum C++ Programming
    Replies: 13
    Last Post: 11-12-2008, 06:04 AM
  3. expected constructor, destructor, or type conversion before '('
    By cosmiccomputing in forum C Programming
    Replies: 5
    Last Post: 06-16-2008, 11:03 PM
  4. Type Name Expected HELP!!!!
    By Unregistered in forum C++ Programming
    Replies: 2
    Last Post: 08-15-2002, 10:33 AM
  5. Type name expected error
    By SilasP in forum C++ Programming
    Replies: 4
    Last Post: 12-09-2001, 02:05 PM