Is far as I know (I am not a developer), it is not possible to send extent x,y in a url parameter. Is there any way to have the bookmark widget open on application startup?
Solved! Go to Solution.
Klas,
For the x,y in the url this is NOT built into the WAB Stem App. But here is a link to where I detail what has to be changed to make this work:
https://community.esri.com/message/399090#399090
As far as making the bookmark widget open at startup that is as simple as editing the config.json to include
"openAtStart": true
so the widget element look like this:
{
"position": {
"left": 55,
"top": 45,
"width": 400,
"height": 410
},
"placeholderIndex": 1,
"id": "_5",
"positionRelativeTo": "map",
"name": "Bookmark",
"label": "Bookmark_2",
"isThemeWidget": false,
"uri": "widgets/Bookmark/Widget",
"openAtStart": true
},
Klas,
For the x,y in the url this is NOT built into the WAB Stem App. But here is a link to where I detail what has to be changed to make this work:
https://community.esri.com/message/399090#399090
As far as making the bookmark widget open at startup that is as simple as editing the config.json to include
"openAtStart": true
so the widget element look like this:
{
"position": {
"left": 55,
"top": 45,
"width": 400,
"height": 410
},
"placeholderIndex": 1,
"id": "_5",
"positionRelativeTo": "map",
"name": "Bookmark",
"label": "Bookmark_2",
"isThemeWidget": false,
"uri": "widgets/Bookmark/Widget",
"openAtStart": true
},
For widgets in the Widget Pool, there is a bug with the openAtStart behavior. I logged it as WebApp-001095 and a few hours ago someone else logged it as WebApp-001126. You can see them here.
Was this bug ever resolved? The page in the link you provided is unavailable. If you could let me know that would be great, thank you!
Neither bug report has been resolved. I worked around it by putting the widget pool widget I wanted to open at startup as the first widget in the widget pool. Later, I stopped using the openAtStart config parameter in favor of a widget I wrote that is an onScreen widget and can open as may widgets at startup as I want.
Thanks for your reply Larry! Good to know its not just me. Although I cannot get open at startup param to work for me no matter where the app it resides in the widget pool for any widget (even a basic built in widget like the basemaps). Did you do anything else additionally to finally get it to work?
No, as far as I know, Robert's answer still works.
How about using "openAtStart": true for widgets in the side control panel? I can only get this to work for off-panel widgets.
I would like the Layer List widget in my sidebar to be open when app starts-- to create the typical map and toc look.
Gregory,
This involves a bit of code. See these threads