struct IntuitionIFace has no member named 'GetMsg()'

This forum is for general developer support questions.
Post Reply
Alix
Posts: 3
Joined: Mon Oct 07, 2013 3:52 pm

struct IntuitionIFace has no member named 'GetMsg()'

Post by Alix »

Hi all,

I have installed the Amiga OS4 SDK, and and I am trying to find my way around the most basic concepts, so I appologise in advance if my question is trivial (I have plenty of experience as a C programmer, but very little understanding of the Amiga OS - still learning!)

I am simply trying to compile the example at the bottom of this page:
http://wiki.amigaos.net/index.php/Intui ... _Interface

But it won't even compile. It says: struct IntuitionIFace has no member named 'GetMsg()'

Now as a programmer I understand what that means. I am calling a function (GetMsg) that doesn't exist on this object/interface. But I am not sure why, since I am running a code example without changing it. Am I not using the right version of the libraries? Of the SDK?

And more importantly, is there a way to LOOK at a certain interface, i.e. look at the list of the different methods and their parameters?

Thanks all! :)

Alix
User avatar
salass00
AmigaOS Core Developer
AmigaOS Core Developer
Posts: 534
Joined: Sat Jun 18, 2011 4:12 pm
Location: Finland
Contact:

Re: struct IntuitionIFace has no member named 'GetMsg()'

Post by salass00 »

@Alix

That's an error in the example code. It should be IExec->GetMsg() not IIntuition->GetMsg().
And more importantly, is there a way to LOOK at a certain interface, i.e. look at the list of the different methods and their parameters?
For up to date information on library functions you should read the autodocs. You can find them in:
SDK:Documentation/AutoDocs/
User avatar
ssolie
Beta Tester
Beta Tester
Posts: 1010
Joined: Mon Dec 20, 2010 8:51 pm
Location: Canada
Contact:

Re: struct IntuitionIFace has no member named 'GetMsg()'

Post by ssolie »

Alix wrote:But it won't even compile. It says: struct IntuitionIFace has no member named 'GetMsg()'
Now fixed.
Alix wrote:And more importantly, is there a way to LOOK at a certain interface, i.e. look at the list of the different methods and their parameters?
Each interface like IExec has a struct ExecIFace* type. This type is defined in a header file which means you have a full list of every function available on that interface. I just don't remember right now where those files are in the SDK (not near an Amiga).

You should also review the associated autodoc of course but it is nice to know where the C source files are because code doesn't lie (unlike docs).
ExecSG Team Lead
Alix
Posts: 3
Joined: Mon Oct 07, 2013 3:52 pm

Re: struct IntuitionIFace has no member named 'GetMsg()'

Post by Alix »

Okay thanks guys, all this is very helpful. My code is now compiling and working, and I have found the auto docs.

It's a shame that there are errors in the code examples. I found a very obvious one earlier :
http://wiki.amigaos.net/index.php/Introduction_to_Exec

Right at the bottom, on the line:
struct IntuitionIFace *IIntuition = IExec->GetInterface(base, "main" 1, NULL);

There is cleary a comma missing after "main". Once I am more confident I will be more than happy helping with updates/corrections of the Wiki :)
User avatar
cha05e90
Posts: 90
Joined: Fri Jun 17, 2011 11:15 pm
Location: Germany
Contact:

Re: struct IntuitionIFace has no member named 'GetMsg()'

Post by cha05e90 »

Alix wrote:My code is now compiling and working, and I have found the auto docs.
For more convenient look up of Autodocs you might try this SDKBrowser (http://os4depot.net/index.php?function= ... rowser.lha) or the inbuild Autodoc browser of Codebench (http://codebench.co.uk).
X1000|II/G4|440ep|2000/060|2000/040|1000
User avatar
ssolie
Beta Tester
Beta Tester
Posts: 1010
Joined: Mon Dec 20, 2010 8:51 pm
Location: Canada
Contact:

Re: struct IntuitionIFace has no member named 'GetMsg()'

Post by ssolie »

Alix wrote:There is cleary a comma missing after "main". Once I am more confident I will be more than happy helping with updates/corrections of the Wiki :)
Fixed. And yes, we always need more wiki editors. There are probably hundreds of errors given the massive amount of text available.

I'm just happy we have a place to store, edit and improve that text. Before the wiki you would be stuck with combing the internet or using pirated copies of manuals to get the information you needed.
ExecSG Team Lead
Post Reply