Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3301530
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T20:45:38+00:00 2026-05-17T20:45:38+00:00

I have a requirement to retemplate the ScrollBar so that only one Template is

  • 0

I have a requirement to retemplate the ScrollBar so that only one Template is required, instead of separate horizontal and vertical ones. The designer’s assertion is that the ScrollBar can be rotated on a Trigger (Orientation = Horizontal), and the commands swapped on the buttons.

Since the single Template is set up as a Grid with rows, the horizontal ScrollBar is stuck in the center of the view when rotated, showing just the left and right buttons. This seems to be because the height of the center * row is the height of the track area, so it won’t stretch. Binding in the Trigger to the height of something like the parent ScrollViewer ActualWidth causes the usual stackoverflow.

Any thoughts? I presume there’s a reason all the examples have a horizontal and vertical templates separate.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T20:45:38+00:00Added an answer on May 17, 2026 at 8:45 pm

    Never mind. I figured it out:

                <Trigger Property="Orientation" Value="Horizontal">
    
                <!-- Rotate the ScrollBar from Vertical to Horizontal -->
                <Setter Property="LayoutTransform" TargetName="gLayoutRoot">
                    <Setter.Value>
                        <RotateTransform Angle="90"/>
                    </Setter.Value>
                </Setter>
    
                <!-- Change Track Orientation back to Vertical -->
                <Setter TargetName="PART_Track" Property="Orientation" Value="Vertical"/>
                <Setter TargetName="PART_Track" Property="IsDirectionReversed" Value="false"/>
    
                <!-- Change the commands to do Horizontal commands -->
                <Setter Property="Command" Value="ScrollBar.LineRightCommand" TargetName="DecreaseRepeat"/>
                <Setter Property="Command" Value="ScrollBar.LineLeftCommand" TargetName="IncreaseRepeat"/>
                <Setter Property="Command" Value="ScrollBar.PageLeftCommand" TargetName="PageDown"/>
                <Setter Property="Command" Value="ScrollBar.PageRightCommand" TargetName="PageUp"/>
    
            </Trigger>
    

    Then in the style set everything to Stretch or Auto.

            <Setter Property="HorizontalAlignment" Value="Stretch"/> 
        <Setter Property="VerticalAlignment" Value="Stretch"/>
        <Setter Property="Width" Value="Auto"/> 
        <Setter Property="Height" Value="Auto"/>
    

    Fortunately one of those things that worked out.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In our project we have requirement that, after receiving sms message from third party
I have requirement in which I continuously receive messages that needs to be written
I have requirement to create asp .net application that will upload garmin .fit files
I have requirement like this: On one server(linux) I need to run 2 instances
i have requirement in which opportunities of a particular record type can only updated
I have requirement for an application which work in background only. When first time
Suppose I have requirement where I have Shape which contains area as only operation.
I have requirement like this, Have One NSIMageView and which will be changing frequently
I have requirement that: When i execute shell script , it should read all
I have requirement in a custom class where I want to make one of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.