Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FragmentManager: No view found for id 0x2 (unknown) for fragment SupportMapFragment #282

Open
fede1295 opened this issue Oct 30, 2019 · 3 comments

Comments

@fede1295
Copy link

fede1295 commented Oct 30, 2019

App crash when I add the module="ti.map" to a View:

<View id="mapView" module="ti.map"> <Annotation id='point'/> </View>

ti.map version 4.5.0
titanium sdk version 8.2.0

@m1ga
Copy link
Contributor

m1ga commented Nov 2, 2019

Did you try the syntax from: http://docs.appcelerator.com/platform/latest/#!/api/Modules.Map

<Alloy>
    <Window>
        <Module id="mapview" module="ti.map" onClick="report" method="createView">
            <Annotation id="appcHQ" myId="1337" />
        </Module>
    </Window>
</Alloy>

with alloy.js

Alloy.Globals.Map = require('ti.map');

@ericpolkadoc
Copy link

Hi Michael,

Im getting same error with ti.map on android, just started out of the blue.

[ERROR] TiExceptionHandler: (main) [6,44061] No view found for id 0x1 (unknown) for fragment SupportMapFragment{91d3b96 (f118b8e7-cf16-4c99-8835-618101e85a9e) id=0x1}

Im using classic ti for this controller, 9.0.0.GA, ti.map v5.0.1. I've not changed anything, seems to happen when I add the mapview to my view. Works ok on IOS.

Any thoughts on what the issue might be?

    var map = require("ti.map");

mapview = map.createView({
	mapType : APP.MAP.NORMAL_TYPE,
	left : 12,
	top : 0,
	right : 12,
	bottom : args.payload ? 0 : 12,
	regionFit : true,
	accessibilityLabel: "pharmacySelect-mapView"
});

view.add(mapview);

@ericpolkadoc
Copy link

Michael,

Update on my issue, thought I would add it here for anyone else that might need it.

I had a console.log that was failing for some reason, I think the object was either undefined or null when the map was being generated in my view.

It looks like when my console.log error'd, it wasn't being logged in terminal, and caused the map to fail, with the error message I saw. So the map error I was seeing was misleading, I was not seeing the actual error.

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants