为什么现在脚本生成图片表格出现错误,返回下面

Form Dat a.append: Expe c ted value ("Blob { name: '桂南省区-缓发数据-17835 61418448 .P N G', Symbol(type): 'application/octet-stream', Symbol(buffer): <Buffer 89 50 4 d e7 4c e9 00 00 00 09 70 48 59 73 00 00 0 e c 4 00 00 0 e c 4 01 ... 170425 more bytes> }") to be an instance of Blob. ()
福建省
浏览 581
1
5
分享
5 +1
7
1 +1
全部评论 7
 
林泽泰
林泽泰

@金山办公

很抱歉给大家带来的问题,目前原因已经定位到,内部会抓紧时间修复,上传url图片可以通过转base64的方式临时规避,参考代码如下: function imageUrlToBase64(url) { const res = HTTP.fetch(url) const contentType = res.headers['content-type'] const buffer = res.binary() const base64 = buffer.toString('base64') return `data:${contentType};base64,${base64}` } const fileData = 'https://xxx' const base64 = imageUrlToBase64(fileData) Application.Sheets("s").RecordRange('B',"@pic").Value = DBCellValue([{"fileData":base64,"fileName":"1.png","height":0.1,"width":0.2}])
作者已采纳    广东省
举报
2
0
 
陈俊龙
陈俊龙

@金山办公

内部紧急修复中,可以先转成base64临时规避~ https://365.kdocs.cn/l/cmncBAfUUHXS?R=L1MvMQ==
   广东省
举报
1
0
 
19号
同问,最近的脚本一堆问题,都没见官方有解释和处理的。
   江西省
举报
0
0
 
人生何处不相逢
unhandledTypeError:FormData.append: Expected value ("Blob { name: '邓水霞.png', Symbol(type): 'application/octet-stream', Symbol(buffer): <Buffer 89 50 4e 47 0d 0a 1a 0a 00 00 00 0d 49 48 44 52 00 00 03 0c 00 00 05 01 08 02 00 00 00 ae 53 91 c8 00 00 00 09 70 48 59 73 00 00 0e c4 00 00 0e c4 01 ... 217975 more bytes>}") to be an instance of Blob.
   安徽省
举报
0
0
 
人生何处不相逢
我也是的,今天上午都严重影响工作了
   安徽省
举报
0
0
 
斌斌想睡了
昨天脚本还是可以正常运行的, 早上测试了一下发现不行,脚本返回的错误值如上
   福建省
举报
1
0
 
高毅帅
同问
   河南省
举报
0
0