从协作网站导入 Excel 工作表作为私人表不起作用我正在从 Teams/Sharepoint/Collab 网站导入 Excel 工作表,但“私人”设置不起作用。
dt = Open ("https://collab.company.com/:x:/r/sites/Folder/Shared%20Documents/General/Title%of%Excel.xlsm?download=1",
Worksheets( "Sheet1" ),
Use for all sheets( 1 ),
Concatenate Worksheets( 0 ),
Create Concatenation Column( 0 ),
Worksheet Settings(
1,
Has Column Headers( 1 ),
Number of Rows in Headers( 1 ),
Headers Start on Row( 1 ),
Data Starts on Row( 2 ),
Data Starts on Column( 1 ),
Data Ends on Row( 0 ),
Data Ends on Column( 0 ),
Replicated Spanned Rows( 1 ),
Replicated Spanned Headers( 0 ),
Suppress Hidden Rows( 1 ),
Suppress Hidden Columns( 1 ),
Suppress Empty Columns( 1 ),
Treat as Hierarchy( 0 ),
Multiple Series Stack( 0 ),
Import Cell Colors( 0 ),
Limit Column Detect( 0 ),
Column Separator String( "-" )
), Private
);When I replace the filepath with a local filepath, the table is Private, but when I'm using the filepath for the collab site, it doesn't read the Private. I've tried putting the Output Table("Name of Output Table") command in without the Private to see if the code is even reading anything after the filepath and that setting isn't recognized. Obviously, the Worksheet setting is recognized because it does return that specific worksheet, but I don't know why it isn't reading private or output table. It's also not because this is a .xlsm vs .xlsx file.
数据访问大规模定制视窗回复:从协作网站导入 Excel 工作表作为私人表不起作用好的,所以我找到了解决方法。 我仍然不知道为什么上面的方法会使私人的设置,但您可以通过将文件夹路径放置在“打开数据文件”窗口中访问协作站点,如下所示:
https://collab.company.com/sites/Folder/Shared Documents/General/
我以这种方式打开了文件,然后查看了该表的 JSL 脚本。
Open(
"\\collab.company.com@SSL\DavWWWRoot\sites\Folder\Shared Documents\General\Name of Document.xlsm",
Worksheets( "In-Process Config Table" ),
Use for all sheets( 1 ),
Concatenate Worksheets( 0 ),
Create Concatenation Column( 0 ),
Worksheet Settings(
1,
Has Column Headers( 1 ),
Number of Rows in Headers( 1 ),
Headers Start on Row( 1 ),
Data Starts on Row( 2 ),
Data Starts on Column( 1 ),
Data Ends on Row( 0 ),
Data Ends on Column( 0 ),
Replicated Spanned Rows( 1 ),
Replicated Spanned Headers( 0 ),
Suppress Hidden Rows( 1 ),
Suppress Hidden Columns( 1 ),
Suppress Empty Columns( 1 ),
Treat as Hierarchy( 0 ),
Multiple Series Stack( 0 ),
Import Cell Colors( 0 ),
Limit Column Detect( 0 ),
Column Separator String( "-" )
)
)
文件路径不同。 我不完全确定是什么@SSL\DavWWWRoot\意思是,但是当您将表设置为私有时,它可以工作。 它不必等待网页打开来创建路径。 我仍然想知道为什么会出现上述问题,因为这感觉像是一个奇怪的问题,但我发现的这种方法实际上更好。