klm 0 Posted July 5, 2012 Report Share Posted July 5, 2012 Hi Guys, Does anyone know if it's possible to use some sort of scrpit in ubot to do conversion from text files to pdf files? I want to see if ubot can do this "internally" somehow, without using online conversion tools? Thanks All! Quote Link to post Share on other sites
Kreatus (Ubot Ninja) 422 Posted July 5, 2012 Report Share Posted July 5, 2012 I think its not possible if not using third party app. Quote Link to post Share on other sites
Legend 181 Posted July 5, 2012 Report Share Posted July 5, 2012 I don't think so either... Quote Link to post Share on other sites
klm 0 Posted July 5, 2012 Author Report Share Posted July 5, 2012 Really- not even using some sort of javascript in the 'run javascript' command? I'll just have to use an online converter for now then I guess. The only problem with that is it's going to be slow when running multiple file conversions. Quote Link to post Share on other sites
JohnB 255 Posted July 5, 2012 Report Share Posted July 5, 2012 It's definitely possible, it's just a matter of what you are doing and how you are doing it...here's a helpful article on the subject: http://blog.advanced...a-command-line/ http://www.robvanderwoude.com/printfiles.php John Quote Link to post Share on other sites
ubotusold 28 Posted July 6, 2012 Report Share Posted July 6, 2012 Ubot can't convert text to PDF internally. You have to step outside the Ubot environment to do so. Unless you are doing anything browser related, Ubot is not the right tool for the job. Perhaps its best to take a different, easier approach? Try this: 1) Download AutoHotKey, a Windows macro key/mouse recorder. Its open source, and free. 2) Download Nitro PDF Creator. It creates and reads PDF files. Its also free. Both these programs are heavily used and popular. Find them on Cnet download.com. 3) Use Ubot for whatever browser related requirements. If that means scraping text off a website or loading a file locally (file://myfile.txt), then do that and save the resulting text file on disk. 4) Run the AutoScript recorder. Go through all the mouse and keyboard actions necessary to load the text file, do whatever, and navigate to File | Print. Select the Nitro PDF Creator print emulator and then press the create button. Turn off recording. 5) Convert the AHK script to EXE using the supplied utility6) Run it. Is this what you are trying to accomplish? Quote Link to post Share on other sites
klm 0 Posted July 6, 2012 Author Report Share Posted July 6, 2012 Thanks John. I had come across a few pages explaining how to do this but having read through these also, it still seems a little over my head. Ubotusold yes this is what I'm trying to accomplish basically. Something along the lines you suggest may be the best solution I think...at least for a bot only used internally & not being distributed. I think keeping it simple is the best path especially if I'm not sure how to work with the more complicated approaches. I'll be looking into AutoHotKey to see more about that as too as it sounds useful. I've started using another program called 'Convert Doc' by SoftInterface ( http://www.softinterface.com/Convert-Doc/Convert-Doc.htm ) which has the ability to be run from the command line also. That program seems great for all kinds of file conversions, only downside is it's cost...but it does batch conversion of files flawlessly using the trial version. Thanks for all your input guys! Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.