.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

lossing focus from model pop up window controls

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

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 

View Complete Post

More Related Resource Links

Binding WPF Controls to an Entity Data Model

In this interview, programming writer, McLean Schofield, demonstrates how to bind WPF controls to an entity data model, using Visual Studio 2010 Beta 1. You can also learn more in the topic: Walkthrough: Binding WPF Controls to an Entity Data Model.

Binding WPF Controls to an Entity Data Model

In this interview, programming writer, McLean Schofield, demonstrates how to bind WPF controls to an entity data model, using Visual Studio 2010 Beta 1. You can also learn more in the topic: Walkthrough: Binding WPF Controls to an Entity Data Model.

Generated controls - skipping focus event - C# + JS


Ok, here is my senario.

A random (6-15) amount of textboxes are generated. Each textbox represents only one character. From those textboxes, three of them (at a random position) are enabled and the rest disabled.


When I put a character in any enabled textbox, it must put the focus on the next enabled textbox.


Textbox IDs go from 'char0' to 'char15' OR 'char0' to 'char12' OR ...

All the textboxes are generated so I can't set up specific focus events for each textbox because the designated control is unknown at design time.

Here is my attempt:


<script type="text/javascript">
    function abc(nextfocus)


for (int i = 0; i < focusableControls.Length-1; i++)
focusableControls[i].ClientSideEvents.KeyDown = "abc(" + focusableControls[i + 1].ID + ")";


focusableControls is an array with all the textboxes in that can get focus. It is also in the right order.

Things I want to find out:

How will I send the textbox out of focus

How to prevent Javascript window to steal focus

Hi,I have made an asp.net web application in which i open a javascript window for 4 seconds at regular interval . The problem is that when window opens it steals focus from current application. For example when application is running in background or is minimized and i am typing in word/Excel or outlook, the window pops up and steals the input focus.I want to popup window in some way that it never steal focus from some other application, just like msn or gtalk notification when someone sign in/out.Please suggest how it can be done ? Thanks

change focus on controls in sharepoint list newform.aspx

hi all. i have newform.aspx where i hav required fields . when i say ok to enter the values the required field valiedates and shows error messages. but the problem is that the focus where it is suppose to get placed is promting in differnet place. can i change the focus of the controls inside newform.aspx or editform.aspx?jayaraja

Unexpected focus behaviour when disabling controls

I'm working with WindowsForms using C#, but I think the described control behaviour is language independent... I have a form containing 3 comboboxes A, B and C, which have the taborder A.TabIndex=0, B.TabIndex=1 and C.TabIndex=2. Combobox B is enabled/disabled depending on the content of A.Text in A's Validating event (A.Text = "dis" disables combobox B, A.Text="other" enables combobox B): private void A_Validating(object sender, CancelEventArgs e) {     if (A.Text == "dis") {         B.Enabled = false;     }     else {         B.Enabled = true;     } } The behaviour following then is very strange (executed exactly in the given order): 1.) I'm entering "dis" in combobox A. When pressing the tab key, the Validating event disables combobox B. Expected behaviour:  Focus is moved to combobox C Actual behaviour: Focus stays on combobox A 2.) I'm then entering "other" in combobox A and pressing the tab key. Expected behaviour:  Validating event is called and enables combobox B. Focus should then be on B. Actual behaviour: Validating event is NOT called, therefore B is still disabled. Focus is now on C. 3.) I'm setting the focus on combobox A (using tab key or mouse) and

Change a controls properties from another window

I have a WPF App that opens a window (MainWindow) and has a button control that creates a new instance of a Window2 class and calls window2.show() When I click this button I disable it from within MainWindow code. The question I have is when the Window2 onclosing event is called  how do I access the Mainwindow button properties to enable it again. TIA Mike

how to open a subform model Form,Sub Window form using jquery that save the data ajex

how to open a subform model Form,Sub Window  form using jquery that save the data ajex

how to open a model window in server side


i use


it local open

but server side not open modal window

How to prevent the window stealing focus on .Net framework 3.0?



We created a wpf window which will be poped up on the right bottom of the screen, like the notify window of MSN when contact is online, Topmost is set as true for this window, When this window shows, it will steal the focus of current application. For example, user is typing, when this popup window showed, it steal the focus and interrupt user's typing. It is boring.

How to prevent the window stealing focus on .Net framework 3.0?



How make Controls scalable when resizing Window?


How do I make my Controls scalable in relation to the size of the Form?

I mean, when the Anchors of a Panel on a Form are set to all 4 borders then the Panel Width/Height properties change when changing the Form size but the Left/Top position of the Panel is fixed and not changing. What properties do I have to set to what value to also make the Panel's Left/Top position move when the undelying Form size is changed?



Controls in a WPF UserControl don`t raise lost focus



I have a MainWindow with 3 main buttons at the top and below a MainUserControl.

In the MainUserControl I have at top 3 UserControls with ButtonBars and at the bottom a DataGrid.

When I enter data in a DataGridCell and I click into another cell a property change is fired in my ViewModel bound to the DataGrid.

When I enter data... and I click on one of the 3 main buttons again a property change is fired because of Lost Focus event.

When I ... and I click on one of the buttons in the ButtonBar in the UserControl no property change is fired because there seem to be no Lost Focus event.

How can I fix that?

iframe model window problem


i am using the and model window



and demo



when we click on demo page i click outside the iframe

the iframe is close

what is the jquery  code for clicking  outside of the iframe then iframe is not close

and how can load iframe useing jquery ajex


Custom Controls in C# .NET

Embedding user controls in a Windows form is just like adding a simple button or text box that are already provided with .NET. These basic controls were written essentially like you code your own controls. Typically the controls you design are to be used in multiple forms or to modularize your code. These reasons help reduce the amount of code you have to type as well as make it easier for you to change your implementation. There should almost never be any reason to duplicate code because it leaves a lot of room for bugs. So, implementing functionality specific to your control in the control's source code is a good idea. This reduces code duplication as well as modularize your code, which is a good programming guideline.

Accessing the different controls inside a GridView control

how we can access a particular control which resides inside a GridView control. In this article I will show you how you can access different controls inside a GridView control. We will see how we can access a TextBox control, a DropDownList control and a ListBox control. If you are working with ASP.NET 1.X then you might want to check out my article Accessing Different Controls Inside a DataGrid.

Using ASP.NET 3.5's ListView and DataPager Controls: Displaying Data with the ListView

Prior to ASP.NET 3.5, developers who needed to display a set of records could choose between the GridView, DataList, and Repeater controls. The GridView provides rich data features, but has a very boxy layout; the DataList and Repeater allow for a more flexible layout, but lack the "point and click" data features found in the GridView, DetailsView, and FormView controls. The ListView bridges the gap between layout flexibility and built-in data features.

This article, the first in a series of articles on the ListView and DataPager controls, looks at the ListView's many available templates and illustrates how to display data. Read on to learn more!

Model View Controller (MVC) for ASP.NET

Model View Controller (MVC) architectures, immediately wonder how the MVC pattern can be applied in an ASP.NET world. This article will demonstrate how the MVC pattern can be applied to an ASP.NET web application and still maintain the basic Microsoft supplied architecture.
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