Click here to Skip to main content
15,888,610 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
What is the equilanet for
Activecells.Characters(1,5) in C# .Net?
Posted
Comments
Cueen 8-Jan-16 6:11am    
I presume you're looking to format just a piece of text in some excel's cell with C#, in that case try this:

application.ActiveCell.get_Characters(1,5)

Note that application is an object of Microsoft.Office.Interop.Excel.Application type.
Also in case you're interested you can check out a C# library for excel files, it can enable you to format the individual characters and words within a cell in a more intuitive manner (see here).

1 solution

Looks like string.Substring(1, 5) to me...
 
Share this answer
 
Comments
fjdiewornncalwe 22-Dec-10 10:28am    
Apparently someone found your answer repulsive, John...
agkannan 23-Dec-10 1:52am    
Which is not like that john.

i am just using this in Excel application.
Do u have any other idea?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900