Type Conversion from Vulcan.__Array to XSharp.__Array

Public support forum for peer to peer support with related to the Visual Objects and Vulcan.NET products
Post Reply
frankP
Posts: 2
Joined: Tue Feb 19, 2019 12:26 pm
Location: Germany

Type Conversion from Vulcan.__Array to XSharp.__Array

Post by frankP »

Hello,

is there a way to convert a Vulcan.__Array to an XSharp.__Array in XSharp?

I tried:

Code: Select all

xs_array := (ARRAY)vn_array
but that results in a compiler error
Cannot convert type 'Vulcan.__Array' to 'ARRAY'

Thanks for any suggestions.
User avatar
Chris
Posts: 4907
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

Type Conversion from Vulcan.__Array to XSharp.__Array

Post by Chris »

Well, you could write a function that creates a new X# array and simply copies the elements of the vulcan array to the X# one, but is it really necessary to do all this? Can you tell us why you need to mix both array types? Maybe we could suggest a better way to do what you need to achieve.

.
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
frankP
Posts: 2
Joined: Tue Feb 19, 2019 12:26 pm
Location: Germany

Type Conversion from Vulcan.__Array to XSharp.__Array

Post by frankP »

Thank you, Chris.

We are about to migrate a project from Vulcan to XSharp. We are using Vn2Ado, but Vn2Ado is using Vulcan.__Array. So we are getting a lot of compiler errors now. e.g:

Code: Select all

Cannot apply indexing with [] to an expression of type 'Vulcan.__Array'
We are also getting further errors, because array functions like ALen() and so on are referring to Xsharp Alen() functions and would have to be rewritten as VulcanRtFuncs.Functions.Alen() to refer to the corresponding Vulcan function.
User avatar
Chris
Posts: 4907
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

Type Conversion from Vulcan.__Array to XSharp.__Array

Post by Chris »

I think it will be way less complicated, if you just use the X# version of Robert's tool instead. I'm sure he will step in here or you can contact him directly for a X# license.

..
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
User avatar
robert
Posts: 4520
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

Type Conversion from Vulcan.__Array to XSharp.__Array

Post by robert »

Frank,
You already have download rights to the Xs2Ado installers on this website.
I recommend that you download Xs2Ado instead of Vn2Ado from this location:
https://www.xsharp.eu/itm-downloads?fol ... 252Fxs2ado
Version 5.0.5 is the recommended version.

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
Post Reply