[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
[phpBB Debug] PHP Notice: in file [ROOT]/includes/session.php on line 2208: Array to string conversion
www.undertowsoftware.com • View topic - How to fake a structure and/or array?

How to fake a structure and/or array?

A forum made available for users of the MapPro OCX SDK to exchange ideas, ask each other questions, etc.

How to fake a structure and/or array?

Postby FletcherJ » Thu Feb 02, 2012 9:48 pm

Hi all,

Ok, while I am doing my development in C#, someone came to me using another dev environment. Theirs does NOT support structures. So it makes it hard to pass an array of structures when they can't define such.

Anybody got an idea of how we could model the data as binary data and pass that instead of a nice array of structures? They are trying to use the Cad.Polygon method. Or better yet, is there another method that could be called that doesn't require structs or a way to load their data from a file/xml string that would do the same thing?

Thanks,

me
User avatar
FletcherJ
Active User
Active User
 
Posts: 36
Joined: Fri Jan 20, 2012 5:33 pm

Re: How to fake a structure and/or array?

Postby Kevin_T » Fri Feb 03, 2012 11:55 am

What environment is that someone using? Not sure that *I* would have the expertise to help them, but if it's not one of the mainstream development environments for this type of work, it may just be that there is no way to do it. A few years ago, we had an access developer in our team that was trying to implement a mapping solution within access, using an earlier OCX from Undertow (Mappro60 or Mappro70 - not sure which one). Well, it didn't work out very well :-) I am not saying that's what your friend/associate is doing, just saying...
User avatar
Kevin_T
Senior User
Senior User
 
Posts: 265
Joined: Fri Apr 30, 2010 9:13 am

Re: How to fake a structure and/or array?

Postby FletcherJ » Fri Feb 03, 2012 3:10 pm

Kevin,

He is not using Access, but it is an outdated environment. But the info that the Access developer couldn't get it working at least gives me some idea that it might end up being just as difficult and to explore some other avenue.

Thanks,

me
User avatar
FletcherJ
Active User
Active User
 
Posts: 36
Joined: Fri Jan 20, 2012 5:33 pm

Re: How to fake a structure and/or array?

Postby UShadow » Fri Feb 03, 2012 9:43 pm

FletcherJ wrote:He is not using Access, but it is an outdated environment. But the info that the Access developer couldn't get it working at least gives me some idea that it might end up being just as difficult and to explore some other avenue.


If I understand it correctly, the TRpoint structure is simply a record of two double variables. In most development environments, it's possible to create an array of doubles (XCoord,YCoord) and get a pointer to the array.

Then, you can just pass it as Pointer to the polygon method you are trying to use. My thinking is that you should be able to do this in pretty much every IDE/language, although I have to say that a few years ago, when fooling around with VB6, it wasn't real obvious.

I guess the answer to your original question is, it depends on the IDE/language your friend is using, and only someone real knowledgeable in *that* language could answer your question with authority.
Imagination is greater than detail - Albert Einstein
User avatar
UShadow
Frequent User
Frequent User
 
Posts: 61
Joined: Fri May 28, 2010 11:49 am

Re: How to fake a structure and/or array?

Postby VictorC » Sun Feb 05, 2012 4:44 pm

I would have thought that pretty much every language/IDE would support passing arrays! Surprised to hear there are some that don't.
User avatar
VictorC
Active User
Active User
 
Posts: 29
Joined: Sun Jan 24, 2010 2:54 pm

Re: How to fake a structure and/or array?

Postby FletcherJ » Tue Feb 07, 2012 2:14 pm

Victor,

VictorC wrote:I would have thought that pretty much every language/IDE would support passing arrays! Surprised to hear there are some that don't.


The array isn't (currently) the problem, it's the structure data type. But he will try a couple of things and let me know if any of them work.

Too bad there isn't an option to just pass in an XML dataset of points that can be rendered.....

Thanks,

me
User avatar
FletcherJ
Active User
Active User
 
Posts: 36
Joined: Fri Jan 20, 2012 5:33 pm


Return to MapPro OCX

Who is online

Users browsing this forum: No registered users and 2 guests

cron