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

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Animate window height

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

Hi, All:


I have a storyboard which reduce my window height to 40. See below:


            <Storyboard x:Key="StoryBoard_Collapse">
                <DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="me" Storyboard.TargetProperty="Height">
                    <SplineDoubleKeyFrame KeyTime="00:00:00.3000000" Value="40">
                            <KeySpline ControlPoint1="0.175,0" ControlPoint2="1,1"/>

View Complete Post

More Related Resource Links

IE Process Start and Window Height

Hi, I'm working on a tool for cross-browser testing: the idea being that a WinForms app will open a range of URLs over a range of browsers, and save each out as a screenshot. I have a problem with Internet Explorer though - namely that the opened window thinks it's a lot larger than it actually is... Background: I've got some javascript/jQuery, that happily reads a parameter from a URL, and scrolls a page down - so for example http://mypage/?scroll=1 will show the top part of a web page, http://mypage/?scroll=2 shows the second part, and so forth. The scrolling mechanism uses $(window).height() and $(document).height() - both of which are standard javascript methods that work happily.   $(document).ready(function () { var windowHeight = $(window).height(); var documentHeight = $(document).height(); alert("Window Height: " + windowHeight + "px, Document Height: " + documentHeight + "px" ); });   If I open my url in IE normally, it picks up (for example) a window height of 880px - which is correct since my screen is 1050px high, minus a bit for the IE toolbars/furniture. In my WinForms application, I can open IE happily with one of the scrollable urls - namely   process.StartInfo.CreateNoWindow = false ; process.StartInfo.WindowStyle = ProcessWindowStyle.Maximized; process.StartInfo.FileName = "iexpl

How to create a wpf-dialog window with constant height?

Good afternoon. I need to create a dialog wpf-window with the constant height. One can see a window height in wpf-editor, and set this value to MinHeight and MaxHeight properties. Here's a simple XAML-code: <Window x:Class="ClassName" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Height="94" Width="243" MaxHeight="94" MinHeight="94"> <Grid> <Button Content="Button" Height="23" HorizontalAlignment="Left" Name="button1" VerticalAlignment="Top" Width="75" /> <Button Content="Button" Height="23" HorizontalAlignment="Left" Margin="146,32,0,0" Name="button2" VerticalAlignment="Top" Width="75" /> </Grid> </Window> However, when running the application, one sees the window has a larger height. What's the bug? Tell me please, how to make a dialog wpf-window with the constant height?

Wrong window height when running the WPF App



I have the XAML code below with a fixed width and height but when I run the application it is changing the height automatically. How can I fix this?

Here's the code:

<Window x:Class="Vodia.Clinica.LoginWindow"
    Title="Clínica - Login" Height="225" Width="388" Topmost="True" WindowStartupLocation="CenterScreen" WindowStyle="None" ResizeMode="NoResize">
    <Border BorderBrush="Black" BorderThickness="1">
          <ColumnDefinition Width="70" />
          <ColumnDefinition Width="*" />

        <Border Grid.Column="0" Grid.Row="1" Background="LightGray"></Border>

        <Image Height="32" HorizontalAlignment="Left" Margin="21,26,0,0" Name="imgCadeado" VerticalAlignment="Top" Width="32" Source="/Vodia.Clinica;component/Images/base_key_32.png" />
        <Label Content="Usuário" Grid.Column="1" 

New window with width and height identitical to the page content


hi all forum

I have my NewsDetails.aspx page which displays a certain news  in a gridview according to the NewsId query string field. i wish to make the user able to print the page or mail it to a friend  so I used the following code

