Solved

Modify (customize) size of indent in Excel

Posted on 2010-11-29
5
2,980 Views
Last Modified: 2012-05-10
Hello,

In Excel (2007), is there any way to change or customize the default size of indents?

I am not referring to the width of columns but rather, the indent inside a given cell which can be accessed in two different ways (that I know of):

1)  > Ribbon Home tab > Alignment section > Increase Indent or Decrease Indent buttons

2)  > Ribbon Home tab > Alignment section > bottom-right expansion button > Text alignment > Indent box

The second option allows you to set the number of desired indents, but unfortunately, not the width of each indent.  It is this width with which I am struggling.  If anyone knows how to reset or modify that, I would appreciate knowing.

Thanks
0
Comment
Question by:Steve_Brady
  • 2
  • 2
5 Comments
 
LVL 50

Accepted Solution

by:
Ingeborg Hawighorst earned 500 total points
ID: 34235514
Hello Steve,

I don't think you can change the indent size. My empirical tests show that it remains the same, even for different font sizes. You can use code to set the indent level (between 1 and 15) but I have not found any indicator of setting the base size of the indent width.

cheers, teylyn

0
 
LVL 37

Expert Comment

by:TommySzalapski
ID: 34235523
With the macros we discussed a few questions ago you can set them to whatever you want. Then you can add them to the ribbon or a hotkey or both as we discussed then.
Sub IncreaseIndent()
    Selection.InsertIndent 3 'Can be anything (I suppose up to 15)
End Sub
Sub DecreaseIndent()
    Selection.InsertIndent -3
End Sub

Open in new window

0
 

Author Comment

by:Steve_Brady
ID: 34305173
Thanks for the responses.

>>...you can set them to whatever you want.
>>Selection.InsertIndent 3
>>Selection.InsertIndent -3


Tommy, please correct me if the following is wrong but I believe your code refers to the number of indents to be inserted rather than the width of each individual indent (e.g. it is not possible to have a width of -3).  Only the latter was the object of my question:

>>The second option allows you to set the number of desired indents, but unfortunately, not the width of each indent.  It is this width with which I am struggling.

0
 
LVL 37

Expert Comment

by:TommySzalapski
ID: 34305357
Ah, yes. Sorry. In that case, I agree with teylyn that the indent size is static. You can't change the width of the indent. Pressing the 'increase indent' button runs this line of code
Selection.InsertIndent 1
and just adds an indent. So you can't change the default size of the indent but you can change the number of indents that your custom button or hotkey makes.
If you press 'record macro' and change the indents in both the ways you mention, you'll see that it isn't changing the width, it's changing the number.
0
 
LVL 50

Expert Comment

by:Ingeborg Hawighorst
ID: 34421966
Thanks for the grade, Steve.

However(/if at all) you celebrate the end of the year, I wish you a peaceful holiday season and a great start into a wonderful 2011.

Please keep posting your interesting questions, where you challenge the usability of MS Excel and prop the experts onto their toes.

It's been  very interesting working with you. I appreciate your drive to learn and understand. I'm absolutely amazed at your communication skills. I'm baffled at your sense of humour and how you've managed to drive finicky disagreements into clear-cut statements of what is important to the parties involved.

Steve, I'm pretty sure that without your questions and your feedback to experts, I would not have achieved the rank I have right now in the same time frame.

Maybe in the new year you could consider  answering questions, too. I believe that with your attitude and mindset you would be a great asset to EE.

From a warm NZ mid summer night, I send you my best wishes and hope you will continue to post your challenges at EE in the new year.  (Just remember to check the open questions from time to time. I'm sure you can answer quite a lot of them, and that will open up a completely new aspect of EE).

Kindest regards,

teylyn


0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Approximate matching with VLOOKUP and MATCH seems to me to be a greatly under-used technique, and one which is vital for getting good performance out of large lookups. Until recently I would always have advised using an exact match for simplicity an…
Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question