Asp.net - Hiding A Parent Modal Popup In ASP / Ajax

Jun 21, 2011

I have a modal popup extender on a parent form (called from a child aspx is in an iFrame). I'm able to show it by calling

parent.ShowModal();

Which is a javascript function on the parent page that executes $find('ModalPopupExtender1').show();

It works great. But now I've discovered a new problem.

After the VB code-behind is finished executing on the child page, I'd really like to hide that modal form. Don't get me wrong, I have nothing against modal popups. I rather like them in fact. It's just that my users would like it better if they could continue working after the VB code-behind (child page) is finished executing. I tried

ParentForm.ModalPopupExtender1.Hide()
Top.ModalPopupExtender1.Hide

View 1 Replies


ADVERTISEMENT

RadWindow Modal Ajax Popup Hide And Show From Code Behind?

Feb 2, 2011

using a RadWindow control, pop up a modal window containing a dynamically populated CheckBoxList based on user selection on dropdownlist changed.

<telerik:RadWindow ID="UserListDialog" runat="server" Title="Editing record" Width="250" Height="536" VisibleOnPageLoad="false" Modal=true Behaviors="Minimize, Move, Resize,Maximize" Left="580" Top="-8" EnableShadow="true">

[Code].....

View 1 Replies

Asp.net - Refresh DataGrid And DropDown On Main Page After Hiding Modal Popup?

Dec 7, 2009

I am adding records to a database from a modal popup. After hiding the modal popup, the page has not been refreshed (even though I have Re-bound the controls). I have reviewed a few postings on the web about this but the solution still evades me. I have attached my code after removing some of the extra detail.

It seems I need to cause a postback, but I don't know what needs to be changed. Some posts have talked about the extender being misplaced.<asp:Content ID="Content1" ContentPlaceHolderID="Head" Runat="Server">

<div class="divBorder">
<asp:DataGrid id="dgrSessionFolders" runat="server" BorderWidth="2px"
BorderStyle="Solid" BorderColor="#C0C0FF"

[Code]...

View 2 Replies

Asp.net - Setting Control Text In Parent Form From Modal Popup

Mar 28, 2012

I have a problem I am trying to set the parent textbox from the modal popup.

Although I found the control from the modal popup with the below code
DirectCast(Parent.Page.Form.FindControl("ContentPlaceHolder1").FindControl("myAccordion").FindControl("txtTo"), TextBox).Text = str

This is being called on button click when the user has finished selecting from the Checkboxlist.

When the parent page is shown again though the textbox is empty.

The scenario of my user control is that a user is to select from a checkbox list which is a list of emails.

When done has been clicked then it is required that the selected emails be forwarded to the parent webpage.

Then the To Textbox in this case will be filled with the emails that the user has selected.

View 1 Replies

Modal Window - Cannot Refresh Parent (Retry / Cancel Popup)

Jan 15, 2009

I am using modal window for my VB.NET program and I am trying to open this child modal window from another window, after I close the child modal window I am trying to refresh the parent but I am getting retry/cancel popup, I tried a lot of things to avoid but I can't get rid of this popup.

View 1 Replies

Can Edit Inside Of A Modal Popup

Oct 27, 2011

However, I am not using a gridview so editing is not as simple as an edit within a gridview. The modal popup disappears when I click on the edit button. Here is what I have so far, but in the codebehind I get an error saying that my modal isn't declared.In the image below, the little pencil image next to the close button is what I click on to edit the description. When I click on it, the modal disappears, so I cannot edit the text.

<!-- Descriptions -->
<asp:TabPanel ID="tab2" runat="server" HeaderText="Descriptions">
<HeaderTemplate>Descriptions</HeaderTemplate>

[code]....

View 2 Replies

Winapi - Closing A Modal Popup?

Dec 15, 2009

I want to wait for and close a modal form (a popup) from another application, as soon as it appears. I want to do this from VB.NET, but suggestions in C# should be easily translateable.

I can hard-code the modal popup's caption in my app, since it's long and unique. What I want to do is simulate either the user clicking on the close ("X") button on the form, or a click on the defeault, tab-order 0 button of the form. Either would work.

Maybe I need more info about the modal popup other than the title bar's caption? In any case, it's safe to use it as an unique identifier of that modal form. I also want that code to terminate checking as soon as the first event of closing the popup happens.

I believe it's trivial, but I can't find any ready info on that. Microsoft says I should not send WM_CLOSE to the modal popup, since it will call DestroyWindow() instead of EndDialog(), but to be honest I don't even know what "sending WM_CLOSE" to the "window" means =/

