Comments (4)
Hi Anders,
The argument type 'data' is a dictionary which has the few keywords defined in it which are made available at run time to be used in any of your custom function. Have you referred to page 7 in MDCS documentation present under Documentation folder??
if you wish to return multiple values from your custom function , you can return those values instead of "True"
e.g. return val1,val2
Hope this helps.
Best Regards,
Vijay
from mdcs-py.
Thanks the for the respons Vijay,
I have read the documentation but I still don’t understand. ☹
I have built a custom function that is checking whether or not a mosaic dataset exists. Since I do not understand how to return the answer to my calling bat-file (or powershell script) I have to write the answer to a file and then open that file to get hold of the value.
How can I return the answer in a better way? Is the data['response'] a way of doing it.
Do you have an example?
from mdcs-py.
Hi Anders ,
Apologies for the late reply.
If your objective is to somehow return the answer back to the batch file , I can suggest using sys.exit() .
So if the mosaic doesnt exist then you exit out the program with sys.exit(0) error.
This error can then be used using "errorlevel" inside your bat file.
data['response'] would not be ideal in this case.
Hope this helps.
Best Regards,
Vijay
from mdcs-py.
@anpe00 did the suggestion from @vijaygit02 resolve the issue
from mdcs-py.
Related Issues (20)
- Calculate Value expression / code block - 'not defined' HOT 7
- SyntaxWarning: "is not" with a literal.
- Updated MDTools Setup to support 3.1 version of ArcGIS Pro
- Mosaic Layer as input for MDCS HOT 3
- How to register Mosaic Datasets Footprint layer for web tool publication HOT 3
- Add Deep Learning Commands
- Issue related to Pro with MDCS PYTs/custom objects. HOT 1
- Introducing MDCS Steps functionality HOT 1
- Add standard Lidar commands
- MDTools Setup to support ArcGIS Pro 3.2
- Support for longer namespaces such as arcpy.ia..
- MDCS access support via Jupyter Notebooks
- Update Set Mosaic Dataset Properties .py file HOT 1
- Add Point to Raster tool to MDCS
- Add support to modify the MDCS command chain from a User Function
- Update Master.xml with new parameters for all the relevant GP tools
- MDCS fix ArcGIS version check for Pro
- MDCS/ removal of redundant code that are no longer needed for SP command invocation
- Pro 3.2 support?
- To support user variable values with ';' character
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mdcs-py.