Link to home
Start Free TrialLog in
Avatar of hanmannis
hanmannis

asked on

MIDI and mmsystem

I'm interestin about midi programmin and have made som high level mci-calls, but when I try to call functions from mmsystem.lib file it usualy gives me many error messages. Example: I put mmsystem to uses clause and definie pointer to PMidiInGetDevCapsA (var mincaps: PMidiInGetDevCapsA;) but when Imake a call  mincaps.pMid it gives me accessibility error.  
Avatar of inter
inter
Flag of Türkiye image

Hi,
I am not sure but, may be you forget to initialize the memory associated with is such as
 New(mincaps); then call it safely. After you are done with is Dispose(mincaps);
Igor
Avatar of ZifNab
ZifNab

Hanmannis,

Don't you've to use MinCaps^.pMid?

PS. I don't find PMidiInGetDevCapsA... Which version of Delphi are you using?

Regards, Zif.
Yes Inter, I see that's a possible problem.
ASKER CERTIFIED SOLUTION
Avatar of d003303
d003303

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Yo inter, Zif,
I havent' seen all your comments in the meantime. The question was empty when I was submitting my answer, sorry ! Yeah, you both were absolutely right.
This is real Windows multithreading ! It works perfectly in parallel, but every thread does exaclty the same thing ;-)

Cheers,
Slash/d003303
Nice work, no problem friend.
Regards, Igor
Hi all,

You're right d003303. Besides, don't you think it would be really interesting if they could split the points? That way multiple persons could give advise and help to come to a good and well-thought answer. I read they were trying to built something like I proposed, but I haven't heard anything about it anymore... Ok, I quit, before I spoil this thread.

Regards, ZiF.



Yo !
Zif, right, splitting points would be realy nice ! That would eliminate the feeling of <stealing> somebodys commented idea to implemet it in your own answer.

CU,
Slash/d003303
Yep, that's correct, because sometimes, you don't know the answer right away, but with the help of a piece of source of somebody else, you can solve it. This way, I think, both should receive some points. ZiF.
Avatar of hanmannis

ASKER

Thank you from your answer! I think that you were right about getting memory for the pointer struct. By the way, I'm using Delphi 3.