AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Thema durchsuchen
Ansicht
Themen-Optionen

Operator not applicable

Ein Thema von EWeiss · begonnen am 21. Apr 2007 · letzter Beitrag vom 21. Apr 2007
 
EWeiss
(Gast)

n/a Beiträge
 
#1

Operator not applicable

  Alt 21. Apr 2007, 06:12
Hi

Langsam wirds immer schwiriger

Delphi-Quellcode:
function GetPresetCount(var pnPresetCount: LongInt): HRESULT;
Var
  IntVal: integer;

begin
  if (IWmpEffects <> 0) then
    begin
       IntVal := 0;
       result := IWmpEffects.GetPresetCount(IntVal);
       pnPresetCount := IntVal;

    end else
    result := -1;

end;
Zwei Fehler in einer function.
if (IWmpEffects <> 0) then 0 normalerweise in C# 'null' wie im MS Beispiel.

gibt in Delphi den Fehler aus.
[Pascal Error] WMPUnit.pas(218): E2015 Operator not applicable to this operand type

IWmpEffects.GetPresetCount(IntVal); laut MS Beispiel IWmpEffects.GetPresetCount(ref IntVal);
ref dürfte var sein funktioniert aber nicht!
Zusätzlich kommt noch die Meldung
[Pascal Error] WMPUnit.pas(221): E2018 Record, object or class type required für den bereich (ref IntVal);

Delphi-Quellcode:
IWMPEffects = interface(IUnknown)
   ['{D3984C13-C3CB-48e2-8BE5-5168340B4F35}']
   procedure GetPresetCount(var pnPresetCount : LongInt); safecall;
Jemand ne Idee was da falsch läuft ?

Gruss Emil
  Mit Zitat antworten Zitat
 


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 19:14 Uhr.
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz