white8889 Posted September 8, 2010 Share Posted September 8, 2010 Hi taietel I like this great script. One question is how to try using other fonts that not installed in the script. For example,if I copy a chinese font file (such as simkai.afm) to the %Temp%\Fonts,how to use this font in the script? Link to comment Share on other sites More sharing options...
taietel Posted September 8, 2010 Author Share Posted September 8, 2010 Hi white8889I'm afraid you can not, because I don't know/use/speak/write chinese (I'm to old for that but not too old to play with AutoIt) and this version of activex was initial for my own projects, then I have decided to share. The fonts are read from within dll. M.I. Things you should know first...In the beginning there was only ONE! And zero... Progs: Create PDF(TXT2PDF,IMG2PDF) 3D Bar Graph DeskGadget Menu INI Photo Mosaic 3D Text Link to comment Share on other sites More sharing options...
StefanoS Posted December 6, 2010 Share Posted December 6, 2010 Hi all I have a problem with this script, may you help me? pdfAutoit.au3 (552) : ==> The requested action with this object has failed.: .TextOut($sText, $iX, $iY) .TextOut($sText, $iX, $iY)^ ERROR Thanks a lot Link to comment Share on other sites More sharing options...
taietel Posted December 8, 2010 Author Share Posted December 8, 2010 (edited) Stefano, as you read in one of my previous posts, the problem was when setting style to certain fonts. Of course I can/will help you! Here is the modified dll. I have tested it with all the fonts/styles available in this version; in the zip file there is a sample pdf resulted from this (see pages 3 and 4). Sorry for the delay, but I'm a little busy for the moment and tired also. M.I. [Edit] *typo [Edit] Attachment moved to first post Edited August 10, 2011 by taietel Things you should know first...In the beginning there was only ONE! And zero... Progs: Create PDF(TXT2PDF,IMG2PDF) 3D Bar Graph DeskGadget Menu INI Photo Mosaic 3D Text Link to comment Share on other sites More sharing options...
dmob Posted May 13, 2011 Share Posted May 13, 2011 Any progress on this great piece of work? Also, where can I find more info about your dll? I have created a sort of UDF for personal use, but I still need more info about the functionality of this script, especially table creation / formatting. Link to comment Share on other sites More sharing options...
engjcowi Posted May 19, 2011 Share Posted May 19, 2011 Hi Im on windows 7 X64 and everytime i try to use this it keeps saying that it cannot register the dll. Ive tried going to the temp dir and deleting the fonts and the dll and trying again but no joy jamie Drunken Frat-Boy Monkey Garbage Link to comment Share on other sites More sharing options...
dmob Posted May 20, 2011 Share Posted May 20, 2011 (edited) Tried to register it as admin? Edited May 20, 2011 by dmob Link to comment Share on other sites More sharing options...
engjcowi Posted May 22, 2011 Share Posted May 22, 2011 Tried to register it as admin?yeah. even compiled and then ran as admin Drunken Frat-Boy Monkey Garbage Link to comment Share on other sites More sharing options...
taietel Posted May 24, 2011 Author Share Posted May 24, 2011 engjcowi, have you compiled your script for x32 or x64 architecture? Try to compile for x32. The activex was intended for x32, since I use only that. #AutoIt3Wrapper_UseX64=n dmob, the info about the dll is not available for the moment. I've updated the ActiveX for not using the external fonts and I will post it as soon as possible (still needs some testing). Regards, taietel Things you should know first...In the beginning there was only ONE! And zero... Progs: Create PDF(TXT2PDF,IMG2PDF) 3D Bar Graph DeskGadget Menu INI Photo Mosaic 3D Text Link to comment Share on other sites More sharing options...
dmob Posted May 24, 2011 Share Posted May 24, 2011 I use your dll on a daily basis on two separate apps.... I'd be happy to do some testing, if you wish. Link to comment Share on other sites More sharing options...
FriendsFade Posted May 24, 2011 Share Posted May 24, 2011 Hey can you please post the code for creating the binary for resource files Link to comment Share on other sites More sharing options...
taietel Posted May 24, 2011 Author Share Posted May 24, 2011 (edited) FriendsFade, expandcollapse popup#NoTrayIcon #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> $Gui = GUICreate("Convert2au3", 200, 94, @DesktopWidth - 220, @DesktopHeight - 130, BitOR($WS_POPUP,$WS_BORDER), BitOR($WS_EX_ACCEPTFILES,$WS_EX_TOOLWINDOW)) GUISetBkColor(0x000000) WinSetOnTop($Gui,"",1) $Input1 = GUICtrlCreateLabel('', 0, 0, 200, 94) GUICtrlSetState(-1, 136) GUICtrlCreateLabel ("Drag your file here...", 10,10,180,17,$SS_CENTER, $GUI_WS_EX_PARENTDRAG) GUICtrlSetColor(-1, 0xFFCC00) $StatusBar=GUICtrlCreateLabel (@CRLF&@CRLF&'', 10,30,180,57,$SS_CENTER, $GUI_WS_EX_PARENTDRAG) GUICtrlSetColor(-1, 0xFFFF00) WinSetTrans($Gui,"",220) GUISetState () While 1 $msg = GUIGetMsg() Select Case $msg = -13 $filename=StringRegExp(@GUI_DRAGFILE,'(^.*)\\(.*)\.(.*)',3) GUICtrlSetData($StatusBar, 'Reading file '&$filename[1]&'.'&$filename[2]&' ...') ConsoleWrite($filename[0]&@CRLF) $ScrBin='Local $sData=''0x'''&@CRLF $file = FileOpen(@GUI_DRAGFILE, 16) While 1 $Bin = FileRead($file, 512) If @error = -1 Then ExitLoop $ScrBin&='$sData&='''&StringTrimLeft($Bin,2)&''''&@CRLF Sleep(1) WEnd FileClose($file) GUICtrlSetData($StatusBar, 'Transforming file '&$filename[1]&'.'&$filename[2]&' ...') Sleep(1000) $Output = $filename[0] & '\Inc_' $i = 1 While FileExists($Output & $i & '_'&$filename[1]&'.au3') $i += 1 WEnd $Output = $Output & $i & '_'&$filename[1]&'.au3' $file = FileOpen($Output,2) FileWrite($file, 'Func _IncludeFile($sPath="")'&@CRLF&$ScrBin&@CRLF& _ 'If $sPath="" Then $sPath=@TempDir'&@CRLF&'$sData=Binary($sData)'&@CRLF& _ @TAB&'$f=$sPath&"\'&$filename[1]&'.'&$filename[2]&'"'&@CRLF& _ @TAB&'If Not FileExists($sPath&"\'&$filename[1]&'.'&$filename[2]&'") Then'&@CRLF& _ @TAB&@TAB&'$file=FileOpen($f,18)'&@CRLF& _ @TAB&@TAB&'FileWrite($file,$sData)'&@CRLF& _ @TAB&@TAB&'FileClose($file)'&@CRLF&@TAB&'EndIf'&@CRLF&@TAB&'Return $f'&@CRLF&"EndFunc") FileClose($file) GUICtrlSetData($StatusBar, 'Done! File Inc_'& $i & '_'&$filename[1]&'.au3 was created!') Sleep(3000) Exit Case $msg = -3 Exit EndSelect WEnd dmob, when I get back home. Regards, taietel [edit] bad formating Edited May 24, 2011 by taietel Things you should know first...In the beginning there was only ONE! And zero... Progs: Create PDF(TXT2PDF,IMG2PDF) 3D Bar Graph DeskGadget Menu INI Photo Mosaic 3D Text Link to comment Share on other sites More sharing options...
engjcowi Posted May 24, 2011 Share Posted May 24, 2011 engjcowi, have you compiled your script for x32 or x64 architecture? Try to compile for x32. The activex was intended for x32, since I use only that. #AutoIt3Wrapper_UseX64=n dmob, the info about the dll is not available for the moment. I've updated the ActiveX for not using the external fonts and I will post it as soon as possible (still needs some testing). Regards, taietel Hi Thanks for your help. ive added the above and still says cannot register. when i get more time im gonna try to register the dll manually Drunken Frat-Boy Monkey Garbage Link to comment Share on other sites More sharing options...
taietel Posted May 24, 2011 Author Share Posted May 24, 2011 engjcowi, when I ran the application in windows 7 (32 bit), it can not register the activex as long as I run it as admin. On windows 7 (x64), the script will register the ActiveX if it is compiled as 32 bit application. The script, as it is now, tries to register the activex with the x64 version of the regsvr32 (that one from System32). Change the path to %systemroot%\SysWoW64\regsvr32.exe (see this article) in the script and I think it will solve your problem.Regards,taietel Things you should know first...In the beginning there was only ONE! And zero... Progs: Create PDF(TXT2PDF,IMG2PDF) 3D Bar Graph DeskGadget Menu INI Photo Mosaic 3D Text Link to comment Share on other sites More sharing options...
pinkfoyd Posted May 25, 2011 Share Posted May 25, 2011 Hi ! Got this error when running pdfAutoit.au3 +>15:51:08 Starting AutoIt3Wrapper v.2.0.1.24 Environment(Language:040C Keyboard:0000040C OS:WIN_XP/Service Pack 3 CPU:X64 OS:X86) >Running AU3Check (1.54.19.0) from:C:\Program Files\AutoIt3 +>15:51:08 AU3Check ended.rc:0 >Running:(3.3.6.1):C:\Program Files\AutoIt3\autoit3.exe "E:\_Downloads\pdfAutoit\pdfAutoit.au3" E:\_Downloads\pdfAutoit\pdfAutoit.au3 (543) : ==> The requested action with this object has failed.: .Cell ($sText, $C[1], $C[2]+5, $C[3], 10) .Cell ($sText, $C[1], $C[2]+5, $C[3], 10)^ ERROR ->15:51:11 AutoIT3.exe ended.rc:1 >Exit code: 1 Time: 3.927 Link to comment Share on other sites More sharing options...
Emiel Wieldraaijer Posted May 29, 2011 Share Posted May 29, 2011 (edited) Hi Taietel,Thanks for this master piece I have no luck adding an image to a PDF with .ImageWhich image formats are supported ? I've tried gif and png both with no luck *** Edit : jpg works ***Thanks Best regards,Emiel Edited May 31, 2011 by Emiel Wieldraaijer Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
dmob Posted June 1, 2011 Share Posted June 1, 2011 JPG works for me... Link to comment Share on other sites More sharing options...
StuffByDennis Posted June 11, 2011 Share Posted June 11, 2011  If you want to output pdf's from your application, you can use this ActiveX DLL (embeded in the script). It's small and very easy to use. Here is a screenshot of the first page generated by the example. First, unpack the Fonts directory in the scriptdir (if you put it in another location, replace the path in the script). [EDIT] Deleted old version (165 downloads) and uploaded new one*       *all included in the au3 Love it Works greate except the pdf file created causes an Arial-Bold BBox error when opening. Last file I downloaded had Helvetica-Italin BBox error. Fixing it would be greatly appreciated. StuffByDennis Link to comment Share on other sites More sharing options...
Emiel Wieldraaijer Posted June 12, 2011 Share Posted June 12, 2011 @StuffByDennisIf you don't use these fonts, just remove the code which is causing the problem, thats what i did.Or search the internet and download the files and recreate them with the code -> second post on page 6.I believe this code is based on Basicly this embedding is useless because it isn't used as it supposed to be.. because the files are saved. I would prefer to use the Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
pintas Posted June 13, 2011 Share Posted June 13, 2011 Any way to digitally sign the PDF? That would be very helpful to me. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now