View 1 Replies

How To Edit GridView Inside Of Modal Popup

Dec 1, 2010

I have a gridview that appears in a modal popup that is generated dynamically and is bound to a dynamically generated SqlDataSource. I did this to hopefully take advantage of the gridview's automatic editing capabilities. My problem is that when the edit button is clicked the modalpopup closes due to a full postback in spite of the fact that my gridview is in an update panel. I looked at solutions here and here but neither fixed the problem. I've also tried every combination under the sun regarding the positioning of the ModalPopupExtender in relation to the update panel etc, and have tried changing UpdateMode to conditional as well.

Markup:
<span class="none"><asp:Button ID="btnDummy" runat="server" Text="Dummy" /></span>
<ajax:ModalPopupExtender ID="mpLabel" runat="server" TargetControlID="btnDummy" BackgroundCssClass="modalBackground" PopupControlID="pnlLabels"></ajax:ModalPopupExtender>
<asp:Panel ID="pnlLabels" DefaultButton="btnOk" Style="display:none;" runat="server">
<div style="background-color:#fff;border:1px solid black;padding:7px;">
[Code] .....

View 3 Replies

Asp.net - Textbox In Modal Popup Inserts Duplicate Entries?

Nov 14, 2011

My textbox is supposed to enter one value and enters about 8 of the same thing.

<li class="item">
<asp:LinkButton ID="FeatureButton" runat="server">Feature</asp:LinkButton>
<asp:Panel ID="FeaturePanel" runat="server" CssClass="modalPopup"

[Code]....

View 2 Replies

Asp.net - Adding Textbox To Modal Popup Stopped Allowing INSERTS?

Nov 14, 2011

I have a modal popup that allows an admin to choose from a variety of checkboxes to add features to a specific product. If there is a checkbox that an admin believes should be available but isn't because that feature is not in the database, I have added a textbox so that user can add a new feature to the product.

Once I added the textbox, it stopped allowing inserts. At first it was in the same If Else as the checkbox for each loop, but I have recently changed it so the textbox is in it's own for each loop. I have an underline under the words txtFeature.Text that says Value of type 'Char' cannot be converted to 'System.Web.UI.WebControl.Textbox.'

vb code:

For Each feature As ListItem In cbxAddFeature.Items
If feature.Selected Then
Dim strSQL As String = "INSERT INTO Marketing

[code]....

View 1 Replies

Retrieve GridView Selected Row Command Value In Modal Popup Panel1?

Mar 16, 2011

I have a gridview in webform and a panel1 which I used as a modalpopup control. I wanna show panel as modalpopup per row item select using commandrow of gridview ... There are two controls inside panel1; literal1 and literal2. I want when the item in the gridview is selected by user then panel 1 shows as modalpopup which displays the records from gridview in panel 1 controls i.e literal1 , literal2. I want to retrieve the selected row item from gridview to modal popup panel1 control..

View 1 Replies

Javascript - Button Click Event On Modal Popup, Inside A Grid-view Not Firing

Jun 10, 2012

I have a asp grid with a few columns that bind to data. The last column has been converted to a template-field. In this template-field is a button with a modal popup extender attached to it. Hidden inside this field is a modal popup. This modal popup is used to add a new account. it contains 2 text boxes, drop down lists and buttons("Add" and "Cancel"). When "add" is clicked the modal should close after the inserting of the new account in the code behind.

The Problem: I get the popup to display and load the Drop down lists from the cache, without problem. How do I get the button click event to fire in the code behind. I've tried using a JavaScript function that performs a _doPostBack('btnAddAcc','') but it keeps returning the error "JavaScript error: Object expected". I gathered after about 1 hour on Google that it is because "btnAddAcc' is not found because it is actually within the grid-view cell and can't be directly accessed. Using page methods and ajax calls is a last resort as the company has a strict policy against this and only allowes this after a bunch of paperwork.

The Code:

<asp:GridView ID="gvNEA" runat="server" CssClass="gridA_Orange"
AutoGenerateColumns="False" AllowPaging="True"
EmptyDataText="No transactions with 'Non Existent Account(s)'"

[Code]....

View 2 Replies

Minimizing A Modal Form Minimizes Parent Or Main Application?

Jun 2, 2009

Is it possible to have an application where form1 opens a second modal form (form2) and then allows the user to minimized form2 causing the entire application to minimize to the taskbar.(form2 is never shown in the taskbar) A simple example of this is winzip where a second modal progress window is opened which can be minimized?

