Date: prev next · Thread: first prev next last
2013 Archives by date, by thread · List index


Hi,

system("xdg-open abc.pdf"); is not good enough - this won't work on OSX or
Windows.

You have to use XSystemShellExecute:
Reference<XSystemShellExecute>
xSystemShellExecute(SystemShellExecute::create(
::comphelper::getProcessComponentContext() ) );
xSystemShellExecute->execute( aFileName, OUString(),
SystemShellExecuteFlags::URIS_ONLY );

see svx/source/core/extedit.cxx method ExternalToolEdit::threadWorker as an
example where it is used.

As for path and filename in PDFExport::Export you get "rFile" as parameter
- this is the location where the file will be written to.

Regards, Tomaž




On Sat, Apr 27, 2013 at 1:34 AM, Anurag Kanungo <anuragkanungo@gmail.com>wrote:


Hi,

In bug

https://bugs.freedesktop.org/show_bug.cgi?id=37222

I was trying to resolve the bug , and got a little progress that whenever
a user
exports the pdf , i am able to open a particular fixed pdf file .

In file filter/source/pdf/pdfexport.cxx,

i used there system("xdg-open abc.pdf");       //xdg-open because it can
work with any desktop environment (i guess)

so it will always open abc.pdf file .



I am not able to open the newly saved pdf file , as i require the location
and the name of the new pdf to open it ,
and i also require to convert string to const char* , as string.c_str();
doesn't worked there .

Thank You .



_______________________________________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice



Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.