G
Guest
Hi!
I want to learn C# in the near future. But for now, I would be more than
happy if someone could translate this short c# source code into c++. (I
searched the web for c++ equivalents but after one hour i am too frustrated,
and so i hope you can help me)
using System.IO; ... SHDocVw.ShellWindows shellWindows = new
SHDocVw.ShellWindowsClass(); string filename; foreach
(SHDocVw.InternetExplorer ie in shellWindows){ filename =
Path.GetFileNameWithoutExtension(ie.FullName).ToLower(); if
(filename.Equals("iexplore")) Console.WriteLine("Web Site : {0}",
ie.LocationURL); if (filename.Equals("explorer"))
Console.WriteLine("Hard Drive : {0}", ie.LocationURL); }
Here's the start of the c++ code:
#include <windows.h>
#using <mscorlib.dll>
#include <iostream>
#include <string>
using namespace System;
using namespace System::IO;
using namespace System::Collections;
void main()
{
....
}
Thank you very very much!!
I want to learn C# in the near future. But for now, I would be more than
happy if someone could translate this short c# source code into c++. (I
searched the web for c++ equivalents but after one hour i am too frustrated,
and so i hope you can help me)
using System.IO; ... SHDocVw.ShellWindows shellWindows = new
SHDocVw.ShellWindowsClass(); string filename; foreach
(SHDocVw.InternetExplorer ie in shellWindows){ filename =
Path.GetFileNameWithoutExtension(ie.FullName).ToLower(); if
(filename.Equals("iexplore")) Console.WriteLine("Web Site : {0}",
ie.LocationURL); if (filename.Equals("explorer"))
Console.WriteLine("Hard Drive : {0}", ie.LocationURL); }
Here's the start of the c++ code:
#include <windows.h>
#using <mscorlib.dll>
#include <iostream>
#include <string>
using namespace System;
using namespace System::IO;
using namespace System::Collections;
void main()
{
....
}
Thank you very very much!!