Re: Outlook application object



SvenC wrote:
Hi Markus,

"Markus Donath" <news1589@xxxxxxxxxxxxx> wrote in message news:OOedtXX4GHA.1544@xxxxxxxxxxxxxxxxxxxxxxx
I want to create an Outlook-appointment using .NET VC.
My Visual Basic example starts with:

Dim oApp As Microsoft.Office.Interop.Outlook.Application = New Microsoft.Office.Interop.Outlook.Application

But my C++ translation:

Microsoft::Office::Interop::Outlook::Application *oApp = new Microsoft::Office::Interop::Outlook::Application;


does not compile. ('You cannot create an instance of an interface' or something like that). Does anybody know, what's wrong here?

Why not copy the exact error message?

Because it is produced by German version of Visual Studio .NET 2003 and thus, the error message is in German:

error C3153: 'Microsoft::Office::Interop::Outlook::Application': Sie können keine Instanz einer Schnittstelle erstellen


Do you use VC2003 or VC2005?

VC2003


In VC2003 I would expect that something like ApplicationClass or _ApplicationClass would be available which represents the so called COM coclass. A coclass is an object you can instantiate and use by an interface it implements, which would be Application in thiscase.

Have you got an example?

In VC2005 you would want to use the new C++/CLI which uses ^ instead of * for managed pointers and gcnew instead of new.

--
SvenC

Markus


.



Relevant Pages

  • Re: Ready built FMS interface in UK?
    ... This is a small summary of possible interfaces for FMS. ... See the manual of FMS ("handbuch" in German) ... simple parallel or serial interface. ... http://nexstar4.free.fr/aero_bidouilles_cable_sim.htm (French) ...
    (rec.models.rc.air)
  • Re: Accessing interfaces that are not associated with coclasses
    ... internal private objects of the client. ... the event interface before I use DispEventAdvise. ... of the coclass which is created via hr = ptr.CoCreateInstance ...
    (microsoft.public.vc.atl)
  • RE: Outlook Web Access in mixed language
    ... When User access a mailbox through OWA, the language of the OWA interface ... you use the German version of Outlook, or Internet Explorer with a German ... 2.Use Outlook XP or Outlook 2003 to connect to Exchange server, ...
    (microsoft.public.windows.server.sbs)
  • Re: man -t odd page size
    ... Here the 'overprinting' is misaligned in gv, ... but it outputs an error message: ... been invented by a German, all computer stuff should be in the ... but it doesn't look like pushing TCP/IP off its perch .. ...
    (freebsd-questions)
  • Re: What does it mean with a COM class
    ... Microsoft MVP, MCSD ... "Igor Tandetnik" wrote in message ... >> Is COM class the class that implements the Interface? ... A coclass is a specific implementation of one ...
    (microsoft.public.win32.programmer.ole)