I am having trouble compiling a program from the command line. I usually don't use the command line, but I would like to familiarize myself with it a little. I am trying to compile the file named "CppTextReader.cpp" and I am trying to pass the file "volcanoes.xml" to the program. I tried doing this like so -> 'cl CppTextReader.cpp volcanoes.xml' What am I doing wrong. It keeps giving me the error 'cl : Command line warning D4024 : unrecognized source file type 'volcanoes.xml', object file assumed
#include "stdafx.h"
#using <mscorlib.dll>
#include <tchar.h>
#using <System.xml.dll>
using namespace System;
using namespace System::Xml;
// This is the entry point for this application
int _tmain(int argc, char* argv[])
{
// Check for required arguments
if (argc < 2)
{
Console::WriteLine(S"Usage: CppTextReader path"
;
return -1;
}
String* path = new String(argv[1]);
try
{
// Create the reader...
XmlTextReader* rdr = new XmlTextReader(path);
}
catch(Exception* pe)
{
Console::WriteLine(pe->ToString());
}
return 0;
}
#include "stdafx.h"
#using <mscorlib.dll>
#include <tchar.h>
#using <System.xml.dll>
using namespace System;
using namespace System::Xml;
// This is the entry point for this application
int _tmain(int argc, char* argv[])
{
// Check for required arguments
if (argc < 2)
{
Console::WriteLine(S"Usage: CppTextReader path"
return -1;
}
String* path = new String(argv[1]);
try
{
// Create the reader...
XmlTextReader* rdr = new XmlTextReader(path);
}
catch(Exception* pe)
{
Console::WriteLine(pe->ToString());
}
return 0;
}