Cached Basemap Layer will not show up

839
12
03-01-2011 07:29 AM
justinsowers
New Contributor
I am creating a web application in Flash Builder 4 using the ArcGIS Viewer for Flex source code. I am having a problem getting my cached basemap, which is an aerial photograph, to show up when I run the application. The dynamic operational layers show up but the cached base map will not. When i change the basemap to dynamic, it will show up but when I try to zoom in all layers disappear. The zoom slider shows up and displays the correct scales but the basemap itself is blank. I can create a web application using the application tab in ArcGIS Server and it shows up and displays fine at all scales. Any help would be GREATLY appreciated.
Here is the code I am using:

<configuration>
    <title>Barren County WebGIS</title>
    <subtitle>Justin Sowers - Geography 418</subtitle>
    <logo>assets\images\wku.jpg</logo>
    <style>
        <colors>0xFFFFFF,0x333333,0x101010,0x000000,0xFFD700</colors>
        <alpha>0.8</alpha>
    </style>

    <!-- UI elements -->
    <widget left="10"  top="50"    config="widgets/Navigation/NavigationWidget.xml" url="widgets/Navigation/NavigationWidget.swf"/>
    <widget right="20" top="55"    config="widgets/MapSwitcher/MapSwitcherWidget.xml" url="widgets/MapSwitcher/MapSwitcherWidget.swf"/>
    <widget left="0"   top="0"     config="widgets/HeaderController/HeaderControllerWidget.xml" url="widgets/HeaderController/HeaderControllerWidget.swf"/>

    <map initialextent=
"1455768.96629259 1771317.29498822 1715713.09129259 1950286.76200211" top="40">
        <basemaps>
            <layer label="Barren" type="tiled" visible="true"  alpha="1"
                   url="http://sowers/WebGIS/rest/services/basemap_cache/MapServer"/>
 
        </basemaps>
        <operationallayers>
          <layer label="Roads" type="dynamic" visible="true"
                   url="http://sowers/WebGIS/rest/services/b_roads/MapServer"/>

            <layer label="Schools" type="dynamic" visible="true"
                   url="http://sowers/WebGIS/rest/services/schools/MapServer"/>
        </operationallayers>
    </map>
 
<widgetcontainer layout="float">
 
  <widget label="Search" left="80" top="280" icon="assets/images/i_search.png" config="widgets/Search/SearchWidget_Louisville.xml" url="widgets/Search/SearchWidget.swf" />

  </widgetcontainer>


</configuration>
Tags (2)
0 Kudos
12 Replies
RobertScheitlin__GISP
MVP Emeritus
Justin,

   A couple of questions

1. Is this the extent that is provided from the REST endpoint for your cached service? 1455768.96629259 1771317.29498822 1715713.09129259 1950286.76200211

2. Do your REST End point look something like this:

Single Fused Map Cache: true

Tile Info:

    * Height: 256
    * Width: 256
    * DPI: 96
    * Levels of Detail: (# Levels: 18)
          o Level ID: 0 [Start Tile, End Tile]
                  Resolution: 156543.033928
                  Scale: 591657527.591555
          o Level ID: 1 [Start Tile, End Tile]
                  Resolution: 78271.5169639999
                  Scale: 295828763.795777
0 Kudos
justinsowers
New Contributor
yes that is the extent of the REST service. here is what the REST page looks like through ArcGIS Services Directory:

basemap_cache (MapServer)
View In:   ArcMap   ArcGIS Explorer   ArcGIS JavaScript   Google Earth   ArcGIS.com Map

View Footprint In:   Google Earth

Service Description:

Map Name: Layers

Legend

All Layers and Tables

Layers:


barren (0)
ortho_1-1_1n_s_ky009_2010_1.sid (1)
Tables:


Description:

Copyright Text:

Spatial Reference: 2247

Single Fused Map Cache: true

Tile Info:


Height: 256

Width: 256

DPI: 96

Levels of Detail: (# Levels: 😎

Level ID: 0 [Start Tile, End Tile]
Resolution: 257.881076388889
Scale: 297079
Level ID: 1 [Start Tile, End Tile]
Resolution: 128.940104166667
Scale: 148539
Level ID: 2 [Start Tile, End Tile]
Resolution: 64.4696180555556
Scale: 74269
Level ID: 3 [Start Tile, End Tile]
Resolution: 32.234375
Scale: 37134
Level ID: 4 [Start Tile, End Tile]
Resolution: 16.1171875
Scale: 18567
Level ID: 5 [Start Tile, End Tile]
Resolution: 8.05815972222222
Scale: 9283
Level ID: 6 [Start Tile, End Tile]
Resolution: 4.02864583333333
Scale: 4641
Level ID: 7 [Start Tile, End Tile]
Resolution: 2.01388888888889
Scale: 2320
Format: JPEG
Compression Quality: 75
Origin:
X: -121000700
Y: 152113100

Spatial Reference: 2247
Intial Extent:

XMin: 1455768.96629259
YMin: 1753655.99007773
XMax: 1715713.09129259
YMax: 1967948.06691259
Spatial Reference: 2247

Full Extent:

XMin: 1502400.36474015
YMin: 1757922.13623097
XMax: 1669081.69284502
YMax: 1963681.92075935
Spatial Reference: 2247
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Justin,

From the REST Service end point can you click ArcGIS Javascript and it bring up the map?

One thing that is really suspicious to me is the point of origin for the tiles.

Origin:
X: -121000700
Y: 152113100

Spatial Reference: 2247
Intial Extent:

XMin: 1455768.96629259
YMin: 1753655.99007773
XMax: 1715713.09129259
YMax: 1967948.06691259
Spatial Reference: 2247

Normally those values are within the initial extent...
0 Kudos
DasaPaddock
Esri Regular Contributor
Does it work as expected when you go to:
http://sowers/WebGIS/rest/services/basemap_cache/MapServer?f=jsapi
Are the tiles loaded and the slider shows the available levels?
0 Kudos
justinsowers
New Contributor
when i try to bring up the map using javascript it shows the zoom slider but the tiles do not load, it is still blank. i see what you are saying about the origin of the tiles, but i do not really know how to go about fixing that. could it be a function of the projection maybe? i have attached screenshots of what the application looks like when its launched in Viewer (the operational layers are there and the slider shows the correct scale but the aerial photo is blank) and when it is brought up in javascript.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Justin,

   Do your sids have .sdw files if so open on in notebook.exe and see that it's origin is. The last two lines of the file.
0 Kudos
justinsowers
New Contributor
the last two lines of the .sdw file have these values:

571934.500000000000000
4116779.500000000000000
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Justin,

   That looks like a different coordinate system than what you are attempting to publish it as... That is going to be an issue.
0 Kudos
NicholasFordes
New Contributor
Is that your only base map?  Or do you have other maps from Bing or ESRI as well?

If so, when you make the cache and tiles, you need to load the tiling scheme that matches.

http://help.arcgis.com/en/arcgisserver/10.0/help/arcgis_server_dotnet_help/index.html#/Designing_a_m...
0 Kudos