Issue in exporting links in excel from record grid

I have a requirement to show the hyperlink when exported to excel from record grid . The associated DB column has a either a DOC Id or a url .

By exporting ,few fields are shown as desired (both label name with hyperlink), few are just shown with with label and no hyperlink and few are entirely skipped to show the excel.

I have the following sample code.. Is something wrong here?

a!gridColumn(
label: "File Name",
value: a!linkField(

links:a!safeLink(
label: fv!row['recordType!record.fieldname],
uri:
if(
left(
fv!row['recordType!record.docImage],
10
) = "[Document:",
document(
todocument(fv!row['recordType!record.docImage]),
"url"
),
fv!row['recordType!record.docImage]
)),
showWhen:a!isNotNullOrEmpty(
fv!row['recordType!record.docImage]),


showwhen:false
exportWhen: true,
align: "START"
),

Thanks

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer

    The link label is derived from a record "fieldname" value. To ensure the link label appears correctly, all records must have a valid (non-empty) value for that field. If the fieldname is blank, those records will be skipped entirely and no link label will be displayed.

    For the URI, there is a conditional logic implemented:

    It checks whether the docImage field contains the string "[Document".
    If this condition is true, the system retrieves and displays the document URL. (both label name with hyperlink)
    If the condition is not met, it will show docImage and link will not accessible.

    So overall, both the link label and URI behavior are entirely driven by the underlying record data and conditional logic.

Reply
  • 0
    Certified Lead Developer

    The link label is derived from a record "fieldname" value. To ensure the link label appears correctly, all records must have a valid (non-empty) value for that field. If the fieldname is blank, those records will be skipped entirely and no link label will be displayed.

    For the URI, there is a conditional logic implemented:

    It checks whether the docImage field contains the string "[Document".
    If this condition is true, the system retrieves and displays the document URL. (both label name with hyperlink)
    If the condition is not met, it will show docImage and link will not accessible.

    So overall, both the link label and URI behavior are entirely driven by the underlying record data and conditional logic.

Children
No Data