.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Imran Ghani
Sohaib Khalid
Post New Web Links

Thumb Border

Posted By:      Posted Date: October 05, 2010    Points: 0   Category :WPF


 is it possible to remove the Thumb Border 3D style.

i tried using myThumb.BorderThickness = new Thickness(0);. but it still have that 3D effect

View Complete Post

More Related Resource Links

Adding table to a page, but the format lost when I use clear border



I added a table to a page, by default, the table layout is the light border. So, I add my content and the vertical align seems to set to the top. But when I changed it to clear border, the content of the table will set vertical align to center. Is there a way to change this back to top align but with the clear border. I don't think I can do this by what is available in the ribbon. Please advice.

Border at the end of page

hi all, at  the end of report i want to add border in that page. basically, i want to know that ,is it possible to get border at the end of page in ssrs report.  Thanx in advance, Sagar Joshi 

How to set the border for a WPF DataGrid Row which is currently having the focus

Hi, I want to set the border for a DataGrid Row which is currently having the focus. But not the seleced row because when the Multi selection is enabled for the datagrid then there is a chance that multiple rows can be selected. I need a solution in XAML Thanks in advance! Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This will help other members to find the solution easily.

Issue with Combobox - On selecting Item the combobox border becomes red why?

Hi, I have a combobox. <ComboBox DisplayMemberPath="Name" Name="CB" IsEnabled="{Binding ElementName=RB, Path=IsChecked}"<br/> SelectedValue="{Binding Path=Folders, Mode=TwoWay, UpdateSourceTrigger= PropertyChanged}" /> It has Selected value binding with ObservableCollection as public ObservableCollection<T> _folders; public ObservableCollection<T> Folders { get { return _folders; } set{ _folders = value; }} Combobox's IsEnabled property has binding with a Radio button checked value. PS: I don't have any validation here. The problem I am facing is when I select an Itam from Combobox its border becomes red , I don't understand why this is happening.

How to change background or border brush color of an element while it has template in xaml?

Dear all, I want to change some style property of one element in code behind while that element already had a data template in xaml. as an example this is a code for my window: <Window x:Class="Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="Window1" Height="300" Width="300" Loaded="Window_Loaded"> <Window.Resources> <Style x:Key="ButtonStyle" TargetType="{x:Type Button}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate> <ControlTemplate.Resources> <Storyboard x:Key="OnMouseEnter1"> <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="grid" Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)"> <SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/> <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="1.1"/> </DoubleAnimationUsingKeyFrames> <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Story

WPF Border rendering offset when CornerRadius defined

I'm experiencing a strange rendering issue when running WPF based apps on my workstation. The any vertical drawn seems to be offset to the left by 1px. This is especially noticeable on elements that are wrapped by a <Border /> element with it's "CornerRadius" defined. Does anyone have any idea what's going on?   Running: Microsoft Visual Studio 2008Version 9.0.30729.1 SPMicrosoft .NET FrameworkVersion 3.5 SP1BTW this issue IS NOT seen in the designer. Same thing in Blend 3 :

div border issue


 Hiiiiii Coders,

I m using div to display data. Now the width of my div is 800px and also i m displaying bottom border of div to mark the separations between two consecutive divs.

the length of my div's bottom border is same to div's width(800px). But i want that border should be displayed in center of page and it's width should be 400px.

Is it poss?

How can i achieve this?

thanx and regards 

Outside border of a window in Windows 7



I have a defaut window with WindowStyle="None" and in Windows 7 I get a pretty big border - this not happens in XP. How can I get the width of this border?



When border when overlaps another border it gives weird appearance



In the below XAML code, the border for StackPanel "sp2" overlaps with the border for StackPanel "sp1". The overlapped region has border thicker than the non-overlapped region. SnapsToDevicePixels does not help. When SnapsToDevicePixels="false", the border bulges outwards. Otherwise, it bulges inwards.

How can I avoid the border bulging or thickening at the overlapped region? I cannot avoid the overlapping border.

<!--  XAML Code      -->

<Window x:Class="WpfApplication1.Window1"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="Window1" Height="300" Width="300">
    <Grid >
            <Border Margin="30,50,30,3" SnapsToDevicePixels="False" BorderThickness="2,2,2,0" BorderBrush="Black">

Listbox border change padding



In snoop I have noticed that the Listbox has a Border child node with a padding="1,1,1,1" (valuesource is parentTemplate).

How can I change this padding to 0?

Here is the wpf code:

     ItemsSource="{Binding AlarmItems}"
     ScrollViewer.VerticalScrollBarVisibility="Disabled" >               

transparent border around a submenu level in asp menu control..


i know this must be simple but not sure of how to get this done.

i need a border that is transparent around a level of submenu for a asp menu control(not around each of the sub menu item) similar to this.

and also the inside menu should have two layers of submenu if it is too long..

How can i do this.. Its really urgent..

SSRS -Charts border issue

I have five charts in one rdl file in SSRS reports and while exporting to word the border of the charts is coming incomplete.please advice.

how do I change BORDER COLOR for a TEXTBOX (and any other winform control) in a windforms app in VB

Does anyone have the VB code to change  border colors for winform controls such as a textbox?

Issue with ImageButton Border Colors


I am running into an issue with dynamically setting the border color for ImageButtons sitting in 15x15 tablecells.

Here is the relevent code (I removed the code that is not)

    protected void ImageButton1_Click(object sender, CommandEventArgs e)
        ImageButton bt = new ImageButton();
        // Reset the border for the last image button back to default
        ContentPlaceHolder MainContent = Page.Master.FindControl("MainContentArea") as ContentPlaceHolder;
        bt = MainContent.FindControl(Session["SelectedButton"].ToString()) as ImageButton;
        //bt.BorderColor = Color.FromName("#EFEAD7");
        button.BorderColor = Color.Beige;
        // Now set the border for the selected button to black
        bt = sender as ImageButton;
        bt.BorderColor = Color.Black;
        // Save the tile ID for later calls
        Session["SelectedButton"] = bt.ID;

<Part of initial page load code>
    button.BorderWidth = 1;
    if (<condition is true>)
         button.BorderColor = Color.Black;
         Session["SelectedButton"] = button.ID;
         //button.BorderColor = Color.FromName("#EFEAD7");
         button.BorderColor = Color.Beige;

Notice how I have some of the border color assign

3D Border


How can I place a 3D border arround my control



How to draw a textbox border?


We were using the following code to draw a textbox like border:

        VisualStyleElement vse = VisualStyleElement.TextBox.TextEdit.Normal;
        VisualStyleRenderer vsr = new VisualStyleRenderer(vse);

        vsr.DrawBackground(g, area);

This worked for XP. In windows 7 the TextBox border has some fade effects. The code no longer works, so...

Anyone knows if there is there a standard way of drawing a "text box like" border in a custom control?

Blue Border on first web page button


On every web page I build, the first asp:button always has a blue border at runtime, even if I set another button as the default button. How do I make the default button have the blue border without making it the first button on the page, or get rid of the blue border on the first button? 

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend