for(Row r : rows){
PagedResult<Attachment> attachments = smartsheet.sheetResources().rowResources().attachmentResources().getAttachments(sheetId, r.getId(), null);
System.out.println("attachments"+attachments.getData().size());
if(attachments.getData().size() > 0){
for(Attachment at : attachments.getData()){
System.out.println(String.format("Attachement ID[%s], URL{%s}",at.getId(),at.getUrl()));
}
输出:
答案 0 :(得分:0)
我现在明白了,迭代对象并伸出attachement将不会给你url,事实上你必须从该对象获取id然后再使用GetAttachment过程查询智能表i。 ë
Attachment at = smartsheet.sheetResources().attachmentResources().getAttachment(sheetId, att.getId());