Excel 2010 scrollbar goes too far

Frades

New Member
Joined
May 30, 2015
Messages
2
My problem is illustrated in the PrintScreen below:

iw6IWwL.png


I've searched a lot on the Internet and almost all sources say to delete the empty rows at the end of the sheet and save the document. For example that is what is suggested here (see Section 2f) : http://www.contextures.com/xlfaqApp.html#Unused.

Sometimes this works, but most of the time it doesn't!

I don't know if this is relevant information or not, but my Excel document contains three user-defined macros, including two that have to do with comments formatting. There are many comments in the sheet "Notes A", most of them with pictures as backgrounds. Also, my document is not protected, so I do not think the problem is that the extra lines are locked.

Is there a definitive solution to this?

Note: Here are the codes of my three macros.

Module 1: This is a macro that sorts alphabetically the string of letters of a word. For example, applying it to a cell containing HELLO will give EHLLO as the output.

Option Compare TextFunction SortString(ByVal iRange, Optional Croissant As Boolean = True)

<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">'Trevor Shuttleworth, mpep, modifié fs, mpfe
Dim i%, j%, sTemp$

For j = 1 To Len(iRange) - 1
For i = 1 To Len(iRange) - 1
If Mid(iRange, i, 1) > Mid(iRange, i + 1, 1) Then
sTemp = Mid(iRange, i, 1)
Mid(iRange, i, 1) = Mid(iRange, i + 1, 1)
Mid(iRange, i + 1, 1) = sTemp
End If
Next
Next

If Croissant = False Then
For i = Len(iRange) To 1 Step -1
SortString = SortString & Mid(iRange, i, 1)
Next
Exit Function
End If

SortString = iRange

</code>
<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">End Function
</code>
<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">
</code>Module 2: This is a macro that automatically resizes comments containing words.

<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">Sub Fitrangecomments()

</code>
<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">'Updateby20140325
Dim rng As Range
Dim WorkRng As Range

xTitleId = "KutoolsforExcel"
Set WorkRng = Application.Selection
Set WorkRng = Application.InputBox("Range", xTitleId, WorkRng.Address, Type:=8)

For Each rng In WorkRng
If Not rng.Comment Is Nothing Then
rng.Comment.Shape.TextFrame.AutoSize = True
End If
Next

</code>
<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">End Sub
</code>
<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">
</code>Module 3: This is a macro that asks the user to choose a background image for a to-be-created comment and that automatically resizes the comment to match the image dimensions. All credits to its creator here: http://superuser.com/questions/9145...dimensions-to-match-the-background-image-in-e.

Sub InsertComment()
<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">
Dim strImagePath As Variant
Dim objImage As Object

strImagePath = Application.GetOpenFilename("Picture, *.jpg; *.png; *.bmp")
If strImagePath = False Then Exit Sub

Set objImage = CreateObject("WIA.ImageFile")
objImage.LoadFile strImagePath

With ActiveCell
If .Comment Is Nothing Then .AddComment ("")
.Comment.Shape.Fill.UserPicture strImagePath
.Comment.Shape.Height = objImage.Height * 0.75
.Comment.Shape.Width = objImage.Width * 0.75
End With

</code>
<code style="margin: 0px; padding: 0px; border: 0px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, sans-serif; white-space: inherit;">End Sub

P.S. This question has been asked here without any answer : http://superuser.com/questions/919479/excel-2010-scrollbar-goes-too-far.</code>
 
Last edited:

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
Not sure I know what your question is.
Your quote" My problem is illustrated in the PrintScreen below:"
I don't see a problem.
Your post title is: "Excel 2010 scrollbar goes too far"
Are you saying you want to delete all rows below row 664?
If so I would think that's impossible. Excel 2013 has more then one million rows.
 
Upvote 0
My problem is that when I click on the scrollbar and roll it all the way down (as is shown on the picture), it does not stop at the last non-empty line, that is to say, the line 664 in the picture.

In the sheet named Tirages en ordre AN, there are 7207 non-empty rows and when I scroll down to the max, it stops there:

hjIXBDP.png


I want the same for the sheet named Notes A​.
 
Upvote 0

Forum statistics

Threads
1,223,214
Messages
6,170,771
Members
452,353
Latest member
strainu

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