Initial commit - Stand 26.04.2026
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
import openpyxl, os, json
|
||||
|
||||
base = r'C:\Users\renet\.openclaw\workspace\buchhaltungs-app'
|
||||
result = {'kredite': [], 'nebenkosten': [], 'planung': []}
|
||||
|
||||
for f in sorted(os.listdir(base)):
|
||||
if not f.endswith('.xlsx'):
|
||||
continue
|
||||
fp = os.path.join(base, f)
|
||||
size_mb = os.path.getsize(fp) / 1024 / 1024
|
||||
if size_mb > 2:
|
||||
print(f'SKIP (too large): {f} ({size_mb:.1f} MB)')
|
||||
continue
|
||||
try:
|
||||
wb = openpyxl.load_workbook(fp, data_only=True, read_only=True)
|
||||
print(f'\n=== {f} ===')
|
||||
for sn in wb.sheetnames:
|
||||
ws = wb[sn]
|
||||
rows = []
|
||||
for row in ws.iter_rows(max_row=60, values_only=True):
|
||||
vals = [v for v in row if v is not None]
|
||||
if vals:
|
||||
rows.append(vals)
|
||||
print(f' {vals}')
|
||||
wb.close()
|
||||
except Exception as e:
|
||||
print(f'ERROR {f}: {e}')
|
||||
Reference in New Issue
Block a user