Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Output parameter of ref type long throwing Type Mismatch #79

Open
Alee02 opened this issue Jun 11, 2020 · 1 comment
Open

Output parameter of ref type long throwing Type Mismatch #79

Alee02 opened this issue Jun 11, 2020 · 1 comment

Comments

@Alee02
Copy link

Alee02 commented Jun 11, 2020

I have tried the following combinations

var longOuput = new Variant(0, "long")
var longOutputRef = new Variant(longOutput, "byref")
var longOuput = new Variant(0, "long")
var longOutputRef = new Variant(longOutput, "plong")

The type mismatch error occurs only when passing a reference type. Passing the following compiles fine, but the out value isn't returned.
var longOuput = new Variant(0, "long")

Here is the method signature for reference:

VARIANT GetCurrentId(
                [in] BSTR sessionID, 
                [out] long* number, 
                [out] VARIANT* error, 
                [out] VARIANT* outcome);
@Alee02 Alee02 changed the title long output parameter throwing Type Mismatch long output parameter throwing Type Mismatch Jun 11, 2020
@Alee02 Alee02 changed the title long output parameter throwing Type Mismatch Output parameter of ref type long throwing Type Mismatch Jun 11, 2020
@Cgende
Copy link

Cgende commented Aug 31, 2023

I'm having the exact same issue. Has any one figured it out?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants