Hallo J. Dinesh Davidson
In files the product codes for instance 01 is the sum of all 01#### products and 0101 is the sum of all 0101## products.
The Job:
- Make a new exel file named "trade.xlsm"
- There have to be three buttons (names: "Trim" "IIT" "Reports")
1. A button that can do this:
Trim all data in a file (attached) based on the level of digits (for instance show all product with ONLY 2 or 4 or 6 digits) Example with 6 digits is attached.
If 6 digits are chosen THEN all files has to be trimmed AND saved in same folder as the attached (path) and named for instance [login to view URL] ect.
The files that has to be trimmed is based on INPUT from user and the level. (2 or 4 or 6 digits)
Nothing is generated in trade file here.
Be aware that all product ID with 3ed and 4ed digits = 99 are ESTIMATES and are not relevant in generated and trimmed files just as product with NO data.
In trimmed files cells with "-" has to be replaced with 0.
2. A button that can do this:
Creates new files once more called IIT6 or IIT4 or IIT2.
IIT calculated for every year 1990 to 1998 and for the countries/files dnk and aut, dnk and deu (based on data from generated [login to view URL] and [login to view URL]), dnk and esp, dnk and prt
If user has not generated files needed for IIT calculation in button 1 then stop vba showing text "Error"
(see attachment "2")
3 A button that can do this:
- From input(year and level (2,4,6)) a msgbox that shows an IIT number for a country and its partner for a given year. Besides the msgbox has to show the average of IIT over the years 1990-1998 for the chosen country and partner
INFO:
dnk Denmark, deu = deutchland, swe􏰃 sweden, prt􏰃Portugal, aut􏰃Austria.
The 6th character in file name: m = import and x = export. v = value
The formuala for IIT is attached (paint)
When opening files, please use path
In the files
Product numbers are with two digits are the sum of Product numbers with more digits, you will se the link when you look at files.
Not nessesary for you to think much about how fast the code is working OR having including difficult code. Just use simple code. Maybe just use 3 subs, one for each button.