How to change font size and font type in excel using vb.net code

Hi All,

When I am trying to write a summary report to excel, I am seeing issues

How to change font size and font type in excel using vb.net code? I can’t use balareva activities due to security restrictions

you should try with VBA (excel macros) instead of VB.net. VBA will give you granular control.

Hey @Krithi1,

You can use modern excel activities to do the formatting instead of vb.net code.

Thanks,
Sanjit

@AkshaySandhu - Macros are disabled as well here. Thus looking for vb.net code

I don’t see any activities related to ‘format’ and ‘resize’ in modern.

search for this activity
image

@Sanjit_Pal

I see it in studioX activities, but I cannot figure out how to read a specific sheet out of 20 different sheets within excel. I need to change the format only for one sheet within excel. What activity should I use to fetch that one particular sheet?

Can someone help with vb.net code here, please?

I need to change the format to “Arial” and size to “11” in one the of the sheet in excel

Hi @Krithi1

Check out the docs

https://www.e-iceblue.com/Tutorials/Spire.XLS/Spire.XLS-Program-Guide/Excel-Font-Set-Excel-Font-in-C-VB.NET.html

Hope it will helps

Regards
Gokul