Jump to content
gahhon

Generate Fancy Report - (Moved)

Recommended Posts

gahhon

Is there any resource/sample to generating a fancy report?

I was downloaded this resource and try the example, but it failed to execution due to function not define. PDF

My simple idea of generating the report would be like this:-

Read data from excel instead of database, then generate PDF report based on my custom design.

Any better ideas is much appreciate to share with me here

Thanks.

Share this post


Link to post
Share on other sites
water

Please post the exact message you get in the SciTE output pane.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
iCal (2019-01-22 - Version 0.1.0.0) - Download - General Help & Support
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
Chimp

in that udf, the "function not defined" error, is caused by the lack of the _Iif() function.
have a look to this post (https://www.autoitscript.com/forum/topic/187723-create-a-pdf-with-own-style/?do=findComment&comment=1348757) for a workaround to that problem and also as an easy example to generate "fancy" reports.

 

Edited by Chimp

small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt....

Share this post


Link to post
Share on other sites
JLogan3o13

Moved to the appropriate forum, as the AutoIt Example Scripts forum very clearly states:

Quote

Share your cool AutoIt scripts, UDFs and applications with others.


Do not post general support questions here, instead use the AutoIt Help and Support forums.

Moderation Team


√-1 2^3 ∑ π, and it was delicious!

How to get your question answered on this forum!

Share this post


Link to post
Share on other sites
Vincor

@gahhon Give also an example of Excel data - is it named fields, columns, etc, or how do you find your data in your spreadsheet?

What kind of report do you need? Is it a single-page, lots of numbers kind of thing, or a many-pages bla-bla report?

Does the output of the script need to be a PDF, or could it be e.g. Word, which you then "print" to a PDF?

Share this post


Link to post
Share on other sites
gahhon
14 hours ago, Chimp said:

in that udf, the "function not defined" error, is caused by the lack of the _Iif() function.
have a look to this post (https://www.autoitscript.com/forum/topic/187723-create-a-pdf-with-own-style/?do=findComment&comment=1348757) for a workaround to that problem and also as an easy example to generate "fancy" reports.

 

Indeed. And I test run your example script is not what I am looking for.
Your script is return a PDF with Calendar print on graph paper.

What I am looking for is normal blank background with printed data.

2 hours ago, Vincor said:

@gahhon Give also an example of Excel data - is it named fields, columns, etc, or how do you find your data in your spreadsheet?

What kind of report do you need? Is it a single-page, lots of numbers kind of thing, or a many-pages bla-bla report?

Does the output of the script need to be a PDF, or could it be e.g. Word, which you then "print" to a PDF?

Usually the Excel is act like a table right. So in the Excel file there should be Header Row and Header Left Column, and within of them there should be have their appropriate data.

Regarding the paging, I cannot say is single page or multiple page, it still have to depending the volume of the data.

I think PDF would be the common report format?

12 hours ago, JLogan3o13 said:

Moved to the appropriate forum, as the AutoIt Example Scripts forum very clearly states:

Moderation Team

Thanks for moving the topic.

Share this post


Link to post
Share on other sites
water

As you seem to have Excel installed on your computer I assume the same for Word.
It should be simple to copy/paste data from Excel to Word, arrange/format it and then save it as PDF.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
iCal (2019-01-22 - Version 0.1.0.0) - Download - General Help & Support
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Similar Content

    • gahhon
      By gahhon
      I have a python script automate.py and I wanna run it via CMD.
      As I know to execute python via CMD is something like this
      $CMD = "Something python here" Run(@ComSpec & " /c " & $CMD) But how can I just open the 1 CMD and send multiple commands to the CMD based on the function called?
      For instance like:

      Launch CMD and send python then send import automate If google() function is called - send automate.google() to the CMD If yahoo() function is called - send automate.yahoo() to the CMD  I don't want to execute multiple CMD to call the automate functions. This is due to inside the python script have global variable to handle duplicate flag.
      So if I execute multiple CMD to call the functions, the global variable will be keep new as NULL. Which is not my expectation.
       
      Thanks
    • gahhon
      By gahhon
      I only found that AutoIt can actually execute the entire python script or execute the .exe (converted to .exe from .py)
      But what if I just want call the particular function? If that possible to do so?
      This is because python can't create fancy GUI like AutoIT does. So my plan is use AutoIT to have fancy GUI.
      Then each buttons will trigger specific function in the python script or .exe file.
      For instances:
      btnSum - trigger function in python script or .exe file (funcSum)
      btnMinus - trigger function in python script or .exe file (funcMinus)
       
      Thanks for advance information.
    • nacerbaaziz
      By nacerbaaziz
      Hello my friends
      Can we create a single context menu on more than one item?
      For example, a context menu includes standardized options on more than one control, such as buttons or check boxes
      to Create a context menu on one item am using this function
      GUICtrlCreateContextMenu ($ HWND)
      How to link it with more than one element please?
      or if we can't do that, please give me a solution
      so i tried to add an context menus to all the controls but the script will be long, for that if their are any solutions i hope to give it to me
      thanks in advanced
    • gahhon
      By gahhon
      _Metro_SplashTextScreen(1, "", $iMsg) AdlibRegister("_Metro_LoopInProgress") DirRemove($DIR_WA_FOLDER, 1) Local $iCopy = _WinAPI_ShellFileOperation($CUR_WA_FOLDER, $DIR_WA_FOLDER, $FO_COPY, BitOr($FOF_SIMPLEPROGRESS, $FOF_NOCONFIRMMKDIR)) AdlibUnRegister("_Metro_LoopInProgress") _Metro_SplashTextScree If @error Then _Metro_MsgBox(0, "", $iCopy) _FileWriteLog($LOG_INSTALLATION, "Error: " & $iCopy) Else _Metro_MsgBox(0, "", "Application is up to date!") _FileWriteLog($LOG_INSTALLATION, "Debug: Application is up to date.") EndIf According to the help file of _WinAPI_ShellFileOperation there are a lot of failure and error code. But how can I handle all of them and display corresponding error message based on the help file?
      The incident is like this:
      I'll lock the folder with permission, so when I execute the _WinAPI_ShellFileOperation to copy and overwrite the folder contents, it popped me an error message saying that permission issue to caused I can't access the folder and overwrite the contents.

      Then I clicked Cancel button, and my AutoIT application exit immediately and it's not execute the function _Metro_MsgBox(0, "", $iCopy) to display the message.
       
      Anyway, I did also tried the code below, the it still display "Application is up to date!"
      According to the help file, 120 - Security settings denied access to the source.
      If @error = 120 Then _Metro_MsgBox(0, "", $iCopy) _FileWriteLog($LOG_INSTALLATION, "Error: " & $iCopy) Else _Metro_MsgBox(0, "", "Application is up to date!") _FileWriteLog($LOG_INSTALLATION, "Debug: Application is up to date.") EndIf  
    • gahhon
      By gahhon
      I have a application that have a function is to create a shortcut to desktop, lets say is ChromePortable.lnk.
      $iCreate = FileCreateShortcut($DIR_WA_FOLDER & '\GoogleChromePortable.exe', $DIR_SHORTCUT, $DIR_WA_FOLDER, '--kiosk "https://example.com/"') So the shortcut will be launch as kiosk mode and force to enter the specific website. However, the user is still able to right-click on the shortcut and modify the target value to remove the kiosk mode. What can I do to disable the user to editing the target value?
      So far, I had asked and tried from SuperUser for advises Disable Shortcut Target Field
      icacls "ChromePortable.lnk" /GRANT EVERYONE:RX So this will set the permission of this shortcut file to only Read & Execute only! But after I set it, the user is still can modify.
      Please kindly advise.
      Please note and assume that user don't have Administration account or etc, that should be only have 1 account to logon to the computer.
       
      EDIT:
      I must disable inheritance to remove all others permissions like SYSTEM, ADMINISTRATORS, etc. Then only GRANT everyone for READ & EXECUTE only.
      But still the user can go to edit the permissions tho. Any advise?
×