06-11-2015, 01:01 AM
Hi Gintaras,
The example above works with integer type when I change to "string" type I've got an error of "Error in PassByRefStr: type mismatch."
You know what's wrong with it?
Macro PassByRefStr
The example above works with integer type when I change to "string" type I've got an error of "Error in PassByRefStr: type mismatch."
You know what's wrong with it?
Macro PassByRefStr
out
str s1="s1"
str s2="s2"
out "s1=%s, s2=%s" s1 s2
CsScript x.AddCode("")
IDispatch d=x.CreateObject("Test")
d.PassByRefStr(&s1 &s2)
err
,out _error.description
out "s1=%s, s2=%s" s1 s2
#ret
using System;
public class Test
{
,public static void PassByRefStr(ref string x, ref string y)
,{
,,x = "s1_string";
,,y = "s2_string";
,}
}