.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

How do you insert a google map into an ajax updatepanel?

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

I have built a site that I am using google maps on.  The default page has a google map with info windows containing links and all works great... until a user clicks on the link in the info window.  Doing so takes them to a community page that I have built.  On this community page, I have an ajax update panel that has 2 panels nested inside of it with the visibility set for one to be on and the other off.  The default panel shows community photos, and the second panel I want to show the google map and common directions to the community.  In testing, my buttons to switch the visibility of the panels works great as it should without postback, but when I try to add the map to its panel, it does not show up.  I am new to ajax as well as google maps and I'm not sure why the same code would work fine on my default page but not the community page.  The only obvious thing I can assume is because the community page map is in an update panel.  

How do you insert a google map into and ajax updatepanel and have it work correctly?  Many thanks in advance. 

View Complete Post

More Related Resource Links

UpdatePanel is not a known element - message when upgrading to 1.0 ajax


It worked on one of my old pages.  I change the web.config, renamed all the <asp.

On some aspx page it doesn't recognize the updatepanel.  It only does on one page.  If I create a new aspx page with a different name - then it works.

Should I just create a new web project ajax - then copy all my code into there?  Or is there a way to get those old pages to recognize the new ajax controls?

Insert into SQL Server with ajax file uploader


I am getting error in here 


Incorrect syntax near '987'

987 is where i put clientname.text

        Dim objCmd As New SqlCommand("Create Table " + clientname.Text + "(name Varchar(50), event Varchar(50), date1 datetime, username Varchar(50), password Varchar(50), " + strCommandText + ")", objConn)

        objCmd.CommandType = CommandType.Text

        Dim objConn2 As New SqlConnection("Data Source=dddd.db.2.hostedresource.com; Initial Catalog=mrpoteat; User ID=xxxxx; Password=xxxxxx;")
        Dim strCommandText2 As String = ""
        For index2 = 1 To Attachments1.Items.Count Step 1
            If String.IsNullOrEmpty(strCommandText2) Then
                strCommandText = "@pic" + index2.ToString()

AJAX - Insert to SQL using ASP


Hello Everyone,

I have run into a brick wall in my test development unfortunately and am not sure where to go from here. What I am trying to do is work up a test set of AJAX code that does the following ultimately.


1) Select Statement to load information for a selection within a dropdownlist (AJAX Database example on W3Schools is similar, just with a SQL connection as opposed to Access)

2) Insert Statement where a user types in information and submits it to the ASP page that recognizes it and creates the appropriate insert statement into SQL (This is where I am having the issue) 

3) Update Statement where a user selects something from the dropdownlist and it pre-loads it within the textboxes (previously used for creating new inserts) so that they may be altered and saved (effectively sending to the ASP page the needed update information).


At the moment, I have managed to get the connection to the ASP page and the parameters are loaded (as to whether or not the ASP page is reading them, however, is something I am not sure of)



ASPX Source

<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="TestForm.aspx.vb" Inherits="Ajax_Test_Database.TestForm" %>


Insert, Update, Delete with ajax


I'm kind of new to ajax. I normally just use  the canlendar and some popup stuffs.

i'm wondering what is the practice to doing Insert, Update, and Delete on  GridView/FormView with ajax.

Is UpdatePanel the best thing i can use it with Insert, Update, and Delete?

Ajax Nobot, updatePanel on firefox


Hi guys,

I encounter a very strange problem and hope someone could help me. I have a content page in which a nobot control is used to prevent any robot guessing. There is an updatepanel used to hold all the input fields, enter button and the nobot control. Whenever I finished filling out the form and pressed enter button, an invalidbadresponse will come out. This problem doesn't appear on IE, Chrome but on Firefox. I used firebug to trace the problem and then i found that 2 posts were submited. 1 is aborted and 1 is successfully sent. The most wired thing is, when i fired the webpage on debugger mode from visual web developer (http://localhost:<port> ), firefox can validate it without a problem. Once I copied the page to my website ( http://www.mySite.net/ ), such invalidbadresponse comes out. Then, I tried to remove the updatePanel and now only 1 post is sent and no more invalidbadresponse is shown. Therefore, I guess the problem is between the mechanism of nobot and updatepanel. Could anyone know what happens behind and what I could do to solve this problem ?

My challenge is from the internet:

    Protected Sub CustomChallengeResponse(ByVal sender As Object, ByVal e As AjaxControlToolkit.NoBotEventArgs)

AJAX UpdatePanel Memory Leaks in IE.