View 10 Replies

Set A Messagebox To Popup In Center Of A Parent Form?

Aug 17, 2009

I would like to have my messageboxes popup in the center of the parent form. When I resize and move the parent form the popup messageboxes open center screen. I have tryed searching for an answer but have come up empty. I am programming VB 2008.

View 4 Replies

Jquery - Colorbox- Get Value From Popup (Child.aspx) Page To The Parent (parent.aspx) Page?

Jun 27, 2012

I have 2 pages. parent.aspx and child.aspx. In parent.aspx, i use colorbox and send some value for the child.aspx to popup.

[code]...

child.aspx will popup and shows ASPxGridView base on the value passing from parent.aspx. User will select the data from ASPxGridView. the selected data need to send back to the parent page. I code it in child.aspx.vb page.My problem is how can i get the value from child.aspx.vb and pass it to parent.aspx ?

View 1 Replies

Prevent Popup Toolbox Form From Stealing Parent's Focus?

Aug 4, 2011

how to prevent a popup toolbox window (Form) from stealing the parent Form's focus?I've been told to override CreateParams and use WS_EX_NOACTIVATE (0x08000000) but that does not seem to work (see the code segment shown below). I'm using Show() and not ShowDialog().

Protected Overrides ReadOnly Property CreateParams() As System.Windows.Forms.CreateParams
Get
Dim cp As CreateParams = MyBase.CreateParams

[code]....

View 1 Replies

Asp.net - Pass Cancel Or Update Button Click From Popup Back To Parent Page?

Apr 25, 2012

I have a popup aspx page that receives data from a parent page gridview Edit click. There is a great deal of parsing of data from parent page to pop up as the data is being translated in pop up, then sent back to parent page to be reassembled in the original text block before update.

When the popup passes the data back or is canceled, the parent page gridview is still in Edit mode.I would like to pass the Cancel or Update button click from the popup to the parent page gridview so it can complete the update or cancel event without asking the user to click the corresponding command button link from the gridview edit mode, to Update or Cancel.

UPDATE: There is also a jquery UIBlocker on the Parent page to prevent the user from returning to the page until the PopUp page processing has been completed. Below is the critical code:

PARENT Page:
function parentFunc(a) {
// Unblocks on return from popup page.
$.unblockUI({});

[code]...

Had a problem with preventing the popup from reloading. So there is an if condition in the load event. A dynamic number of controls are built on the popup as literals. So the Page Init event and Page Load event fire on non Postback to rebuild the controls.

View 1 Replies

Passing Values From Modal Form To Parent Form?

Aug 11, 2011

I am trying to pass information to parent form from modal form in vb.net winforms application.

1.) I created a copy of a form and displayed it using following code.

dim f=new frmParent()
f.show()

2.) Depending on conditions a button on frmParent opens a modal child form and asks for some informations. I used following code for that:

dim f = new ChildForm()
f.showDialog()

Both code works fine. When user press saves in child form i need to close childForm and use the user types values in parent form. I know how to close the childform but not sure how to pass info from childform to parent form.

View 1 Replies

Hiding The Child Form Also Hide The Parent Form?

Aug 16, 2010

I have three forms: A, B and C. Upon a button being clicked, A displays B. Similarly, B displays C. Both using the ShowDialog() method.

However when I use the Hide() method (inside a Button Click event) on form C to close it, form B also closes. Why would this be? As far as I can see, it shouldn't be doing this. I certainly didn't write any code to tell it to do that.

[Code]...

UPDATE: I am an idiot. DialogResult was set to Cancel on the button as I'd copy+pasted it from the existing Close button and not realised that property was set

View 3 Replies

Asp.net - Show Ajaxtoolkit Modal Popup Extendar Only If Textbox1.text="show" Esle Do Not Show?

Feb 20, 2011

I have a textbox1 and button1 and panel1 (which is used as a popup control)i want if textbox1.text="show" then modalpopup control whose id is panel1 will be visible on buttonclick event other wise .... modal popup control panel1 will not be shown ...how to do this ? using vb.net ?

View 2 Replies

Control Child Popup Page From Parent Page With Program?

Nov 18, 2011

Using vb.net on an aspx code behind event, is there away to tell from a parent page if the child page popup is open, and then close the child page if it is truly open based on some event on the parent page, like clicking a gridview edit link, again?

View 1 Replies

DB/Reporting :: PopUP Form Refresh Combobox On Parent Form

May 31, 2008