protected void ArticleGrid_RowCommand(object sender, GridViewCommandEventArgs e)
        if (e.CommandName == "print")
            int NewsId = int.Parse(e.CommandArgument.ToString());
            string url = "ForPrint.aspx?NewsId=" + NewsId;
            string js = "<script language='JavaScript'>window.open('" + url + "','" + ArticleLbl.Text + "',";
            js += "'top=0,left=0,status=no,width=710,height=700,resizable=no,scrollbars= yes');";
            js += "</script>";
            ClientScript.RegisterClientScriptBlock(this.GetType(), &

Animation a window height Extreme Jitter


When making a window grow exposing a couple of controls the animation jitters like crazy... Is there any way to make it smooth?  When I shrink the window hiding the controls its smooth as silk.


Modal popup window in ASP.Net

A Masked div or modal popup window is a child window created from the parent window which prevents the user from interacting with parent window before he returns to the parent application.

lossing focus from model pop up window controls


hi i using a model pop up window with some textbox but when i click on textbox of model pop up focus move to back to page textbox control plz help me 

animate effect work but the render items are messed up.


Hi all,

     I have a very unique problem, humm i think. I am using a jquery effect that animate bounce effect, i have a line in my javascript pageLoad function $("#UserBrowserInfoDIV").show('bounce'); - the effects run smoothly but what it does is mess up the bolded text in the div. I have try the items inside the div without bolding and it works fine and no render problem but when bolded the text that are bolded is quite messed up, and barely readable.

Please let me know is there anything else i can do i really would like use this effect.

P.S all the effect have the same render problem, and i am using ie8 under compatibility mode.





Open PopUp Window From Error httpModule


I would like to open a popup window from the assembly to present the information to the user. Does anyone know if this is possible, I am presently doing the following:

        WriteLine("body {font-family:""Verdana"";font-weight:normal;font-size: .7em;color:black; background-color:white;}")
        WriteLine("b {font-family:""Verdana"";font-weight:bold;color:black;margin-top: -5px}")
        WriteLine("H1 { font-family:""Verdana"";font-weight:normal;font-size:18pt;color:red }")
        WriteLine("H2 { font-family:""Verdana"";font-weight:normal;font-size:14pt;color:maroon }")
        WriteLine("pre {font-family:""Lucida Console"";font-size: .9em}")

Create a user friendly pop up window


Hello friends I am new to asp.net programming. While working with windows form(windows application) i have created a window for editing purpose(just like popup window ) which contains three bounded dropdown list a button and a gridview. After making selections from the drop down when we press button the corresponding result should display in a grid.After that when you click on the grid row it will load the corresponding datas in my form. i want to create such control in asp.net . i have to use jquery or ajax.And this pop up window i have to use more than twenty times in my application.am using VS2008 ASP.NET and C# 3.5 . Plese suggest me what to do. Thanks in advance

problem in consuming WCF service through Window application


I have a silverlight application and WCF service all made in VS 2010 , i had hosted my site to web server which contain Window 2008 and IIS 7.0

now the problem is i have another application which is a window application developed in VS2008 , when i try to add the service reference it gives me error


The document at the url was not recognized as a known document type.

The error message from each known type may help you fix the problem:

- Report from 'DISCO Document' is 'There was an error downloading 'http://dev_qa.emspa.com/HRDev3/Service.svc?disco'.'.

  - The request failed with HTTP status 400: Bad Request.

- Report from 'WSDL Document' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.

- Report from '' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.

- Report from 'XML Schema' is 'The document format is not recognized (the content type is 'text/html; charset=UTF-8').'.

Metadata contains a reference that cannot be resolved: ''.

Content Type application/soap+xml; charset

Crystal Report parameter value window.


 Hi friends,

   I am using Crystal report which displays the result of stroed procedure which have 2 paramater.

  When i run report it shows two window for getting each parameter.

  My need is, can i have one window for getting all the paramter value for stored procedure.


  With Advanced thanks,






Aero Glass: Create Special Effects With The Desktop Window Manager


In this article we introduce the Desktop Window Manager, the new interface that manages how windows are rendered on the Windows Vista desktop.

Ron Fosner

MSDN Magazine April 2007

C++ Q&A: Window Destruction in the .NET Framework


If a window is destroyed, does the .NET Framework immediately destroy the corresponding Form, or does it wait until a garbage collection to do this? How can you release my resources as soon as the window is destroyed? This month Paul DiLascia gives you the answers.

Paul DiLascia

MSDN Magazine May 2003

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