Skip to content

Commit 9e61daf

Browse files
committed
Add features for formula error check and external reference checks in Excel files.
1 parent f2a7ae5 commit 9e61daf

File tree

409 files changed

+2149
-583
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

409 files changed

+2149
-583
lines changed

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,4 +64,7 @@ target/
6464
.ipynb_checkpoints
6565
/.vscode
6666
/.swagger-codegen
67-
test-reports
67+
test-reports
68+
.idea
69+
test/
70+
TestData/

Examples/Example_PostBatchSplit.py

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
import os
2+
import sys
3+
from asposecellscloud.apis.cells_api import CellsApi
4+
from asposecellscloud.models import *
5+
from asposecellscloud.requests import *
6+
7+
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
8+
remote_folder = 'TestData/In'
9+
10+
local_book1 = 'Book1.xlsx'
11+
remote_book1 = 'Book1.xlsx'
12+
local_my_doc = 'myDocument.xlsx'
13+
remote_my_doc = 'myDocument.xlsx'
14+
15+
batchSplitRequestMatchCondition = MatchConditionRequest(regex_pattern= '(^Book)(.+)(xlsx$)' )
16+
batchSplitRequest = BatchSplitRequest(source_folder= remote_folder ,format= 'Pdf' ,out_folder= 'OutResult' ,match_condition= batchSplitRequestMatchCondition )
17+
mapFiles = {
18+
local_name: local_name
19+
}
20+
request = UploadFileRequest( mapFiles, remote_folder + '/' + remote_name,storage_name= '')
21+
api.upload_file(request)
22+
mapFiles = {
23+
local_name: local_name
24+
}
25+
request = UploadFileRequest( mapFiles, remote_folder + '/' + remote_name,storage_name= '')
26+
api.upload_file(request)
27+
28+
request = PostBatchSplitRequest( batchSplitRequest)
29+
api.post_batch_split(request)

Examples/Example_PostClearObjects.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,11 @@
66

77
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
88
book1_xlsx = 'Book1.xlsx'
9-
data_source_xlsx = 'datasource.xlsx'
109

1110
objecttype = 'chart'
1211

1312
mapFiles = {
14-
book1_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +book1_xlsx ,data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
13+
book1_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +book1_xlsx
1514
}
1615

1716
request = PostClearObjectsRequest( mapFiles, objecttype)

Examples/Example_PostCompress.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,12 @@
55
from asposecellscloud.requests import *
66

77
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
8-
assembly_test_xlsx = 'assemblytest.xlsx'
98
data_source_xlsx = 'datasource.xlsx'
109

1110
compress_level = 50
1211

1312
mapFiles = {
14-
assembly_test_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +assembly_test_xlsx ,data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
13+
data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
1514
}
1615

1716
request = PostCompressRequest( mapFiles,compress_level= compress_level)

Examples/Example_PostExport.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,13 @@
55
from asposecellscloud.requests import *
66

77
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
8-
assembly_test_xlsx = 'assemblytest.xlsx'
98
book1_xlsx = 'Book1.xlsx'
109

1110
format = 'csv'
1211
object_type = 'workbook'
1312

1413
mapFiles = {
15-
assembly_test_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +assembly_test_xlsx ,book1_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +book1_xlsx
14+
book1_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +book1_xlsx
1615
}
1716

1817
request = PostExportRequest( mapFiles,object_type= object_type,format= format)

Examples/Example_PostLock.py

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import os
2+
import sys
3+
from asposecellscloud.apis.cells_api import CellsApi
4+
from asposecellscloud.models import *
5+
from asposecellscloud.requests import *
6+
7+
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
8+
needlock_xlsx = 'needlock.xlsx'
9+
10+
mapFiles = {
11+
needlock_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +needlock_xlsx
12+
}
13+
14+
request = PostLockRequest( mapFiles, '123456')
15+
api.post_lock(request)

Examples/Example_PostProtect.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,12 @@
66

77
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
88
assembly_test_xlsx = 'assemblytest.xlsx'
9-
data_source_xlsx = 'datasource.xlsx'
109

1110
mapFiles = {
12-
assembly_test_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +assembly_test_xlsx ,data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
11+
assembly_test_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +assembly_test_xlsx
1312
}
1413
protectWorkbookRequest = ProtectWorkbookRequest(aways_open_read_only= True ,encrypt_with_password= '123456' )
1514

16-
1715

1816
request = PostProtectRequest( mapFiles, protectWorkbookRequest,password= '123456')
1917
api.post_protect(request)

Examples/Example_PostReplace.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@
55
from asposecellscloud.requests import *
66

77
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
8-
assembly_test_xlsx = 'assemblytest.xlsx'
98
data_source_xlsx = 'datasource.xlsx'
109

1110
mapFiles = {
12-
assembly_test_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +assembly_test_xlsx ,data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
11+
data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
1312
}
1413

1514
request = PostReplaceRequest( mapFiles, '12', 'newtext')

Examples/Example_PostSearch.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@
55
from asposecellscloud.requests import *
66

77
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
8-
assembly_test_xlsx = 'assemblytest.xlsx'
98
data_source_xlsx = 'datasource.xlsx'
109

1110
mapFiles = {
12-
assembly_test_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +assembly_test_xlsx ,data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
11+
data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
1312
}
1413

1514
request = PostSearchRequest( mapFiles, '12')

Examples/Example_PostSplit.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,12 @@
55
from asposecellscloud.requests import *
66

77
api = CellsApi(os.getenv('CellsCloudClientId'),os.getenv('CellsCloudClientSecret'),"v3.0",os.getenv('CellsCloudApiBaseUrl'))
8-
assembly_test_xlsx = 'assemblytest.xlsx'
9-
data_source_xlsx = 'datasource.xlsx'
8+
book1_xlsx = 'Book1.xlsx'
109

1110
out_format = 'csv'
1211

1312
mapFiles = {
14-
assembly_test_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +assembly_test_xlsx ,data_source_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +data_source_xlsx
13+
book1_xlsx: os.path.dirname(os.path.realpath(__file__)) + "/../TestData/" +book1_xlsx
1514
}
1615

1716
request = PostSplitRequest( mapFiles, out_format)

0 commit comments

Comments
 (0)