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

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

C++ Q&A: Get the Main Window, Get EXE Name

Posted By:      Posted Date: August 21, 2010    Points: 0   Category :ASP.Net

More Related Resource Links

How to sync main thread and new opened window

Hi all, I need to halt the main thread until some workflow is completed on the opened Window, the opened window has a user control content in which the user enter some data and click the button "next" . how can i halt the main thread and signal it to continue after the next button has been clicked? I've tryed using AutoRestEvent but the main thread get stucked and the window is frozen. ShowDialog wont help me, because i want to keep the window visible after the next button is clicked.     public void SomeMethod() { AppWizardStep2 step2 = new AppWizardStep2(ref myParams); Window myWin = new Window(); myWin.Content = step2; myWin.Show(); //Halt here // ...some logic that needs to continue after user workflow is completed on step2 user control }      

Part of Window content not minimizing with rest of Main Window.


I am developing an IDE-like WPF application.  The application's main window from the Microsoft  has a number of child tool windows and tabbed document windows. 

The layout system for the main window's child controls has been implemented using the Composite Application Library.

Recently, a problem arose in which two particular elements of the main application window did not minimize with the rest of the window.  Instead, these two child elements stay up on the screen.  However, I cannot actually click on the unminimized region.  In fact, I can drag items from desktop through the unminimized regions.  The only thing that I can think of that may be causing this is that the content that doesn't minimize is executing within a separate AppDomain.  The two UIElements from the different AppDomain are remoted from an Add-In (System.AddIn).

Has anyone else experienced a similar windowing problem?

How do you change the color of the main frame on a Window in WPF?


I have an application where all windows have a very custom look/feel.  When the user has their theme set to Classic, or even set to certain default themes, the colors clash with my main app colors.

Seems like it should be easy to set a brush on the Frame portion of a Window in WPF but this appears to be missing from WPF.

I have searched around, but the only solutions have found involve making the main window transparent and manually creating the border and drawing the frame yourself and handling all the sizing/move options yourself.  I got this to work just fine, however I have a window on which I need to use INTEROP to show an HwndHost on a canvas.

HwndHost doesn't appear when being used on a Transparent window, so I simply cannot make the window Transparent without making my app useless.

I have tried setting the WindowStyle="None" and that gets me close, but shows an ugly thin frame around whatever I put on the window.  I wish "None" really meant none..  Unfortunately, it doesn't.

Does anybody have any way to override the color of the main window frame without making it Transparent or setting the WindowStyle="None" ?

Please help me out with a code sample if you have a good solution for this?

Thanks a bunch,



Can not display the value in combo box from main windows in another secondary window.


Hi All.

I have a problem : I have main windows with bind to sql combo box. I want to display at the start of second windows selected value from main win combo box in combo box which located in second windows. I have code that does this but I'm having trouble when I bind combo box from second windows to sql. More than I have this code that displays the selected value from main windows but everytime first row in sql table because a code is selectedIndwx = 0 ;

How can I change the code to display the selected value from the main window and bind combo box at the same time.

there is a code.

Main window.

private void button3_Click(object sender, RoutedEventAr

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 

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