MozillaZine

Change file association for some XML files

User Help for Mozilla Thunderbird
RouseA
 
Posts: 2
Joined: September 5th, 2017, 2:47 am

Post Posted September 5th, 2017, 3:02 am

We have developed an application that creates files in XML format, but with the extension .DUCX. If one of these files is attached to an e-mail and the recipient tries to open it, it opens with Wordpad. I would like it to open with our application DUCX.exe (if it is installed on the PC).

I have modified the mimeTypes.rdf file so now Thunderbird>>Tools>>Options>>Attachments includes the DUCX Content Type .DUCX, and I have tried setting the Action to both DUCX.exe and Always Ask. However, Thunderbird recognises the file contents as XML so over-rules the setting and always open the files in Wordpad.

Is there a way to overcome this?

tanstaafl
Moderator

User avatar
 
Posts: 43932
Joined: July 30th, 2003, 5:06 pm

Post Posted September 5th, 2017, 10:10 am

What is the Content-Type header for one of those attachments? It sounds like the problem is that it identifies itself as application/xml rather than application/ducx or application/xml+ducx. Thunderbird uses the MIME type, not the file extension, to determine what utility to open a attachment. http://www.solvusoft.com/en/file-extens ... n-ducx-om/ might be useful if you don't want to use view -> message source or control+U to view the raw message source and look at the attachments headers.

If you're stuck with it identifying itself as a .xml file I suggest you set the association for xml to always ask.

RouseA
 
Posts: 2
Joined: September 5th, 2017, 2:47 am

Post Posted September 7th, 2017, 6:33 am

Thanks for the response. I have copied the content of a typical file below, and as far as I can see it doesn't identify an application.

I don't see any option in Thunderbird to set the action for an XML file

