1. Introduction. 1.1 I have previously written about exchanging SAFEARRAYs of managed structures with unmanaged code via COM interop. 1.2 In this new series of articles, I shall expound on the exchange of such SAFEARRAYs via P/Invoke. 1.3 I have arra…
1. Introduction. 1.1 Starting from part 4 I have started to discuss how to interop marshal a managed array of TestStructure structs that is contained within a structure. 1.2 We have seen in part 4 an example for marshaling such a container structure…
1. Introduction. 1.1 In part 4, I have started to discuss how to interop marshal a managed array that is contained within a structure. 1.2 I have given a specific working example for marshaling such a container structure to unmanaged code "one way&qu…
1. Introduction. 1.1 In parts 1 through 3 of this series of articles, I have thoroughly discussed the techniques for exchanging arrays between managed and unmanaged code by way of SAFEARRAYs. 1.2 The knowledge that can be gained from the first 3 part…
1. Introduction. 1.1 In part 1 of this series of articles, I demonstrated how to transfer managed arrays to unmanaged code as SAFEARRAYs. The transfer was single-directional "into" the unmanaged function and the SAFEARRAY that was passed to the…
1. Introduction. 1.1 In part 1 of this series of articles, I explained how managed arrays may be transferred to unmanaged code as a SAFEARRAY. 1.2 In part 1, the SAFEARRAY was passed to unmanaged code as an "in" (read-only) parameter. 1.3 Here i…
1. Introduction. 1.1 In part 1 of this series of blogs we studied how to pass a managed structure (which contains strings) to unmanaged code. The structure was passed as an "in" (by-value) parameter, i.e. the structure was passed to the unmanage…
1. Introduction. 1.1 Managed structures that contain strings are a common sight. The trouble is that managed strings are non-blittable. This means that they do not have a single common representation in the unmanaged world. However, there are several…
1. Introduction. 1.1 In part 1 of this series of blogs we studied how to pass a managed structure (which contains strings) to unmanaged code. The structure was passed as an "in" (by-value) parameter, i.e. the structure was passed to the unmanage…
Silverlight If the target managed property or input parameter is strongly typed (that is, not typed as an object), Silverlight attempts to convert the JavaScript object to the corresponding .NET Framework object. If the conversion fails (because of m…