Skip to main content

⚠️ Please note that this topic or post has been archived. The information contained here may no longer be accurate or up-to-date. ⚠️

Bug - "Kind as text" is broken in Applescript Standalone

Comments

1 comment

  • Eric Nepean
    Case number 258288

    The Applescript below below is now tested and it works.

    [quote="Eric Nepean" wrote:
    ... I suppose it would be cleaner to do the conversion to string right in the converter. Property value in, string out.
    Untested:on convertKind(kind_property)
    tell application "Capture One 10" to set kind_s to kind_property as text
    if kind_s does not contain "constant" then
    return kind_s
    else
    set code_start to (get length of kind_s) - 2
    set kind_code to get (text code_start thru (code_start + 1) of kind_s)

    if kind_code = "pj" then
    set kind_res to "project"
    else if kind_code = "gp" then
    set kind_res to "group"
    else if kind_code = "al" then
    set kind_res to "album"
    else if kind_code = "sm" then
    set kind_res to "smart album"
    else if kind_code = "fv" then
    set kind_res to "favorite"
    else if kind_code = "ff" then
    set kind_res to "folder"
    else if kind_code = "ct" then
    set kind_res to "catalog"
    else if kind_code = "sd" then
    set kind_res to "session"
    else
    error "Kind code not found: " & kind_s
    end if
    end if
    return kind_res
    end convertKind
    0

Post is closed for comments.