Code: Select all
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Configuration>
  <DUCX>
    <Version>1.0.23.0</Version>
  </DUCX>
  <Target>
    <FirmwareVersion>1.0.33</FirmwareVersion>
  </Target>
  <FilePath>
    <Name>S:\Dropbox\My Documents\DUCX\Newton Rigg OS with Digital Registers.ducx</Name>
  </FilePath>
  <XTP>
    <SystemAddress>0</SystemAddress>
    <StationAddress>10</StationAddress>
    <SuppressDualCommsAlarms>No</SuppressDualCommsAlarms>
    <PowerSave>No</PowerSave>
  </XTP>
  <COMport>
    <COM id="1">
      <BaudRate>9600</BaudRate>
      <BitsPerChar>8</BitsPerChar>
      <Parity>None</Parity>
      <StopBits>1</StopBits>
      <RS485>RS232</RS485>
      <RTS_CTSflowControl>No</RTS_CTSflowControl>
      <CTSdelay>20</CTSdelay>
      <TransmissionDelay>0</TransmissionDelay>
    </COM>
    <COM id="2">
      <BaudRate>9600</BaudRate>
      <BitsPerChar>8</BitsPerChar>
      <Parity>None</Parity>
      <StopBits>1</StopBits>
      <RS485>RS232</RS485>
      <RTS_CTSflowControl>No</RTS_CTSflowControl>
      <CTSdelay>20</CTSdelay>
      <TransmissionDelay>0</TransmissionDelay>
    </COM>
    <COM id="3">
      <BaudRate>9600</BaudRate>
      <BitsPerChar>8</BitsPerChar>
      <Parity>None</Parity>
      <StopBits>1</StopBits>
      <RS485>RS232</RS485>
      <RTS_CTSflowControl>No</RTS_CTSflowControl>
      <CTSdelay>20</CTSdelay>
      <TransmissionDelay>0</TransmissionDelay>
    </COM>
  </COMport>
  <COMinterface>
    <Interface id="1">
      <InterfaceType>458MHz Radio, RC1760 (7501-1)</InterfaceType>
      <RadioChannel>4</RadioChannel>
      <AerialGain>0</AerialGain>
      <CableLength>10</CableLength>
      <CableType>RG213</CableType>
      <APN />
      <UserName />
      <Password />
    </Interface>
    <Interface id="2">
      <InterfaceType>458MHz Radio, RC1760 (7501-1)</InterfaceType>
      <RadioChannel>31</RadioChannel>
      <AerialGain>6</AerialGain>
      <CableLength>10</CableLength>
      <CableType>RG213</CableType>
      <APN />
      <UserName />
      <Password />
    </Interface>
  </COMinterface>
  <Fieldbus>
    <MasterPort>COM3</MasterPort>
    <FieldbusMasterProtocol>MODBUS</FieldbusMasterProtocol>
    <ScanRate>1</ScanRate>
    <Retries>2</Retries>
    <RXtimeout>200</RXtimeout>
    <SlaveAddress>0</SlaveAddress>
  </Fieldbus>
  <DataRouting>
    <Line id="1">
      <SourcePointNo>1</SourcePointNo>
      <SourceAddress>1</SourceAddress>
      <SourceType>Fieldbus Input Register</SourceType>
      <DestPointNo>3</DestPointNo>
      <DestAddress>10</DestAddress>
      <DestType>Analogue Input</DestType>
      <Quantity>2</Quantity>
      <Description>Note: All Fieldbus registers offset by 1, so these are defined in PLC as 2 - 3</Description>
    </Line>
    <Line id="2">
      <SourcePointNo>512</SourcePointNo>
      <SourceAddress>1</SourceAddress>
      <SourceType>Fieldbus Input Register</SourceType>
      <DestPointNo>5</DestPointNo>
      <DestAddress>10</DestAddress>
      <DestType>Analogue Input</DestType>
      <Quantity>6</Quantity>
    </Line>
    <Line id="3">
      <SourcePointNo>3</SourcePointNo>
      <SourceAddress>10</SourceAddress>
      <SourceType>Analogue Output</SourceType>
      <DestPointNo>2</DestPointNo>
      <DestAddress>1</DestAddress>
      <DestType>Fieldbus Output Register</DestType>
      <Quantity>1</Quantity>
    </Line>
    <Line id="4">
      <SourcePointNo>4</SourcePointNo>
      <SourceAddress>10</SourceAddress>
      <SourceType>Analogue Output</SourceType>
      <DestPointNo>512</DestPointNo>
      <DestAddress>1</DestAddress>
      <DestType>Fieldbus Output Register</DestType>
      <Quantity>7</Quantity>
    </Line>
    <Line id="5">
      <SourcePointNo>0</SourcePointNo>
      <SourceAddress>10</SourceAddress>
      <SourceType>Digital State on Comms Fail</SourceType>
      <DestPointNo>8</DestPointNo>
      <DestAddress>10</DestAddress>
      <DestType>Digital Output</DestType>
      <Quantity>1</Quantity>
    </Line>
    <Line id="6">
      <SourcePointNo>1</SourcePointNo>
      <SourceAddress>10</SourceAddress>
      <SourceType>Digital Input Register</SourceType>
      <DestPointNo>519</DestPointNo>
      <DestAddress>1</DestAddress>
      <DestType>Fieldbus Output Register</DestType>
      <Quantity>1</Quantity>
    </Line>
    <Line id="7">
      <SourcePointNo>1</SourcePointNo>
      <SourceAddress>10</SourceAddress>
      <SourceType>Digital Output Register</SourceType>
      <DestPointNo>520</DestPointNo>
      <DestAddress>1</DestAddress>
      <DestType>Fieldbus Output Register</DestType>
      <Quantity>1</Quantity>
    </Line>
  </DataRouting>
  <CommsRouting />
  <IPaddressTable />
  <SMSnumberTable />
</Configuration>

Return to Thunderbird Support


Who is online

Users browsing this forum: Google [Bot] and 4 guests