Jan 03 2022 10:38 PM
In excel the following text i want to bold only which is following highlight text from selected section. how to bold it.
="By debit to our account No.50000141, you are hereby advised to transfer an amount of" &" Rs."& TEXT(Table1[[#Totals],[Amount]], "#,##")&"/-" & "on account of salaries for the month of Dec-21.
The sample file is attached for ready reference.
Jan 03 2022 11:33 PM
Jan 03 2022 11:59 PM
@Jalil1985 PQ doesn't do bold formatting or anything alike. VBA is not my kind of thing.
Jan 04 2022 12:25 AM
Hi @Jalil1985
I agree that it seems not possible without a macro, but with VBA it is possible.
Put the different parts in separate cells and generate A2 as static text;
Sub boldSum()
part1 = Range("Part_1").Value
part2 = Range("Part_2").Value
part3 = Range("Part_3").Value
Range("a2").Select
ActiveCell.Value = part1 & part2 & part3
ActiveCell.Characters(Start:=Len(part1), Length:=Len(part2)).Font.FontStyle = "Bold"
End Sub
Thus, the attached file is xlsM.
-/-
i5:i7 are named Part_1 to 3 to be easy possible to move to another sheet with preferences. Cut and paste and tha macro will still be functional.
Jan 04 2022 07:55 AM