Pedro Caldeira Active Member Licensed User Longtime User Mar 29, 2017 #1 Hello, I am trying to add a circle and then remove it. The Adding part is easy, but I get a non initialized circle error when trying to remove it. Why ? Code: Sub ShowRanges(Show as boolean) Dim Cnt As LatLng Cnt.Initialize(IniOwnLat, IniOwnLon) Dim OwnCnt As MapCircle If Show=True Then OwnCnt=gmap.AddCircle(Cnt,1000,2,fx.Colors.Red,fx.Colors.Magenta,1) Else gmap.RemoveCircle(OwnCnt) End If End Sub Also, Is it possible to fill the circle with semi-transparent color, instead of fully transparent or fully opace ? Thanks
Hello, I am trying to add a circle and then remove it. The Adding part is easy, but I get a non initialized circle error when trying to remove it. Why ? Code: Sub ShowRanges(Show as boolean) Dim Cnt As LatLng Cnt.Initialize(IniOwnLat, IniOwnLon) Dim OwnCnt As MapCircle If Show=True Then OwnCnt=gmap.AddCircle(Cnt,1000,2,fx.Colors.Red,fx.Colors.Magenta,1) Else gmap.RemoveCircle(OwnCnt) End If End Sub Also, Is it possible to fill the circle with semi-transparent color, instead of fully transparent or fully opace ? Thanks
EnriqueGonzalez Expert Licensed User Longtime User Mar 29, 2017 #2 Everytime you dim a variable it will become uninitialized. OwnCnt should be put in global variables, if you have many, it would be good to save them in a list, You can test wheter the circle is initialized with ownCnt.isInitialized. Upvote 0
Everytime you dim a variable it will become uninitialized. OwnCnt should be put in global variables, if you have many, it would be good to save them in a list, You can test wheter the circle is initialized with ownCnt.isInitialized.
Pedro Caldeira Active Member Licensed User Longtime User Mar 31, 2017 #4 That Worked like a charm. Thanks. And now, just another question. I get the lat and long outside the circle, but i can get it inside. Is there a way to intercept events inside the circles ? Upvote 0
That Worked like a charm. Thanks. And now, just another question. I get the lat and long outside the circle, but i can get it inside. Is there a way to intercept events inside the circles ?
EnriqueGonzalez Expert Licensed User Longtime User Mar 31, 2017 #5 I am not very familiarized with this library but you actually use Code: private Sub EventName_CircleClick (SelectedCircle As MapCircle) End Sub Upvote 0
I am not very familiarized with this library but you actually use Code: private Sub EventName_CircleClick (SelectedCircle As MapCircle) End Sub