Project Analyzer

String literal analysis - PicInfo sample application

String literals

String length Count Bytes spent  
Empty strings 1 6  
1 char 1 8  
2 chars - -  
3 chars 1 12  
4-9 chars 8 148 ***
10-19 chars 5 178 ****
20-29 chars 9 492 ***********
30-39 chars 4 304 *******
40-57 chars 2 234 *****
Total 31 1382

Duplicate string literals

Duplicate cases 1

String length Count Bytes to save  
Empty strings - -  
1 char - -  
2 chars - -  
3 chars - -  
4-9 chars 1 20 ******************************
10-19 chars - -  
20-29 chars - -  
30-39 chars - -  
40-57 chars - -  
Total 1 20

Each string takes (2*length + 6) bytes in the executable.
Savings can be reached by replacing duplicate cases with constants.

Other string data

Attributes (bytes) 224
Declare sub/func (bytes) 54

Each attribute string takes length+2 bytes in the executable.
Only exposed attributes (of public methods in public classes) are compiled.
This analysis does not detect how many attribute bytes are actually compiled into the executable.
You can reduce attribute bytes by removing the attributes.

Each Declare statement string takes length+6 bytes in the executable.
To decrease the space requirement you need to delete some Declare statements.

Duplicate list


"Error #"

PicMain.FileDialog:
  ErrMsg = "Error #" & ErrCode & " with file open dialog" & vbCrLf & ErrMsg
PicMain.FileDialog:
  ErrMsg = "Error #" & ErrCode & " with dialog " & DialogTitle & vbCrLf & ErrMsg

Info

This report is available for 32-bit VB versions from 4.0 to 6.0 and VB.NET.
At this time, we analyzed according to VB6.

None of the data on this report include strings properties of VB Classic form controls.

Constants defined by concatenating other constants (with the & and + operators)
get stored in the executable but are not counted in this report. Do not optimize
by defining additional constants with the & and + operators.

This analysis doesn't take conditional compilation into account.
Your executable may contain less string data due to exclusion by #If directives.