I have a parent form that has a combobox. Whn the form loads I get the data from the db and bind to the combobox. that works fine and here is the code I use in form load to cause this to happen: [code] Now if there is not an Account Type, I have a button that will pull up a small form to allow the addition of an account type. The popup form adds the data back to the database just fine, but I am now trying to get the combobox to refresh its data. So I call a public Sub that is located in the parent form to from the popup form to accomplish this task and I have walked the code and the sub is called and appears to work correctly, but the new data never appears in the combobox. Here is my public sub that i call to try and refresh the combobox on the parent form. [code] But when I go back to the parent form, the combobox is not updated with the new account. How can i get the combobox to refresh from the database with the new data?

View 4 Replies

Close A Modal Form From Who Initiated Modal One?

Feb 25, 2011

I have a parent form (form1), which is calling a second form (form2) as modal.[code]...

No form2 is modal. Closing this form2 from the form itself is clear.But how can I close the form via myform2.close from form1 via an event handler?

View 6 Replies

Access Button Click Event On Modal Popup Button Click Event?

May 14, 2011

my source code in design part is:

<asp:Panel ID="Panel1" runat="server" Style="display: none" CssClass="modalPopup">
<asp:Panel ID="Panel3" runat="server" Style="cursor: move;background-color:#DDDDDD;border:solid 1px Gray;color:Black">[code]......

Ok button click is not accessing click event.

View 1 Replies

Make A Popup Blocker Type Message Box That Pops Up When A Popup Tries To Load A Page?

Dec 2, 2010

im trying to make a popup blocker type message box that pops up when a popup tries to load a page, and it asks The page [URL]is trying to open,open in a new tab?

(label)
No (button) Yes (button)

how would i make a menu appear when i click somwhere on the page,how would i make it recognise a picture, and be able to copy it to a location on the local drive?

View 3 Replies

Parse The URL Of The Desired Popup To The Popup-form AND Show Hints / Tooltips In The WebKit-Component?

Apr 11, 2012

I'm trying to use the WebKit-component ([URL]) in VB with the help of Visual Studio 2008. This is running without problems, except for two following two issues:

1. Hints/Tooltips are not shown (e.g. as there usually will appear one if you stay with the mouse over the Google-logo)

2. If there's a popup-window, I don't know how to get the new desired URL.

[Code]...

View 1 Replies

Silverlight Popup: Call A Method After Popup Is Opened?

Jan 28, 2011

I'm working with a Silverlight Popup control (SL4). I would like to update data shown on that popup every time the user opens it (IsOpen=true) by passing a string and calling a Private method located in the Popup control behind code to fetch updated data.

I was hoping to place code to make this happen in the Opened event of the Popup, but such an event does not seem to exist (even though I found some documentation on it).

View 1 Replies

Wpf - Create New UserControl In Popup Each Time Popup Pops?

Jun 16, 2011

I have a usercontrol that has a popup that displays another usercontrol when the user selects an item from a listbox. When the parent initializes, all the usercontrols initialize.

<Popup x:Name="PopContactLogs" Width="670" StaysOpen="True" AllowsTransparency="True" PopupAnimation="Fade" PlacementTarget="{Binding ElementName=PageCustomerHome}" Placement="Center">

[Code]....

and it just keeps the original data in there. I'd really like to just reinitalize it every time and basically have a new webpart each time.

View 1 Replies

Call A Member Through Its Parent's Type That Shadowed A Parent Class Implementation?

Aug 3, 2011

This is a challenging one that got me stumped while I was coding today. Suppose I am running the Sub Test1() and Test2() and would like to print out the value of the Shadows method of the instance of the object I am passing in to TestCall() (see below - it is clearer) using the following restrictions:

Can't change the contents of Class A, B, and C
Can't change Sub Test1() and Sub Test2()
TestCall() can't have an if, select case etc. statement that tries to figure out the type

[code].....

View 2 Replies

.net - Parent/Child Relationships Failing When Getting Data From Parent Class With Multiple Forms Open?

Jun 24, 2009

I have a main form, and some sub forms, and each sub form can have some sub forms. When I have multiple sub forms open, and I try to get data from the parent form, it returns the data from the wrong parent form.For example I have two instances of Mainform.subform running. If I do something like this in a child form of one instance of the subform. It returns data from the other subform.

dim l = Mainform.subform.listofdata

Edit:I am using visual Studio 2008. Winforms, form designed using designer. In my mainform I am doing this

Protected Friend frmMain as Mainform
frmmain = new mainform

In frmMain I am doing this

Protected Friend frmsub as new Subform'
frmsub = new subform

[code]....

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved