//to get the path of the desired attachment from the parent issue:string attachmentPath = getAttachmentPath(key, attachment name);
i am trying to get attachment path using sil cprime power scripts plugins, but having a hard time to understand how to get all the attachment name.
if anyone can help me?
The reason you can't find a function to get the attachments names is because you don't need one. Attachments is a standard variable in PS. To use it you would do something like this:
string parent = key.parent;
string [] attachments = %parent%.attachments;
for(string a in attachments) {
string attachmentPath = getAttachmentPath(key, a);
}
To get a list of the standard variables see https://confluence.cprime.io/display/SIL/Variable+Resolution
Let me know if you need further assistance.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.