Enter description next to a number

Panoos64

Well-known Member
Joined
Mar 1, 2014
Messages
882
Hi all, i would like to write a vba so that where in col. "D" the number start from number 92 and in col. "F" is the category "BEVERGAE" should place on number's right side "APERITIF" and if in col. "F" and it start from 92 should place "SPICES" and so on.

In sch.1. are the original data and in sch.2. is the expected result.

Many thanks in advance

SCH.1.
ABCDEF
1DATETYPEREF.1REF.2TR. NOCATEGORY
203-02-17ISSUE 92145 BEVERAGE
310-05-17ISSUE 92505 BEVERAGE
410-05-17ISSUE 92800 BEVERAGE
510-05-17ISSUE 92905 FOOD
610-05-17ISSUE 92608 HOT BEVERAGE
710-05-17ISSUE 92700 HOT BEVERAGE

<colgroup><col style="mso-width-source:userset;mso-width-alt:1462;width:30pt" width="40"> <col style="width:48pt" width="64"> <col style="mso-width-source:userset;mso-width-alt:1682;width:35pt" width="46"> <col style="mso-width-source:userset;mso-width-alt:2048;width:42pt" width="56"> <col style="mso-width-source:userset;mso-width-alt:3913;width:80pt" width="107"> <col style="mso-width-source:userset;mso-width-alt:3328;width:68pt" width="91"> <col style="mso-width-source:userset;mso-width-alt:4534;width:93pt" width="124"> </colgroup><tbody>
</tbody>



SCH.2.
ABCDEF
1DATETYPEREF.1REF.2TR. NOCATEGORY
203-02-17ISSUE 92145 APERITIF BEVERAGE
310-05-17ISSUE 92505 APERITIF BEVERAGE
410-05-17ISSUE 92800 APERITIF BEVERAGE
510-05-17ISSUE 92905 SPICES FOOD
610-05-17ISSUE 92608 COFFEE HOT BEVERAGE
710-05-17ISSUE
92700 COFFEE HOT BEVERAGE

<colgroup><col style="mso-width-source:userset;mso-width-alt:1462;width:30pt" width="40"> <col style="width:48pt" width="64"> <col style="mso-width-source:userset;mso-width-alt:1682;width:35pt" width="46"> <col style="mso-width-source:userset;mso-width-alt:2048;width:42pt" width="56"> <col style="mso-width-source:userset;mso-width-alt:3913;width:80pt" width="107"> <col style="mso-width-source:userset;mso-width-alt:3328;width:68pt" width="91"> <col style="mso-width-source:userset;mso-width-alt:4534;width:93pt" width="124"> </colgroup><tbody>
</tbody>
 
Hi Marcelo, both of them work. I am sorry if i was bother you. As i said i wanted to improve my knowledge. Thanks once again. Have a nice day!
 
Upvote 0

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes

Forum statistics

Threads
1,215,444
Messages
6,124,891
Members
449,194
Latest member
JayEggleton

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top