Having trouble creating user defined model?

439
3
05-17-2013 07:35 AM
by Anonymous User
Not applicable
Original User: stevec

Forum,

Thank you in advanced. First let me say that I have been away for a while and I use to be able to do this on a regular basis.
What I am trying to do is build a simple model (10.1) to build a GDB, Create a Mosaic dataset, and add rasters to this dataset. I need it to be flexible and user defined and I can't remember how to add the user defined variables? I want the tool to run starting by

1. Creating the File GDB, user to fill in name and location
2. after the GDB is created (I have a precondition on the GDB for this) Create the Mosaic Dataset
3. While creating the Mosaic Dataset user defines the name, coordinate system, and any other variables desired
4. Then add rasters to the Mosaic Dataset, build pyramids, calculate statistics, build overviews and complete.

Should be easy enough but my mind is drawing a blank, so any input would be greatly appreciated.

Thanks
Steve
0 Kudos
3 Replies
by Anonymous User
Not applicable
Original User: dmhoneycutt

After adding a tool, like Create File Geodatabase, to your model, you need to create model variables for the tool parameters you want to expose.  Right-click the model and choose Make Variable > From Parameter.  Here's the help doc on model variables. Now, if you want to expose this model variable as a parameter a user can fill in, right-click the variable and choose Model Parameter.  A "P" appears next to the variable.  Here's the help doc on model parameters.

There's a tutorial on all this as well.
0 Kudos
by Anonymous User
Not applicable
Original User: stevec

Thank you Dale,

This is what I was trying to do, but maybe incorrectly? Let me ask, would I need to use Wildcard or expressions to validate the model preferences to work correctly? What I know of model building is that there needs to be established paths or files defined in order for the tools to work and run correctly. I would want to set them up where there were user defined paths and naming conventions and have the model run correctly? Thanks you for your advise and I will continue to look at this. If you can answer anymore about what I stated above that would be appreciated also. Thank You,

SteveC
0 Kudos
EjayLai
New Contributor
Forum,

Thank you in advanced. First let me say that I have been away for a while and I use to be able to do this on a regular basis.
What I am trying to do is build a simple model (10.1) to build a GDB, Create a Mosaic dataset, and add rasters to this dataset. I need it to be flexible and user defined and I can't remember how to add the user defined variables? I want the tool to run starting by

1. Creating the File GDB, user to fill in name and location
2. after the GDB is created (I have a precondition on the GDB for this) Create the Mosaic Dataset
3. While creating the Mosaic Dataset user defines the name, coordinate system, and any other variables desired
4. Then add rasters to the Mosaic Dataset, build pyramids, calculate statistics, build overviews and complete.

Should be easy enough but my mind is drawing a blank, so any input would be greatly appreciated.

Thanks
Steve



Hi Steve,

For goal #1, here are the two steps (or abc):

1). Right-click on the Create File GDB on the model layout (a) and select Make Variable > From Parameter(b) where you will find the things you are after: File GDB Location and File GDB Name
2). Then right-click on these parameters one by one and select Model Parameter(That's the magic touch lead to pop up for user to give a name and assign a location when the model is being run.

For the rest, Create Mosaic Dataset and Add Rasters to Mosaic Dataset, you can follow the same procedures (abc).

Hope you find this useful.
0 Kudos