After researching why a page I have using an UpdatePanel to perform a refresh every 15 seconds was using up piles and piles of memory over time, I discovered that this is a "well-known" issue with the UpdatePanel not cleaning up properly in IE (some issue with reference counting in COM interop or some such).  UpdatePanel does not seem to have this issue in Firefox (haven't confirmed the issue in other browsers).

If this is a "well-known" issue, two questions:

Is there a "well-known" workaround to this?  I know that a full-page refresh will cause the memory to be cleaned up, but some pages may be up for a long time and I don't want to interrupt any user interaction with the page that may be going on.  I will if it is required, but it is a sloppy, sloppy UI kluge... you know, one of those "as a self-respecting coder I hang my head in shame at what I have wrought" kind of kluges.

Is there any effort being made to fix this?  I've looked about, however, most articles on this do not make mention of even MS acknowledging bug status for this while I've seen many telling me why this is an issue, and how it's a "design" thing.  I hear IE9 is supposed to take care of this... I guess what you'd call a non-issue, but it will only be available to

refresh listbox on updatepanel ajax control tool kit


Hi all, 

i have a dropdownlist and a listbox inside an update panel. I populate the listbox with a selected value of the dropdownlist and works ok. The problem is when delete an item from the listbox because does not the refresh of the listview and still to watch me the deleted item. 

how can i do the refresh?

pd: i am using framework 2.0

thx in advance!

Javascript allert inside AJAX UpdatePanel not working


I am having problems with alert box not popup when I'm using AJAX UpdatePanel. The following is what I have and it's not working.

1    ClientScriptManager csm = Page.ClientScript;
3    if(!csm.IsStartupScriptRegistered(this.GetType(), "winPop"))
4    {
5    	csm.RegisterStartupScript(this.GetType(), "winPop", "alert('Update is successful');", true);
6    }

I have to stress that the reason why it does not work is because I'm using AJAX UpdatePanel. If I turned off the AJAX UpdatePanel then it works perfectly. So does anyone have solution to go around this AJAX UpdatePanel issue?

UpdatePanel don't work with Google Chorme or Mozilla Firefox.


Hi I am using update panels with Update mode conditional in by aspx page. The page is functioning properlly in the IE.8.0 but the page content is not posting when i open it in the Google Chrome or Mozilla Firefox.

FYI I am using Update panels for drop down lists and buttons and in the triggers also i am using similar controls

Pls can you suggest a way to get this out.



Efficient use of Ajax Updatepanel



I have one query, as i have read somewhere that just using updatepanel on your page and placing some controls inside that doesnt help you to improve performance of your web application, since in this case although its a partial postback it goes through all the page events and generate same amount of data in request and response as of created in normal postbacks.

Efficient use of Updatepanel is to call webmethod through javascript for associated actvities.

Can anyone explain me this bit more, if it realy helpfull then how to use it in application..?

Any kind of help will be appreciated








AJAX UpdatePanel and frames



I am new AJAX. In my webpage I have two frames on on the top for the menu and so on, and one on the button which have the content.

I have a buttom on the upper frame. which I included in the AJAX UpdatePanel trigger. The problem now is that the result page displays on the same frame (the upper). I have target frame set to ContentFrame, so it worked fine before using the update Panel. Now the question: Is there any solution so I can force the target to be another frame than the one which has the UpdatePanel.

Thanks for help. 

ajax - Nested Datalist in Updatepanel



I need to input nested data (data entry) and i am using datalists for the same. The details include many details and I am managing the same using controls for each in information.

The parent datalist can have max 20 rows with 7 rows in each child datalist. I tried to bind the datalists with max rows, due to which the rendered page size was almost 12MB and it took more than 2 mins to load.

Alternative to this, I put the parent datalist in updatepanel and bound it to one row initially.  Onclick of add button, i implemented an asynchronous postback to add new row to the parent datalist datasource and update the updatepanel to display the datalist.  The new row is displayed properly in datalist, however it gets reset to original datalist after some seconds.

I have no clue about the reason for it. Please help me to resolve the above issue.


Ajax Controls - ComboBox inside updatepanel




I have a web part which has an updatepanel with variuos panels.

When i add a combobox to a panel which is not shown to begin with but then is set to visible = true, the combobox erros and is not displayed correctly.


If i have one combobox already visible and working fine, then the others are OK - but thats not a solution.


How do i have a combobox inspde a hidden panel and then show it without having to rebind the whole page.




copy value from one textbox to another inside UpdatePanel with AJAX CalendarExtender


I have a calendar extender tied to a textbox.  When I select a date from the calendar, it displays the selected date in the textbox.  When I click a submit button, it passes no value.  Any ideas on why the textbox doesn't store the value from the calendar?

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If Not IsPostBack Then

            If txtPickUp.Text = "" Then
                txtPickUp.Text = Date.Today
            End If
            If txtDropOff.Text = "" Then
                txtDropOff.Text = Date.Today
            End If

            btnSearch.Attributes.Add("onclick", "return ConfirmL();")
        End If
    End Sub


          <asp:TextBox ID="txtPickUp" runat="server" ReadOnly="true" Width="75px" />
         <asp:CalendarExtender ID="CalS" runat="server" TargetControlID="txtPickUp" PopupButtonID="txtPickUp" />


C# Ajax Updatepanel AsyncPostBackErrorMessage



I currently have a method in a base page that takes care of any errors that are thrown - it gets the error message, and the page it came from, writes it to the DB, and redirects to a custom Error page


void Page_Error(object sender, EventArgs e)
        /// <summary>
        /// Get Error & Page Name - Write to DB
        /// </summary>
        Exception ERROR = Server.GetLastError();
        string PAGE_NAME = base.Request.ServerVariables["SCRIPT_NAME"].ToString();
        Utility.ErrorLog(PAGE_NAME,Convert.ToString(ERROR), "", "", "", "");



Microsoft AJAX CDN

Content delivery networks (CDNs) are composed of "edge cache" servers that are strategically placed around the world at key Internet network points. These "edge cache" servers can be used to cache and deliver all types of content - including images, videos, CSS and JavaScript files.

Using a CDN can significantly improve a website's end-user performance, since it enables browsers to more quickly retrieve and download content. For example, instead of having a browser request for an image traverse all the way across the Internet to your web server to download, a CDN can instead serve the request directly from a nearby "edge cache" server that might only be a single network hop away from your customer (making it return much faster - which makes your pages load quicker).

AJAX GridView Checkbox Select All in ASP.Net

In the previous article GridView Select Multiple Rows you learnt the multiple row selection in GridView control. Here you will get the C# code sample to select all the gridview rows using single checkbox server control. You can highlight the selected rows with different color and Font state Bold. If you want to use the selection values on different ASP.Net
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