file-conversion

How can I use PowerShell to `save as…` a different file extension?

扶醉桌前 提交于 2019-12-04 02:15:45
问题 This question was migrated from Super User because it can be answered on Stack Overflow. Migrated 7 years ago . I'm using the following powershell script to open a few thousand HTML files and "save as..." Word documents. param([string]$htmpath,[string]$docpath = $docpath) $srcfiles = Get-ChildItem $htmPath -filter "*.htm*" $saveFormat = [Enum]::Parse([Microsoft.Office.Interop.Word.WdSaveFormat], "wdFormatDocument"); $word = new-object -comobject word.application $word.Visible = $False

How to convert any format(.txt, .Doc) file into epub file in android application

老子叫甜甜 提交于 2019-12-03 21:47:30
I am developing an application in which I have to read or write any eBook. In android so many libraries available for reading any eBook, but for writing i didn't find any thing. For reading any eBook file must be in .epub format. I have an editor in which i am entering some text and after saving that file in any format how can i convert that file into .epub file. Thanks in advance. In android Java is developer language for create APP, use Epublib (lib in java) Read "doc file" with poi Create epub file: package nl.siegmann.epublib.examples; import java.io.InputStream; import java.io

How to convert .docx to .pdf in C# [closed]

天涯浪子 提交于 2019-12-03 06:57:56
Now we are using OpenXML to read data from database and generate doc. But the final requirement is to be a pdf. So I want to know how to convert .docx to pdf in C#. Could anyone for help? Or provide some information. You can check solutions in this link: http://www.codeproject.com/Questions/346784/How-to-convert-word-document-to-pdf-in-Csharp I recommend using this among solutions as first: using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using Microsoft.Office.Interop.Word; public partial class Default2

Converting correctly pdf to ps and vice-versa

此生再无相见时 提交于 2019-12-03 03:51:36
I'm using "pdftops" to convert .pdf files to .ps files and then "ps2pdf" for the reverse process (poppler-utils). The problem is that when creating the .pdf files from the .ps files, the text looks ok, but when i try to copy it, the characters are very strange (it's like they are corrupted). I used these tools on other files for a long time and it worked fine. I also tried "pdftohtml -xml" to create an .xml file, and the text is ok (the characters are extracted correctly). What problem could it be regarding the conversion? Maybe if I use "pdftops" and "ps2pdf" are there some options that need

Replacing vector images in a PDF with raster images

守給你的承諾、 提交于 2019-12-03 03:10:18
问题 Is there any easy (scriptable) way to convert a PDF with vector images into a PDF with raster images? In other words, I want to generate a PDF with the exact same (un-rasterized) text but with each vector image replaced with a rasterized version. I occasionally read PDFs of technical articles on my Kindle, and have found that reading a PDF directly is frustrating. Thankfully, Amazon's automatic conversion of PDFs to the Kindle format does a good job of reflowing the text portions of most of

Convert .odt .doc .ods files to .txt files

自闭症网瘾萝莉.ら 提交于 2019-12-03 02:01:22
I want to convert all the .odt .doc .xls .pdf files to .txt files. I want to convert these files to text files using a shell script or a perl script There's a program for odt files and alikes: odt2txt - avaliable in repos. $ unoconv --format=txt document1.odt Should produce document1.txt. OpenOffice has a built-in document converter capable of handling a bunch of formats- take a look at unoconv: http://dag.wieers.com/home-made/unoconv/ That being said, I have had some troubles getting that to work in the past- If you're having trouble, take a look at similar programs for AbiWord (another open

How can I quickly and easily convert spreadsheet data to JSON? [closed]

谁说胖子不能爱 提交于 2019-12-03 01:02:54
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 6 years ago . I want to convert spreadsheet data (such as from Excel/*.xls files or Open Office, etc.) to JSON files. What is the easiest way to accomplish this? 回答1: Assuming you really mean "easiest" and are not necessarily looking for a way to do this programmatically, you can do this: 0)

Quickly Convert (.rtf|.doc) Files to Markdown Syntax with PHP

試著忘記壹切 提交于 2019-12-03 00:06:50
问题 I've been manually converting articles into Markdown syntax for a few days now, and it's getting rather tedious. Some of these are 3 or 4 pages, italics and other emphasized text throughout. Is there a faster way to convert (.rtf|.doc) files to clean Markdown Syntax that I can take advantage of? 回答1: If you happen to be on a mac, textutil does a good job of converting doc, docx, and rtf to html, and pandoc does a good job of converting the resulting html to markdown: $ textutil -convert html

How to transfer Nifti file into .mat Matlab file?

时光毁灭记忆、已成空白 提交于 2019-12-02 20:10:20
问题 I have a Nifti file, the size of which is 62*62*38. How can I transfer the Nifti file to .mat Matlab file? 回答1: This can read NIFTI as well as many other medical image file types into MATLAB arrays, which you can then save as .mat files. 回答2: Most medical imaging data can be manipulated effectively using some kind of toolbox, such as SPM. However, if you need to gain access to the raw matrix I've always used NIfTI tools from the Mathworks file exchange site (here). There are two functions

Replacing vector images in a PDF with raster images

旧巷老猫 提交于 2019-12-02 16:40:24
Is there any easy (scriptable) way to convert a PDF with vector images into a PDF with raster images? In other words, I want to generate a PDF with the exact same (un-rasterized) text but with each vector image replaced with a rasterized version. I occasionally read PDFs of technical articles on my Kindle, and have found that reading a PDF directly is frustrating. Thankfully, Amazon's automatic conversion of PDFs to the Kindle format does a good job of reflowing the text portions of most of PDFs I have tried. However, while raster images seem to make it through the conversion process fine,