How i can create a .ppt file from as3? i need to add one image to powerpoint and save the .ppt file on a button click. Is there any as3 library available for saving files as ppt?
Any help would be immensely appreciated.
Thanks in advance..
I write VBA code in Microsoft Office PowerPoint for you. You can achieve to your goal with this code.
You must create a text file with name "Info.txt" in following order when you want to create a PowerPoint presentation (path of the text file must be in where you have placed my attached "InsertPicture-Office 2007.pptm" and "InsertPicture-Office 2010 & 2013.pptm" files):
Line 1. Distance of the image from Left of the slide
Line 2. Distance of the image from Top of the slide
Line 3. Image Width in the slide
Line 4. Image Height in the slide
Line 5. Full path and name (with extension [.pptx]) for saving PowerPoint presentation file
Line 6. Full path and name (with extension) of an image for inserting in the slide of the PowerPoint presentation
After save the text file, you only must run the "InsertPicture-Office 2007.pptm" or "InsertPicture-Office 2010 & 2013.pptm" file and everything will be done.
Remember that you must "Enable all macros" for Microsoft Office PowerPoint from following way:
Open Microsoft Office Powerpoint -> File -> Options -> Trust Center -> Trust Center Settings -> Macro Settings -> Enable all macros ...
4Shared -> InsertPicture-Office 2007.pptm, InsertPicture-Office 2010 & 2013.pptm and Info.txt files
SendSpace -> InsertPicture-Office 2007.pptm, InsertPicture-Office 2010 & 2013.pptm and Info.txt files
You can test it only with change "Info.txt" file in order of what I'm mentioned above, and opening one of the "InsertPicture-Office 2007.pptm" or "InsertPicture-Office 2010 & 2013.pptm" files according to installed version of the Microsoft Office PowerPoint in your system.
Related
Is it possible to show a file directory using function/code? I find myself clicking through file structures to view a directory. I'd like to use some like this:
my_search_finding <- grep('search-pattern', list.files('~/some/long/directory/tree'))
new_function_to_view_files(my_search_finding)
Then the directory is opened in that viewer display and I can explore using the mouse.
Thanks
Under Windows, you can use choose.files:
path <- '~/some/long/directory/tree'
selected.files <- choose.files(default=paste0(path, "/*.*"))
the default argument allows you to display files in a particular directory with a fully qualified file mask, see documentation.
I have a .xlsx file with an image on header. When i try to convert to PDF via terminal using libreoffice it converts but the image doesn't appear on the generated PDF.
Here is a screenshot of the main .xlsx file on Excel (print mode):
And the Screenshot of the generated PDF:
The command that im using is: soffice --headless --convert-to pdf --outdir /home/output /home/input/headers_footers.xlsx
Note: To display the header image of the .xlsx on excel we need to put it into print view mode (ctrl+p)
I tested the conversion of the headers_footers.xlsx with an online convertion tool to PDF and the final result was as expected: the image appeared.
But i need to do this programatically, so im not sure if its libreoffice or if i need to use other tool, or maybe manipulate the final PDF and add an image on it?
This is not only an UNIX problem. I can reproduce the malfunction running MS Windows 10. The header image appears in print view and in manually exported PDF. But when you call
soffice --headless --convert-to pdf --outdir . sample.xlsx
on command line it won't show up. I will keep on searching for an answer but this seems to be a bug to me.
Is using a LO Basic Macro an acceptable approach for you, too?
Sub ExportCalcToPDF
sURL = convertToURL("d:\temp\lo_calc.pdf")
dim mFileType(0)
mFileType(0) = createUnoStruct("com.sun.star.beans.PropertyValue")
mFileType(0).Name = "FilterName"
mFileType(0).Value = "calc_pdf_Export"
thisComponent.storeToURL(sURL, mFileType())
End Sub
When executed this macro exports the spreadsheet to pdf. To run the macro automatically e.g. on file open assign it to "Open Document" in Tools > Customize > Events.
Doing a test by double clicking the xlsx file the image appears in the header of the pdf. However, no success from command line so far.
I'm trying to get from a GraphViz graph to a graph in Powerpoint. But, when it's inside of Powerpoint I would like to be able to edit the individual nodes, edges, boundaries. This means exporting the GraphViz as an image file won't work.
Does anyone know any path to get from GraphViz to Powerpoint?
If you know the XML structure of a .PPTX file, you could export your GraphViz graph as an SVG -- which is in reality a text format -- then parse it and emit the XML needed to create the .PPTX file. A difficult method though, I know.
Like all of the Microsoft "open document" formats, the .PPTX is really just a ZIP file that contains many elements, the XML describing the graph being one of them.
You can generate .emf (Enhanced Metafile) images from .dot files using GraphViz on Windows. You can import the .emf file into your PowerPoint presentation and then ungroup it (several times) to break it down into the individual shapes.
This is good, but unfortunately the edges of your graph do not get turned into connectors. Instead, they are pictures of lines, so they don't reroute when you move any of the nodes of your graph around.
You can achieve this by using LibreOffice. I've tested the process with LibreOffice 7.0.4.2.
Export your graph as SVG in Graphviz (-Tsvg).
Create a presentation in LibreOffice: File → New → Presentation
Delete the elements in the slide (title & body boxes).
Import the SVG file: Insert → Image
Once the image is inserted, select it by left-clicking on it.
Open the context menu by right-clicking on the image and choose Break.
Save the presentation as .pptx: File → Save As... → Choose the file type .pptx in the dialog.
Open the .pptx in PowerPoint.
Select all the image components and copy them to your actual presentation.
Edit the image.
(Of course, you can do 9. and 10. in reverse order.)
Is there a way to display past commands in R/R Studio?? I know in R Studio there is a shortcut (CTRL+UP Arrow) that allows you to see past lines you have ran. But this shortcut only allows you to access only a single line, not a block of previously run code. Is there a package, or some way in R to display and select blocks of past code in R/R Studio?
Here you can find a description of the panes in R Studio, including the "history" pane.
There you can select several lines and paste them into the code.
Also, you can use the command savehistory() to save your history in a file you can the modify. If you want to choose the name of the file to be saved, use
savehistory(file = filename)
The same option is available in the basic R GUI (MS Windows), with "Save history" in the "File" menu (as a .RHistory file). Then, you can open it with any text editor and modify your history to make a script.
To see a specific number of lines, you can use history(25) (for 25 previous lines).
I am building a web application that requires a number of dynamically generated RTF files to be generated, these files are currently .RTF files but I need to build them all within my application in RTF format, does anyone know a program or something that I can open them in and view the raw RTF code that creates the file eg.
{\rtf\ansi\deff0{\fonttbl{\f0\froman Tms Rmn;}{\f1\fdecor
Symbol;}{\f2\fswiss Helv;}}{\colortbl;\red0\green0\blue0;
\red0\green0\blue255;\red0\green255\blue255;\red0\green255\
blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\
green255\blue0;\red255\green255\blue255;}{\stylesheet{\fs20
\snext0Normal;}}{\info{\author John Doe}
{\creatim\yr1990\mo7\dy30\hr10\min48}{\version1}{\edmins0}
{\nofpages1}{\nofwords0}{\nofchars0}{\vern8351}}\widoctrl\ftnbj \sectd\linex0\endnhere \pard\plain \fs20 This is plain text.\par}
Thanks for any help.
J.
Notepad, or any text editor will do. As you are creating the files yourself programatically, you will want to be liberal with carriage returns and line feeds to make the files more readable.