|
POST
|
Dear Majdoleen Awadallah, Does your workbench create the correct output as you expect (I mean, there are 2 aspects: 1. To create the wanted file format, 2. Covert coordinate systems, if needed)? If positive, Then you need to - link the source to e.g. 'SourceDataset_ACAD' user variable name, - link the result to e.g. 'FME_SHAREDRESOURCE_DATA' server variable Then after publishing it to fme server (I use fme cloud) you need to learn and adapt the code in FME Server Playground - Upload File In Session so it will fit within your web application. Do you develop web application or Web AppBuilder custom widget? Do you use 2D or 3D ? I'm doing the 2nd option with 3D Scene. I managed to activate the exaple code within my web app and my fme cloud with my input and output formats and coordinate systems (I don't need to insert the result file into a map in my example web app), and now in midst of developing and debugging the custom widget stuff, where I'll have to insert the result into the 3D web scene. Advice: Referring the fme stuff - I have asked questions in fme community (of e.g. fme cloud) and got serious help. In addition, if the company you work in has licence for the fme workbench, you are entitled help from the fme-agency that sold the workbench to your company. Michael.
... View more
08-10-2020
03:21 AM
|
4
|
7
|
5006
|
|
POST
|
Dear Robert, Thank you very much! You always save my day! It works! Only I found that in order to get the alert when I re-open the in-panel widget, I have to reset "isOpening" inside setTimeout: onOpen: function () { if (!this.isOpening) { this.isOpening = true; let missing = []; // ... code lines to test parameters if (missing.length !== 0) { let errMsg = `missing config param${missing.length > 1 ? "s" : ""}: ${missing.join(", ")}`; alert(errMsg); } else { // code lines to do if parameteers are OK } // close widget setTimeout(lang.hitch(this, function () { this.isOpening = false; //PanelManager.getInstance().closePanel(this.id + '_panel'); WidgetManager.getInstance().closeWidget(this); //best way to close }), 300); } }, // eof onOpen() So, now it works - thank you for explaining that closing the widget from within onOpen() creates race conditions, and for showing how to handle it. If I may only ask, I wish to also get explanations: What is the function of "isOpening" property? What exactly is the cause of the race conditions? and how does the setTimeout handle it? Only in first opening, I got my "exact expected behaviour" - at first, the widget icon shifts up, then, I see the alert ,then, the widget icon shifts down but in all successive openings, first I see the alert, and only AFTER the alert, the widget icon shifts up, then shifts down. So, In order to always get my "exact expected behaviour" I had to "wrap" the whole contents of onOpen() inside an additional setTimeout (not shown in the above code). I assume that this is connected smehow to the same race conditions? Why if I use "closePanel(this.id + '_panel')" instead of closeWidget(this), I get an unwanted behaviour - I do see the alert only on each 2nd click of the widget? With appreciation, Michael
... View more
08-09-2020
10:11 PM
|
0
|
2
|
1979
|
|
POST
|
In in-panel custom widget onOpen() function, if some critical config aram is empty, I output alert, then I want to close the widget (as if someone clicked the "x" button, or as I have not clicked to open it at all). I wrote: PanelManager.getInstance().closePanel(this.id + '_panel'); but it failed, maybe because I'm "inside" onOpen() ? My questions: 1. How to nicely close in-panel custom widget programatically from within onOpen()? 2. My first lines of onPen() are: if (!this.isOpening) { this.isOpening = true; Do I have to reset this.isOpening to false before I close the widget? 3. The code in WidgetManager.js id: if (widget.state === 'closed') { html.setStyle(widget.domNode, 'display', ''); widget.setState('opened'); try { widget.onOpen(); } catch (err) { console.error('fail to open widget ' + widget.name + '. ' + err.stack); } } Should I exit onOpen() with exception and put the alert inside the Widgetmanager? 4. I wish that the widget will really cose (the icon will go back downwards. 5. I wish that I'll get the alert every time I click on the widget (not only in the first time). Help will be greatly appreciated, Michael
... View more
08-09-2020
09:26 AM
|
0
|
4
|
2049
|
|
POST
|
Dear Majdoleen Awadallah, Please see also my answer to Carlos there.
... View more
08-08-2020
11:44 PM
|
3
|
0
|
7692
|
|
POST
|
Dear Carlos, Thank you! I'm in midst of doing it by another way - using fme cloud server (and workspace buit in fme workbench). I'll update you when I've come to conclusions. Michael
... View more
08-08-2020
11:42 PM
|
6
|
9
|
5006
|
|
POST
|
I need to develop a custom widget to import 2D or 3D KML or shapefile(s) or gdb into the 3D Scene. I'm still a newbie, and in great need of instructions where to look and/or code examples. Help will be appreciated. Michael
... View more
07-30-2020
10:47 PM
|
0
|
2
|
1506
|
|
POST
|
I need to develop a custom widget for Web AppBuilder (developer edition) 2.16 in order to display a DWG file (2d or 3d) in 3D scene. The DWG will always be in ITM coordinates (Israel TM grid, that is EPSG:2039) even if not specified. The DWG contains Lines, Polygons and Points. Most of the time the other layers except lines will be empty. What choice is more preferred/applicable - 1. Convert to 3 shape files (for lines, polygons and points) and display them? 2. Convert to KML and display it (is there a way to display 2d/3d KML?)? 3. Display the DWG directly (is a way to do it?) ? I assume the only applicable way is 1, but I want to know more in order to be sure - - Is conversion from DWG needed at all? - Converting to KML is easy, but maybe KML 2D/3D could not be added to 3D scene? - Or maybe there are more suitable ways to go by? Help will be greatly appreciated. Michael
... View more
07-29-2020
06:03 AM
|
4
|
11
|
6937
|
|
POST
|
I am relatively new to ArcGIS Web AppBuilder (Developer Edition) 2.16 in last 2 months I've written several custom widgets, yet there are 3 areas I feel I have not enough knowledge: 1. When do I need to do this.own and what are the parameters I learned that this.own is used to prevent memory leak, but I don't know when it is needed and when it is not needed, and the meaning of its parameters. 2. When do I need to use dijit/_WidgetsInTemplateMixin and what is the usage function of postMixInProperties: function() {...} I learned that postMixInProperties is called very early, but I don't know exactly why it is needed at all, and if there are cases where dijit/_WidgetsInTemplateMixin is needed but postMixInProperties function is not needed. 3. I'd like to get a little comprehensive explanation about what issues should be handled in each of the functions: postCreate, startup, and onOpen, since when I write new custom widgets, sometimes I am not sure what type of tasks to put in each, e.g. where to put this.sceneView.when(){...} and similar things that refer viewModels, graphics etc.. Help will be greatly appreciated. Michael
... View more
07-16-2020
01:33 PM
|
1
|
1
|
2216
|
|
POST
|
Dear Robert, Thank you! As usual, your help is very effective and helpful - I succeeded to open LayerList widget from within my slice custom widget by learning from WAB example stemapp/widgets/samplewidgets/WidgetCommunication - THANK YOU! note: In order to have LayerList widget work under API 4.16 I had to remove 'dojo/i18n!esri/nls/common' from define and apiNlsBundle from function arguments. It works. I see t's not needed in 4.16, though I'd like to know what it is? and why it's not needed anymore in 4.16 ? Michael
... View more
07-14-2020
08:55 PM
|
0
|
0
|
3248
|
|
POST
|
Dear Robert, I'm debugging my slice custom widget and it works, however I have questions concerning the UI code needed for displaying the LayersList: In esri example BuildingSceneLayer with Slice widget | ArcGIS API for JavaScript 4.16 There is the paragraph to display the layers list at top-left // Add a layer list widget const layerList = new LayerList({ view: view }); view.ui.empty("top-left"); view.ui.add(layerList, "top-left"); Since the slice widget popup itself is displayed at top-left, I want to display the layers list at bottom-right, so I write (in the widget.js) this.sceneView.ui.empty("bottom-right"); this.sceneView.ui.add(this.layerList, "bottom-right"); but the whole this.sceneView.ui is hidden since class esri-ui-corner-container is hidden which is the father of the 4 corners. and top-left corner is not empty. My questions: 1. How should I handle correctly the display of the layers list? Below are the 4 lines I did, but maybe there is a cleaner and nicer way?: this.sceneView.ui.empty("bottom-right"); this.sceneView.ui.add(this.layerList, "bottom-right"); document.getElementsByClassName("esri-ui-corner-container")[0].style.display = "block"; document.getElementsByClassName("esri-ui-top-left")[0].style.display = "none"; And I don't know yet why top-left of esri-ui-corner-container is not empty already but has some widgets in it? 2. Could I (how?) display the layerslist in a popup that the user can drag upon the screen (or even minimize and maximize?) I'll appreciate your help
... View more
07-14-2020
08:04 AM
|
0
|
1
|
3248
|
|
POST
|
Dear Robert, Thank you! I've succeeded to activate my in-panel custom widget (which is based on API 4.16) by learning from your zip of screenshot and from more widgets, and to to solve most my bugs, and I'm continuing debugging. Michael
... View more
07-14-2020
12:22 AM
|
0
|
0
|
3248
|
|
POST
|
Shay, I've succeeded to solve most my bugs... I'm continuing debugging. Thank you! Michael
... View more
07-14-2020
12:19 AM
|
1
|
0
|
2668
|
|
POST
|
Dear thejus kambi, I'm facing same problem. I added some custom widget in the widgets-panel and have the same error. Perhaps because my widget use API 4.16, maybe not all needed classes are loaded in time?? You wrote "To fix it, I included the measurement widget in the require present in the html page. this ensured that the required js are retrieved before it loads my custom widget.". Please explain since I don't understand what to do - which is this html page and what exactly to write there. Thanks, Michael
... View more
07-13-2020
11:03 PM
|
0
|
0
|
3300
|
|
POST
|
When I enter esri demo link for IntegratedMeshLayer modification - IntegratedMeshLayer modification | ArcGIS API for JavaScript 4.16 I get in the console multiple identical errors: dojo.js:115 [esri.views.3d.layers.SceneLayerView3D] Failed to store node in IndexedDB cache: 2755: QuotaExceededError g._consoleWriter @ dojo.js:115 all errors are identical, except number of cache is different between errros. 1. What is the cause for the error? 2. I want to build WAB custom widget for this capability. Can I ignore the error? 3. What could be done so that the error will not appear? 4. Is it esri issue or that the error depends on my setups? Attached: screenshot Help will be greatly appreciated.
... View more
07-13-2020
09:12 AM
|
0
|
2
|
2332
|
|
POST
|
Thanks, Shay! To answer your curiosity - I changed 3 lines above your line - I canged: var apiVersion = '4.15'; to 4.16 but it was not enough. After seeing your doc link, I changed both apiVersion to 4.16 and also apiUrl within the comment. I saw that if I download the app from within WAB, the apiUrl is uncommented within the zip, And I saw also that if I click the launch button of the app from within the WAB, it also uses the 4.16 API, due to apiVersion var. So, indeed I solved the problem how to run on 4.16 My problem now is an error in my slice widget, but I don't know how to debug and find it. screenshot attached Could I attach zip of my in-panel widget code? Michael
... View more
07-13-2020
01:12 AM
|
0
|
1
|
2668
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 02-13-2026 04:27 AM | |
| 1 | 12-15-2024 12:09 AM | |
| 1 | 08-01-2024 03:45 AM | |
| 1 | 01-04-2024 04:00 AM | |
| 1 | 03-28-2024 01:25 AM |
| Online Status |
Offline
|
| Date Last Visited |
02-13-2026
04:26 AM
|