Pmdx To Excel Converter [top] Jun 2026
import os import zipfile import xml.etree.ElementTree as ET from openpyxl import Workbook from openpyxl.styles import Font, Alignment class PmdxToExcelConverter: """ A converter class to transform SoftMaker PlanMaker (.pmdx) files into Microsoft Excel (.xlsx) files. """ def __init__(self, pmdx_path): self.pmdx_path = pmdx_path self.wb = Workbook() # Remove default sheet to ensure we only have extracted sheets self.wb.remove(self.wb.active) def convert(self, output_path=None): """Performs the extraction and conversion.""" if not output_path: output_path = os.path.splitext(self.pmdx_path)[0] + '.xlsx' try: with zipfile.ZipFile(self.pmdx_path, 'r') as archive: # PMDX stores its sheets as XML files inside the zip xml_files = [f for f in archive.namelist() if f.endswith('.xml')] # Filter or sort XML files mapped to sheets if needed for xml_file in xml_files: with archive.open(xml_file) as file_data: xml_content = file_data.read() self._parse_and_add_sheet(xml_file, xml_content) self.wb.save(output_path) print(f"✨ Successfully converted: output_path") return True except zipfile.BadZipFile: print(f"❌ Error: self.pmdx_path is not a valid PMDX/ZIP file.") return False except Exception as e: print(f"❌ An unexpected error occurred: e") return False def _parse_and_add_sheet(self, filename, xml_content): """Parses PMDX XML and writes it to the openpyxl workbook.""" # Clean up filename to use as Sheet Name sheet_name = os.path.splitext(os.path.basename(filename))[0] sheet_name = sheet_name.replace('sheet', 'Sheet ') ws = self.wb.create_sheet(title=sheet_name) root = ET.fromstring(xml_content) # PlanMaker XML namespaces (adjust according to specific SoftMaker versions if needed) # We search for row and cell tags. for row_idx, row_elem in enumerate(root.iter('row'), start=1): for col_idx, cell_elem in enumerate(row_elem.iter('cell'), start=1): # Extract text value value = cell_elem.text if value is not None: # Attempt numeric conversion for Excel try: if '.' in value: value = float(value) else: value = int(value) except ValueError: pass # Keep as string cell = ws.cell(row=row_idx, column=col_idx, value=value) # Basic style extraction example if cell_elem.get('bold') == 'true': cell.font = Font(bold=True) if cell_elem.get('align') == 'center': cell.alignment = Alignment(horizontal='center') ### 🚀 How to Use the Feature ```python # Initialize the converter with your .pmdx file converter = PmdxToExcelConverter("financial_report.pmdx") # Convert and save as .xlsx converter.convert("financial_report.xlsx") ``` ### 📌 How It Works * **PMDX is a ZIP**: PlanMaker files are zipped packages containing XML files representing sheets. * **Streamed Extraction**: It opens the zip in memory without extracting bulky files to your disk. * **Data Typing**: It automatically detects and converts numeric strings into actual Excel floats and integers. * **Style Retention**: It checks for basic flags like `bold` and `align` inside the SoftMaker XML tags and applies them to the output Excel file. Use code with caution. Copied to clipboard
Pmdx is a file format used by Project Management software, specifically by the project management tool, ProjectManager.com. Pmdx files contain project data, including tasks, resources, assignments, and other relevant information. While Pmdx files are useful for project management, they can be limiting when it comes to data analysis and integration with other tools. Pmdx To Excel Converter
Open the resulting .xlsx file. You will see something like this: import os import zipfile import xml
The PMDX file is the proprietary format used by PlanMaker , a component of the SoftMaker Office suite. Conversion is primarily necessary when sharing data with users who only have Microsoft Excel or other spreadsheet applications that do not natively support the .pmdx extension. Methods of Conversion * **Streamed Extraction**: It opens the zip in