Jump to content

Recommended Posts

Posted (edited)

The script was made as an analogue to >Organize Includes and has the following important differences:

  • More correct results.

    For example:

    $t = DllStructCreate($tagBUTTON_SPLITINFO)
    
    ;result Includes Helper :#Include <guibutton.au3>
    ;result Organize Includes:

    Func _test()
    Local $hBrush, $iARGB
    DllCall($ghGDIPDll, "int", "GdipSetSolidFillColor", "hwnd", $hBrush, "int", $iARGB)
    EndFunc
    
    ;result Includes Helper :#Include <gdiplus.au3>
    ;result Organize Includes:

    ;Only under installed library "WinAPIEx"
    
    $var = BitOR($PROCESS_VM_OPERATION, $PROCESS_VM_READ)
    
    ;result Includes Helper :#Include <processconstants.au3>
    ;result Organize Includes:#Include <apiconstants.au3>
  • Includes Helper selects the minimum number needed include files.

    For example:

    Func _test()
    _GDIPlus_BitmapCreateFromFile('FileName')
    _WinAPI_CreateFile('FileName', 2)
    $var = $GDIP_DASHCAPFLAT
    $var = $tagNMIPADDRESS
    $var = $FT_ACCESSED
    _Security__OpenProcessToken($var, $var)
    _WinAPI_GetLastError(@error, @extended)
    _SendMessage($var, $var)
    EndFunc
    
    ;result Includes Helper :#Include <gdiplus.au3>
    ;result Organize Includes:#Include <fileconstants.au3>
    ; #Include <gdiplus.au3>
    ; #Include <gdiplusconstants.au3>
    ; #Include <security.au3>
    ; #Include <sendmessage.au3>
    ; #Include <structureconstants.au3>
    ; #Include <winapi.au3>
    ; #Include <winapierror.au3>
  • Is absent the graphic interface - the results are displayed in the console of SciTE.
  • At insertion the results into the source code is stored history undo-redo (in the editor), as well as bookmarks and folding.

Hot keys:
Ctrl+Enter - start
Esc - exit

Example of connection to SciTE (file "au3.properties")


command.37.*.au3="$(autoit3dir)\autoit3.exe" "$(SciteDefaultHome)\IncludesHelper\IncludesHelper.au3" "$(FilePath)"
# for IncludesHelper.a3x :
# command.37.*.au3="$(autoit3dir)\autoit3.exe" "$(SciteDefaultHome)\IncludesHelper\IncludesHelper.a3x" "$(FilePath)"
# for IncludesHelper.exe :
# command.37.*.au3="$(SciteDefaultHome)\IncludesHelper\IncludesHelper.exe" "$(FilePath)"
command.name.37.*.au3=Includes Helper
command.save.before.37.*.au3=1
command.shortcut.37.*.au3=Ctrl+Enter

*particular connection to SciTE4AutoIt3 : >LINK

Configuration file ("IncludesHelper.ini"):

ShowOptimInfo = 1
: Show the minimum number required include files (1 by default)
ShowDetals = 0
: show all the values and the corresponding external file (0 by default)
ResultToSource = 1
: insert the result in the source code (1 by default)

Note:
The values specified as a string in functions GUIRegisterMsg, AdlibRegister, etc. - are processed only for explicit defined values, without the use of variables and expressions.
Otherwise, a warning to the console.

New in version 1.5:

- Added support for AutoIt 3.3.10.xx (in this version is ignored syntax element as assignment a function to variable).

- Faster processing for 64-bit operating systems (only when the script is run as a 32-bit application).

New in version 1.4:
- Significantly increased performance for 32-bit operating systems.
New in version 1.3:
- The magnified speed of the data processing.
New in version 1.2.3:
- Added processing of the values specified as a string in functions GUIRegisterMsg, AdlibRegister, etc. (only for explicit defined values, without the use of variables and expressions)
- Posted compression of the database (only for NTFS)
- Minor changes
New in version 1.2.1:
- Fix: Do not search for some data (thanks wakillon).
New in version 1.2:
- Fixed update the database if there is a folder "Include" files without the functions, constants and global variables (thanks madmasles).
- Are added hot keys.
- Fixed errors inserting data into a file.
New in version 1.1:
- Added ability to insert the result in the source code.
- Settings are placed in the ini-file.
- Minor fixes

IncludesHelper_v1.3.zip

IncludesHelper_v1.4.zip

IncludesHelper_v1.5.rar

Edited by asdf8
  • 4 months later...
Posted

works great! except when includes look like this:

#include "x:scriptsad.au3"

or like this

#include "ad.au3"

any chance you can incorporate these types of specifications?

thanks for the great tool

Posted

gcue

I have an example of a :

#include "ad.au3"

is processed correctly, and for example :

#include "x:scriptsad.au3"

is replaced with the full path to a relative, which is also correct.

Could you put some sample code to reproduce the problem?

Posted

here's what i tried:

i put AD.au3 in the same directory as the script.au3 and specified #include "AD.au3"

AD.au3 comes up on the "Not Needed Included: " report

and at the bottom i see this

! NOT FOUND INFORMATION FOR :

! _AD_Open

! _AD_Close

! _AD_GetUserGroups

! _AD_GetPasswordInfo

! _AD_GetLastLoginDate

! _AD_GetObjectProperties

i also tried moving AD.au3 to another directory and specified #include "x:scriptsad.au3"

same issue.

Posted

gcue,

try to process the file "test.au3" in the attached file.

If in case you have no error, then, to find the problem, it is desirable to me to see your file "ad.au3".

test.zip

Posted

Quite a strange situation.

Checked for AutoIt version 3.3.6.1 and 3.3.7.22

writes :

! NEED INCLUDED :
#Include "AD.au3"

Please try launch in SciTE file "IncludesHelper.au3" of the attached archive and report here the result.

test.zip

Posted

Quite a strange situation.

Checked for AutoIt version 3.3.6.1 and 3.3.7.22

writes :

! NEED INCLUDED :
#Include "AD.au3"

Please try launch in SciTE file "IncludesHelper.au3" of the attached archive and report here the result.

i got this when running the new includeshelper.au3 against your test.au3

! NEED INCLUDED : (placed in the clipboard)

#Include "AD.au3"

here are the results for my script:

! NEED INCLUDED : (placed in the clipboard)

#Include "....AD.au3"

- NOT NEED INCLUDED :

- U:scriptsAD.au3

i am confused by your wording.. - actually still not sure what each one means :D

"NEED INCLUDED"

"NOT NEED INCLUDED"

"! NOT FOUND INFORMATION FOR "

how about

"UDFs being used but not needed"

so im confused if your new version of includeshelper is fixed =)

thanks again for your help =)

Posted

gcue,

or you have an outdated version, or has been damaged file "IncludesHelper.au3". In any case, the problem must be solved reinstalling the files from the first post.

how about

"UDFs being used but not needed"

for this case there is:

"CORRECTLY INCLUDED"

i am confused by your wording..

here refers to the files are included in script.

You can change the source code for these names are convenient for you.

Posted

gcue

I myself as a script editor using SciTE-Ru instead of SciTE-AutoIt3. Perhaps there is some difference in the parameters.

Try removing the string "command.is.filter.37.*.au3=1" for Includes Helper (file "au3.properties").

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...