Click here to Skip to main content
15,907,910 members
Home / Discussions / COM
   

COM

 
GeneralRe: Marshalling problem Pin
David_Leikis19-Aug-05 3:26
David_Leikis19-Aug-05 3:26 
GeneralRe: Marshalling problem Pin
Vi219-Aug-05 4:17
Vi219-Aug-05 4:17 
GeneralRe: Marshalling problem Pin
David_Leikis19-Aug-05 4:42
David_Leikis19-Aug-05 4:42 
GeneralRe: Marshalling problem Pin
Vi222-Aug-05 21:59
Vi222-Aug-05 21:59 
GeneralRe: Marshalling problem Pin
RikaBoy26-Aug-05 21:45
RikaBoy26-Aug-05 21:45 
General[Message Deleted] Pin
RikaBoy26-Aug-05 21:18
RikaBoy26-Aug-05 21:18 
GeneralRe: Marshalling problem Pin
Lim Bio Liong19-Aug-05 3:12
Lim Bio Liong19-Aug-05 3:12 
GeneralRe: Marshalling problem Pin
David_Leikis19-Aug-05 3:38
David_Leikis19-Aug-05 3:38 
Yes, my code is very similar to your example.
1. I have verified that the value for pNum_ROI_nodes is positive and the correct value for the situation.

2. I have seen that all of the values do get loaded into the memory assigned for the array on the server side in the server's memory space.

3. Upon return to the client side, I can see that the value returned for the pNum_ROI_nodes is still the correct value and is in the client memory space, but upon trying to read the values with:

for (int i = 0; i < pNum_ROI_nodes * 2; i++)
{
pfCoordValue[i] = (float)pROI_coords[i]; //retrieve the values to local array
}
CoTaskMemFree(pROI_coords); //delete the array created within the COM server object

At this point, the only value that is in the array pROI_coords, is the very first value loaded. In your example, it would be the value of 1.0. All other values are none existent and it is clear from the memory contents that the array is not initialized past one value. It appears that the marshaller is only moving one item of the array to the client side.

Vita has suggested that the marshaller does not understand the size_is command, maybe he is on to something...


Regards,
David
GeneralRe: Marshalling problem Pin
Lim Bio Liong19-Aug-05 4:04
Lim Bio Liong19-Aug-05 4:04 
GeneralRe: Marshalling problem Pin
David_Leikis19-Aug-05 4:13
David_Leikis19-Aug-05 4:13 
GeneralRe: Marshalling problem Pin
Lim Bio Liong19-Aug-05 4:44
Lim Bio Liong19-Aug-05 4:44 
GeneralRe: Marshalling problem Pin
David_Leikis19-Aug-05 5:01
David_Leikis19-Aug-05 5:01 
GeneralRe: Marshalling problem Pin
Lim Bio Liong19-Aug-05 5:20
Lim Bio Liong19-Aug-05 5:20 
GeneralRe: Marshalling problem Pin
Lim Bio Liong19-Aug-05 4:52
Lim Bio Liong19-Aug-05 4:52 
Generalmshtml programming Pin
softty18-Aug-05 9:46
softty18-Aug-05 9:46 
GeneralAdding a new Interface to Existing component Pin
BicycleTheif18-Aug-05 1:50
BicycleTheif18-Aug-05 1:50 
GeneralRe: Adding a new Interface to Existing component Pin
Milton Karimbekallil20-Aug-05 8:30
Milton Karimbekallil20-Aug-05 8:30 
GeneralCOM with VB.net and C#.NET Pin
Darren Whittall17-Aug-05 11:01
Darren Whittall17-Aug-05 11:01 
GeneralPowerpoint automation with VC++ Pin
spelhatre17-Aug-05 4:21
spelhatre17-Aug-05 4:21 
GeneralRe: coclass Pin
Lim Bio Liong17-Aug-05 6:36
Lim Bio Liong17-Aug-05 6:36 
GeneralUsing ActiveX as pop-up menu Pin
Spaz8016-Aug-05 22:02
Spaz8016-Aug-05 22:02 
GeneralIn-Proc becomes client to Out-of-Proc Pin
Jnewg516-Aug-05 1:35
Jnewg516-Aug-05 1:35 
GeneralAutomation Question Pin
Joel Holdsworth15-Aug-05 22:38
Joel Holdsworth15-Aug-05 22:38 
GeneralActiveX Ctrl for web application Pin
SS0587015-Aug-05 5:40
SS0587015-Aug-05 5:40 
Generaltopic for projects Pin
V.G13-Aug-05 2:14
V.G13-Aug-05 2:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.