{%
    if option == 'InvalidService' then
        echo('Invalid service name.')
    else 
        if option ~= 'RMCP' and portcount == 2 then
            echo(string.format('Set %s service port failed.\r\nThe number of input ports does not match the service type.', option))
        elseif (option == 'KVMIP' or option == 'VNC' or option == 'VirtualMedia' or option == 'Video' or option == 'SNMP') and IsMultihost == 'Multihost' then
            echo("Invalid service name.")
        else
            echo(string.format('Set %s service port to %s successfully.', option, portstring))
        end
    end
%}