I am having trouble in my application with the basemap loading. It will not load initially until I zoom in. It seems that half of the time it will load, the other half it doesn't. What could be a cause this problem? I have a large amount of layers (>30) loading initially as well.
Wesley, There could be several reasons for this. It's hard to tell w/o any code to review. Are you getting any errors in the console when the basemap doesn't load?
Something that comes to mind is the map div resizing for some reason between creating the map and the basemap loading. This can happen w/ dijit/layout/BorderContainer in some scenarios especially when programmatically manipulating the layout. For example adding buttons to a toolbar that is a region. Calling resize() on the bc before and/or after map creation will fix this. Certainly any other layout that is being created or manipulated programmatically during app initializing in which the height and width of the map div change could cause the same problem.
Wesley, There could be several reasons for this. It's hard to tell w/o any code to review. Are you getting any errors in the console when the basemap doesn't load?
Something that comes to mind is the map div resizing for some reason between creating the map and the basemap loading. This can happen w/ dijit/layout/BorderContainer in some scenarios especially when programmatically manipulating the layout. For example adding buttons to a toolbar that is a region. Calling resize() on the bc before and/or after map creation will fix this. Certainly any other layout that is being created or manipulated programmatically during app initializing in which the height and width of the map div change could cause the same problem.