Solved

scrollviewer

Posted on 2009-05-06
3
255 Views
Last Modified: 2013-11-12
HI,

I want to add a number of thumb size photos to a scrollable area.

q1)How do i do style the scroll viewer  as the scrollbars dont look that good ?

 q2) I have an image in the scrollviewer and want to invoke the click event of the image but click event doesnt appear anymore?

 img2 = New Image
        url2 = New Uri("images/armythumb.png", UriKind.Relative)
        uu2 = New BitmapImage(url)
        uu2.UriSource = url2
        img2.Source = uu2
        Canvas.SetLeft(img2, 20)
        Canvas.SetTop(img2, 5)


        sv = New ScrollViewer
        sv.Height = 80
        sv.Width = 200
        Canvas.SetLeft(sv, 100)
        Canvas.SetTop(sv, 100)
        sv.HorizontalScrollBarVisibility = ScrollBarVisibility.Visible
        sv.VerticalScrollBarVisibility = ScrollBarVisibility.Visible
        sv.Content = img1
        LayoutRoot.Children.Add(sv)
0
Comment
Question by:jagguy
  • 2
3 Comments
 

Author Comment

by:jagguy
ID: 24313464
i want to style the tab where you scroll  with the mouse and the scrollbar width
0
 
LVL 9

Accepted Solution

by:
peterdungan earned 500 total points
ID: 24314690
If you want to add several photos to the same scrollviewer, you need to place a canvas or a grid as the content element of the scrollviewer, and add the images to that.
The click event is only for buttons. You need to use MouseLeftButtonDown instead.
0
 

Author Comment

by:jagguy
ID: 24320912
OK  i can add photos and click on them .
I really just needed to know how to style the scrollbars and the tab?
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

This article describes a technique for converting RTF (Rich Text Format) data to HTML and provides C++ source that does it all in just a few lines of code. Although RTF is coming to be considered a "legacy" format, it is still in common use... po…
After several hours of googling I could not gather any information on this topic. There are several ways of controlling the USB port connected to any storage device. The best example of that is by changing the registry value of "HKEY_LOCAL_MACHINE\S…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

813 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

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now