Skip to main content
Known Participant
February 15, 2022
Question

Process Model

  • February 15, 2022
  • 12 replies
  • 8 views

Hi,

I am new to Appian and trying to work on an Asset Management Application. 

I am getting these two errors while running my Request Asset Process Model.

1) Invalid Cast: Cannot cast from type 'AT_Request' to type 'Boolean' (Data Inputs). Where should I fix the problem? 

2) The image at index 1 in an image gallery component [label=“”] has an invalid value for “document”. “document” must not be null. I am having this issue with my image component in all interfaces. 

When I test the interface with rule!GetAssetbyID(), the error is fixed but having a problem when running the process model.  My rule input takes the value of integer for Image. Is that the problem? I tried todocument and other options in the forum but no luck so far. 

 

Hope I can be helped.

Thanks

    12 replies

    gopalk2865
    Participating Frequently
    February 16, 2022

    Hi,

    For issue 1, looks like casting problem, means you are passing a value of type CDT into Boolean.

    For issue 2 , you need to make sure ,you are not providing null values as document

    Can you show the code of image configuration?

    Known Participant
    February 16, 2022

    Hi,

    Thanks for your response. 

    I fixed the first problem. 

    The second one I fixed in the interface but having the problem when running the process model. 

    !formLayout(
    label: "REQUEST ASSET APPROVAL FORM",
    contents: {
    a!sectionLayout(
    contents: {
    a!columnsLayout(
    columns: {
    a!columnLayout(
    contents: {
    a!textField(
    label: "REQUESTED ASSET DETAILS",
    labelPosition: "ABOVE",
    saveInto: {},
    refreshAfter: "UNFOCUS",
    readOnly: true,
    validations: {}
    )
    }
    ),
    a!columnLayout(
    contents: {}
    )
    }
    ),
    a!imageField(
    label: "Image",
    labelPosition: "ABOVE",
    images: {
    a!documentImage(
    ri!assetinput['recordType![AT Asset Management.fields.image]
    )

    },


    size: "MEDIUM",
    isThumbnail: false,
    style: "STANDARD"

    Thanks 

    gopalk2865
    Participating Frequently
    February 16, 2022

    In process model , are you passing record type into rule input?