क्या आप एक Android डेवलपर हैं जो अपने एप्लिकेशन में दस्तावेज़ रूपांतरण सुविधा जोड़ना चाहते हैं? Aspose.Total for Android via Java फाइल फॉर्मेट ऑटोमेशन लाइब्रेरी आपके एंड्रॉइड एप्लिकेशन में दस्तावेज़ रूपांतरण प्रक्रिया को स्वचालित करने में आपकी सहायता कर सकती है। DOCM फ़ाइल को PPTM में बदलने के लिए, आप DOCM फ़ाइल स्वरूप को HTML में बदलने के लिए पहले दस्तावेज़ हेरफेर API Aspose.Words for Android via Java का उपयोग कर सकते हैं। उसके बाद PowerPoint API Aspose.Slides for Android Java का उपयोग करके, आप एक नया प्रेजेंटेशन बना सकते हैं, उसमें HTML सामग्री लिख सकते हैं, और इसे इस रूप में सहेज सकते हैं ओडीपी।
Android में DOCM को PPTM में कैसे बदलें
रूपांतरण आवश्यकताएँ
DOCM से PPTM फ़ाइल रूपांतरण के लिए, आप आसानी से Maven और अपने ऐप में लाइब्रेरी इंस्टॉल करें।
वैकल्पिक रूप से, आप डाउनलोड से एक ज़िप फ़ाइल प्राप्त कर सकते हैं।
// supports DOC, DOCX, DOT, DOTM, DOTX, FLATOPC, ODT, OTT, RTF, TXT, WORDML, DOCM input file formats | |
// load DOC file with an instance of Document | |
Document document = new Document("template.doc"); | |
// save the document in HTML file format | |
document.save("HtmlOutput.html",SaveFormat.HTML); | |
// create a new presentation | |
Presentation pres = new Presentation(); | |
// access the default first slide of presentation | |
ISlide slide = pres.getSlides().get_Item(0); | |
// add the AutoShape to accommodate the HTML content | |
IAutoShape ashape = slide.getShapes().addAutoShape(ShapeType.Rectangle, 10, 10, | |
(float) pres.getSlideSize().getSize().getWidth(), | |
(float) pres.getSlideSize().getSize().getHeight()); | |
ashape.getFillFormat().setFillType(FillType.NoFill); | |
// add text frame to the shape | |
ashape.addTextFrame(""); | |
// clear all paragraphs in added text frame | |
ashape.getTextFrame().getParagraphs().clear(); | |
// initialize StringBuilder to read Html | |
StringBuilder contents = new StringBuilder(); | |
// load HTML file by using BufferedReader | |
BufferedReader reader = new BufferedReader(new FileReader(new File("HtmlOutput.html"))); | |
String text = null; | |
// repeat until all lines are read | |
while ((text = reader.readLine()) != null) { | |
contents.append(text).append(System.getProperty("line.separator")); | |
} | |
reader.close(); | |
// add HTML content in text frame | |
ashape.getTextFrame().getParagraphs().addFromHtml(content); | |
// supports POTM, POT, POTX, PPSM, PPS, PPSX, PPTM, PPT, PPTX, ODP output file formats. | |
// save presentation as Pptx | |
pres.save("output.pptx", com.aspose.slides.SaveFormat.Pptx); |
बीएमपी से जीआईएफ के लिए मुफ्त ऑनलाइन कन्वर्टर
जावा के माध्यम से Android में संरक्षित DOCM को PPTM में बदलें
आप अपने Android एप्लिकेशन में अपने पासवर्ड से सुरक्षित DOCM को PPTM में भी बदल सकते हैं। यदि आपका इनपुट डीओसी दस्तावेज़ पासवर्ड से सुरक्षित है, तो आप पासवर्ड का उपयोग किए बिना इसे ओडीपी प्रारूप में परिवर्तित नहीं कर सकते। एन्क्रिप्टेड दस्तावेज़ खोलने के लिए, आप LoadOptions ऑब्जेक्ट में सही पासवर्ड सेट कर सकते हैं और इसे दस्तावेज़ निर्माता को पास कर सकते हैं।
// supports DOC, DOCX, DOT, DOTM, DOTX, FLATOPC, ODT, OTT, RTF, TXT, WORDML, DOCM input file formats | |
// load DOC file with an instance of Document | |
Document document = new Document("template.doc"); | |
// save the document in HTML file format | |
document.save("HtmlOutput.html",SaveFormat.HTML); | |
// create a new presentation | |
Presentation pres = new Presentation(); | |
// access the default first slide of presentation | |
ISlide slide = pres.getSlides().get_Item(0); | |
// add the AutoShape to accommodate the HTML content | |
IAutoShape ashape = slide.getShapes().addAutoShape(ShapeType.Rectangle, 10, 10, | |
(float) pres.getSlideSize().getSize().getWidth(), | |
(float) pres.getSlideSize().getSize().getHeight()); | |
ashape.getFillFormat().setFillType(FillType.NoFill); | |
// add text frame to the shape | |
ashape.addTextFrame(""); | |
// clear all paragraphs in added text frame | |
ashape.getTextFrame().getParagraphs().clear(); | |
// initialize StringBuilder to read Html | |
StringBuilder contents = new StringBuilder(); | |
// load HTML file by using BufferedReader | |
BufferedReader reader = new BufferedReader(new FileReader(new File("HtmlOutput.html"))); | |
String text = null; | |
// repeat until all lines are read | |
while ((text = reader.readLine()) != null) { | |
contents.append(text).append(System.getProperty("line.separator")); | |
} | |
reader.close(); | |
// add HTML content in text frame | |
ashape.getTextFrame().getParagraphs().addFromHtml(content); | |
// add watermark | |
IAutoShape ashp = slide.getShapes() | |
.addAutoShape(ShapeType.Rectangle,50, 50, 500, 500); | |
ashp.addTextFrame("Watermark Text"); | |
ashp.getTextFrame().getParagraphs().get_Item(0).getPortions() | |
.get_Item(0).getPortionFormat().getFillFormat() | |
.setFillType(FillType.Solid); | |
ashp.getTextFrame().getParagraphs().get_Item(0).getPortions() | |
.get_Item(0).getPortionFormat().getFillFormat() | |
.getSolidFillColor().setColor(Color.GRAY); | |
ashp.getTextFrame().getParagraphs().get_Item(0).getPortions() | |
.get_Item(0).getPortionFormat().setFontHeight(25); | |
// Change the line color of the rectangle to White | |
ashp.getShapeStyle().getLineColor().setColor(Color.WHITE); | |
ashp.getShapeStyle().setLineStyleIndex(LineStyle.ThinThin); | |
// Remove any fill formatting in the shape | |
ashp.getFillFormat().setFillType(FillType.NoFill); | |
ashp.setRotation(-45); | |
ashp.getAutoShapeLock().setSelectLocked(true); | |
ashp.getAutoShapeLock().setSizeLocked(true); | |
ashp.getAutoShapeLock().setTextLocked(true); | |
ashp.getAutoShapeLock().setPositionLocked(true); | |
ashp.getAutoShapeLock().setGroupingLocked(true); | |
// supports POTM, POT, POTX, PPSM, PPS, PPSX, PPTM, PPT, PPTX, ODP output file formats. | |
// save presentation as Pptx | |
pres.save("output.pptx", com.aspose.slides.SaveFormat.Pptx); |
अक्सर पूछे जाने वाले प्रश्नों
- मैं बीएमपी को जीआईएफ में ऑनलाइन कैसे बदल सकता हूं?बीएमपी रूपांतरण ऑनलाइन ऐप आपकी सुविधा के लिए ऊपर एकीकृत है। बीएमपी फ़ाइल को जीआईएफ में बदलने के लिए, बस अपनी बीएमपी फ़ाइल को खींचकर सफेद क्षेत्र में छोड़ दें या इसे आयात करने के लिए क्षेत्र के अंदर क्लिक करें। उसके बाद, "कन्वर्ट" बटन पर क्लिक करें। एक बार बीएमपी से जीआईएफ रूपांतरण पूरा हो जाने पर, आप अपनी परिवर्तित फ़ाइल को केवल एक क्लिक से डाउनलोड कर सकते हैं।
- बीएमपी को बदलने में कितना समय लगता है?इस ऑनलाइन कन्वर्टर की गति काफी हद तक उस बीएमपी फ़ाइल के आकार पर निर्भर करती है जिसे आप कनवर्ट करना चाहते हैं। छोटी बीएमपी फाइलों को कुछ ही सेकंड में जीआईएफ में बदला जा सकता है। हालाँकि, यदि आपने रूपांतरण कोड को अपने Android App एप्लिकेशन में एकीकृत किया है, तो गति इस बात पर निर्भर करेगी कि आपने रूपांतरण प्रक्रिया के लिए अपने एप्लिकेशन को कितनी अच्छी तरह अनुकूलित किया है।
- क्या मुक्त Aspose.Total कन्वर्टर का उपयोग करके DOCM को PPTM में बदलना सुरक्षित है?बिल्कुल! रूपांतरण के बाद, आपकी PPTM फ़ाइल का डाउनलोड लिंक तुरंत उपलब्ध हो जाएगा। अपलोड की गई फ़ाइलें 24 घंटों के बाद स्वतः हटा दी जाती हैं, और इस समय के बाद डाउनलोड लिंक अमान्य हो जाते हैं। निश्चिंत रहें कि आपकी फाइलें सुरक्षित हैं, क्योंकि कोई और उन्हें एक्सेस नहीं कर सकता है। हमारी फाइल रूपांतरण सेवा, जिसमें बीएमपी फाइलें शामिल हैं, पूरी तरह से सुरक्षित है। इसके अतिरिक्त, परीक्षण उद्देश्यों के लिए एक मुफ्त ऐप प्रदान किया जाता है, जिससे आप कोड को एकीकृत करने से पहले परिणामों की पुष्टि कर सकते हैं।
- बीएमपी कन्वर्ट करने के लिए मुझे किस ब्राउजर का इस्तेमाल करना चाहिए?गूगल क्रोम, फायरफॉक्स, ओपेरा और सफारी जैसे आधुनिक वेब ब्राउज़र इस ऑनलाइन रूपांतरण उपकरण के साथ संगत हैं। हालाँकि, यदि आप डेस्कटॉप एप्लिकेशन पर काम कर रहे हैं, तो सुचारू संचालन के लिए Aspose.Total DOCM रूपांतरण API की अनुशंसा की जाती है।