|
POST
|
I want to use about ten domains each having between 10-100 coded values. The values may change over time as I receive feedback on the validity. Typing them by hand is not a feasible option I created CSV's using Excel with the following format: 1;Snake 2;Fish 3;Mammal 4;Critter and so on Using arcpy.CreateDomain_management(WorkSpace, "D_all", "all", "LONG", "CODED", "DEFAULT", "DEFAULT") I can create a domain which I can populate using arcpy.TableToDomain_management(all_csv, "Field1", "Field2", WorkSpace, "D_all", "all", "REPLACE") So far, so good. But I don't seem to be able to use this domain in my featureclass properties/subtypes unless I use a 'SHORT' instead of a 'LONG'. Unfortunately when I create the domain using a 'SHORT' I get an error when using the TableToDomain function (error 000307) does anyone has any idea on how to either populate the domain using a 'SHORT' as the coded value or how to get it working in my featureclass properties/subtypes? regards, Bert By the way, how can I mark code as 'code' in this editor??
... View more
10-27-2014
08:47 AM
|
0
|
5
|
4622
|
|
POST
|
Hi Jessica, How do you store the photo's? As a blob in the table or as a (hyper-)link to an external source? I'm trying to achieve the same goal, hopefully we can team up.
... View more
10-21-2014
04:11 AM
|
0
|
2
|
1536
|
|
POST
|
Jeff, I was able to upload a file like you described. The question remains why I should use a different approach from when using agol at work. Still, it's better than before 🙂 regards, Bert
... View more
09-26-2014
05:51 AM
|
0
|
1
|
1133
|
|
POST
|
Well, this might work Jeff, I'll have to check on that, will keep you posted on that. But on my work I do uploads using a server URL like http://kdhl.maps.arcgis.com and that works fine. Is a home use user different from a 'professional user'? regards, Bert
... View more
09-26-2014
05:41 AM
|
0
|
2
|
1133
|
|
POST
|
As a desktop for home use user, what serverurl should I use when publishing a feature service from desktop to agol? This is the screen I can't get past: thanks in advance for your answer. Bert
... View more
09-26-2014
04:39 AM
|
0
|
4
|
1601
|
|
POST
|
In my limited experience 'failed to execute' was caused by errors in parameters. Does the country has something special like a name with a space? "new zealand" for example? Can you test you script with only this country and troubleshoot from there?
... View more
09-26-2014
12:53 AM
|
0
|
0
|
708
|
|
POST
|
That's exactly what I mean, thanks Dan, and thank you Matthew for your code example.
... View more
09-15-2014
11:53 PM
|
0
|
0
|
10769
|
|
POST
|
Hi, how do I read geodatabase content using python? Creating a file geodatabase is not a problem but after that, how can I acces the file GDB using python and -for example- lists its content tia, Bert
... View more
09-14-2014
10:56 AM
|
0
|
3
|
18426
|
|
POST
|
Took some time but here is my solution using 'Calculate Value': [ATTACH=CONFIG]29608[/ATTACH] Using 'parse path' and choosing NAME I get two strings in Value1 and Value2. These are both preconditional for the 'calculate value' Pay ATTENTION to the double quotes around the %variables% in the expression; they costed me most of the day 😉 So the expression is: x("%Value1%", "%Value2%") The code block concatenates some parts of the original names into a decriptive name which is used to name the resulting raster (example above is from a test model which doesn't do much beside create the output_value) Works like a charm, hope this will be helpful for someone. Regards, Bert
... View more
12-05-2013
05:07 AM
|
0
|
0
|
876
|
|
POST
|
Hello, I'm developing a model in which I take two rasters as input, do some rastercalculation and produce a third raster. As long as I provide a name for this resulting raster in the "output raster" field of the rastercalculator everything is fine. Now I would like to automatically generate the name of the resulting raster from parts of both input names so later I can determine from the name which rasters were used as input. (All my input rasters have a strict name convention) Basically I'm trying to generate a string which I can then use as inline variable in the output raster box of the rastercalculator, something along the lines of: output1 = (value1[2:4]+value1[6:7]+value2[2:4]+value2[6:7]) First I've tried this with the model only tool "calculate value" but no succes, perhaps I cannot create a string using this tool? Secondly I tried to write a scripttool which generates an output string from two inputs, seems to work on itself but whatever I try I cannot get it accepted in the rastercalculator' output raster field. It's either ignored or I get the value '1' filled in Is there anybody who can point me towards what I'm missing here? Should a string work? Can I generate a string using 'calculate value'? Am I overlooking another tool which is capable of manipulating strings like I want? Should I avoid using strings altogether and think differently? (how?) Any help is greatly appreciated (I'll mention you in my documentation :-)) and one day I hope to return the favor. regards, B
... View more
12-05-2013
12:21 AM
|
0
|
1
|
2137
|
|
POST
|
I had the same error after migrating models (home --> school) using self-made python scripttools. Arcmap versions were identical The scripttools themselves were ok after migration and could be executed by themselves All models using these scripttools had a red cross and wouldn't work: "Unable to execute the selected tool" Editing the models in modelbuilder showed the scripttools with a red cross, 'edit' was greyed out. Using 'relative paths' didn't solve it. Solution for me was to rightclick and 'open' each scripttool in the model in modelbuilder and navigate to and select the scripttool. I still have to figure out what caused this but I hope this is of help for someone.
... View more
12-01-2013
11:10 PM
|
0
|
0
|
1443
|
|
POST
|
Hello, newbie here. I'm combining two rasters into an output using the Rastercalculator tool and that work fine, got the tool into modelbuilder and that works great as well. Now I need to do additional steps like looping through more files to repeat the process and prompting the user for some choices so I'm looking into python using arcpy to do the rastermath. I cannot find the syntax to do this: [INDENT]arcpy.gp.RasterCalculator_sa("""(Int("2010cl3" / 10) * 10) + (Int("2013cl5" / 10))""","Y:/case13/first/scrap_db.gdb/outputras")[/INDENT] in arcpy. I understand I should not use rastercalculator in python but instead use arcpy.sa, can someone give an example please? Thanks in advance
... View more
11-24-2013
01:00 AM
|
0
|
2
|
990
|
|
POST
|
I find more situations (modelbuilder, python script, etc) where a filename starting with a number doesn't work but starting with a character does. No problem but took a while to figure it out.
... View more
11-17-2013
12:08 AM
|
0
|
0
|
881
|
|
POST
|
Thanks @ Shiko! All my raster datasets start with a year as in 1990xxxx. You mentinoned "...name is invalid...." and that was it, renaming into b1990xxxx solved my problem.
... View more
11-09-2013
09:33 PM
|
2
|
2
|
6088
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 12-09-2025 05:56 AM | |
| 1 | 10-08-2025 03:45 AM | |
| 1 | 10-01-2025 06:55 AM | |
| 1 | 07-01-2025 05:46 AM | |
| 1 | 06-02-2025 05:19 AM |