AJAX :: Page Methods Starting New Session?
Jun 29, 2010
I'm using ASP.NET page methods to check for the updates. I'm using inproc sessions and windows authentication in IIS 6. When page is loaded, a session is started. But sometimes when the page method is called it starts a new session(created with current request return true also). Why that might happen ?
View 2 Replies
Similar Messages:
Feb 26, 2011
While Ive seen plenty of examples in PHP, can't seem to find one in VB, I want to know if this is even possible.
I have a page, a session starts on page load (using global.asax) the user may not move from (or interact with) that page for a long while and I dont want to increase the session timeout. When the session times out after say.. 20 minutes, I want to start a new one, without moving from the page.
I also don't want constant keep-alives
I want to do it via another method (timer, button press...)
View 1 Replies
Feb 22, 2010
I am using the Page Methods of Asp.Net Ajax to call the server method by enabling EnabledPageMethods of ScriptManager to "True". Can we return the DataSet using the Page Methods written on server side?
And also I want to know what are the default datatypes that are supported by the Page Methods to return to client?
View 3 Replies
Oct 15, 2010
I have written web methods in code behind and I'm able to call them using PageMethods.(method name) in an ordinary aspx page.
If I'm trying to call the webmethods in a master page using PageMethods.(method name), it is throwing a jscript error pagemethods is undefined.
My code is like this:
[Code]....
[Code]....
View 10 Replies
Oct 20, 2010
I'm having problems with accessing querystring params in my page method. Everywhere I read it says you can access querystrings just fine, but when I try it just returns null, what's the problem?
same problem I found - [URL]
View 14 Replies
Nov 11, 2010
how to access the Page methods through javascript.I kept a breakpoint in PageMethod and it never got a hit.
Am i doing anything wrong here?..
<head>
<title>GlobeLocator Gold Map</title>
<script runat="server">
[System.Web.Services.WebMethod]
[Code]...
View 10 Replies
May 20, 2013
<asp:ScriptManager ID="ScriptManager1" AsyncPostBackTimeout="9999" runat="server"
EnablePartialRendering="true" EnablePageMethods="true"> is set
using a webservice defined at the page level
I am calling the webmethod in javascript as
PageMethods.ItmIdDate(param1,param2, function1)
I get the values of the param in alert, the function is defined but I get error PageMethods is undefined...
Public Function ItmIdDate(ByVal ITMID As Integer, ByVal UserRemark As String) As String
View 1 Replies
Oct 4, 2010
I wish to create a website based on ajax functionality using Master and Content pages.I want to use page method or xmlhttprequest object to check some validations in registration form,which is a content page of my website. Is it possible to work so or is there any other method to do it.
The code I'v written using page method in normal aspx page working fine but it is not working in contnet page.
View 1 Replies
Feb 24, 2011
I have three cascading dropdowns on my web page and they work fine. The issue I am facing is that there are other controls on the page which cause a postback and with each postback the cascading drop downs are being re-populated (service methods are called) which is becoming a performnace issue.
View 1 Replies
Apr 13, 2010
In C#, How do you pass the Session[] and Request[] objects to a method?I would like to use a method to parse out Session and Request paramaters for a .aspx page to reduce the size of my Page_Load method. I am passing quite a few variables, and need to support both POSTand GET methods. For most calls, not all variables are present, so I have to test every variable multiple ways, and the code gets long...This is what I am trying to do, but I can't seem to properly identify the Session and Request paramaters (this code will not compile, because the arrays are indexed by number)
static string getParam(
System.Web.SessionState.HttpSessionState[] Session,
System.Web.HttpRequest[] Request,
string id)
[code]...
View 2 Replies
Mar 18, 2011
I'm writing up a security document and it would be great if programmers in other languages than PHP could chime in on (perhaps the default) way sessions are passed by URL in their language's default session handler.
eg. PHPSESSION=token in PHP
Oh, and if yes does it also use cookies?
View 2 Replies
Sep 15, 2010
I write a simple static method in my web page. How can i access session["id"] into method? I dont have access.For example:
public static void myFunc()
{
Session["id"]= 100;
}
View 2 Replies
Dec 21, 2010
First of all, I'm not a pro on IIS configuration topic.With that being said, I got a website written in VB.NET 3.5 Web Forms. I have a small web service, ASMX, running as a part of this website. One page on the website calls the web service with AJAX (jQuery $.ajax function, post). The server is running Windows 2003 and IIS 6.0. The website and the web service are sharing the same Application Pool.
View 2 Replies
Dec 28, 2010
So it is time to use some pages i have to a master page.I have limited usage with master pages so i will write some concerns here so i could get some answers cuz i don't want to start breaking stuff on xmas days.
Of course i will give it a go on my own but it will be good to know what problems must be aware of before i start.If someone knows of them.
So i have a concern about page transfer.
I do a post and on the page to go to i use "<%@ Reference Page="~/thepage.aspx" %>"
Will this go on the master page or on the page to be transferred to?
Also i had an issue with the below command:
Dim result = CType(Context.Handler, _Default) .
Apparently asp is quite funny sometimes and it has blued out the code saying, eerrr, can quite remember but something like the page cannot be found or something.Haha.Very funny.I copy pasted all the code to a new page, deleted the old one and renamed and it worked.So if this happens if i embed the page to a master page, will the copy paste technique will work again or i need to modify the master page also?
Another concern is about the daypilot calendar(Gary? ) it's a heavy ajaxed page using panels,:UpdatePanels,ajax,javascript,server manipulation,SqlDataSources etc. I don't expect most of you to know this but will there be a problem by putting the daypilot design interface inside a master page.This page is so complex that i prefer not to use it inside a master page if i suspect that something is wrong.
Paypal concern.I have read somewhere that you cannot use 2 form tags and master page will give errors.However my approach is using a StringBuilder and doing AppendFormat to finally create an iconic form.So has anyone tried this to a master page?Will it work.
Viewstate.I use viewstate encryption when i use viewstate.Will it work on a page inside the master page?
View 2 Replies
Mar 26, 2010
My main report is about half of a page long, subreport contains a table and its length depends on how many rows the table has. But even when a single row, subreport jumps to second page. How to prevent it?
View 5 Replies
Jun 15, 2010
I have an aspx page that has all its controls inside the scriptmanager and update panel.
I want to send the user to sessionexpired page after 20 mins of inactivity.
For this, I am writing the below code on page_load
Response.AppendHeader(
"Refresh", Convert.ToString((Session.Timeout * 60) + 10) &
"; URL=SessionExpired.aspx")
But the page is going to sessionexpired page after 20 mins even if the user is working on the page.
I think since I have all my controls in an update panel it is not doing a complete postback and hence the session object is not getting refreshed.
View 1 Replies
Mar 12, 2010
I have a gridView and on the DataBound event I am assigning a Session variable from one of the gridview results. This session is then used to determine if certain nodes in a menu are visible. One problem is that when the session variable is assigned, the menu is not updating, until either I refresh the page manully in the browser or move to another page.
View 3 Replies
May 7, 2015
How to open a popup image on page load in asp.net ? and can its possible that when i close the popup it should not open whan the session value is not end.
View 1 Replies
Apr 9, 2010
Is it possible to call usercontrol methods/events using MSAJAX. I wanted to update my usercontrol by calling one of its events when a property from its parent page changes.
View 2 Replies
Aug 16, 2010
I have an extension method as follows:
public static class PageExtensions
{
public static int GetUserId(this Page targetPage)
{
var user = Membership.GetUser(targetPage.User.Identity.Name);
return (int)user.ProviderUserKey;
}
}
Now in a page I need to use this method in a static WebMethod, so I have added another 'extension method' to PageExtensions:
public static int GetUserId()
{
return (int)Membership.GetUser(HttpContext.Current.User.Identity.Name).ProviderUserKey;
}
and I call it as follows in my WebMethod: PageExtensions.GetUserId()
View 1 Replies
Jul 23, 2010
public class CacheHelper { /// <summary> /// Removes object with the specified key. /// </summary> /// <param name="key">The key.</param> [code]....
I have this methods for caching..I need to change this methods to use in aDictionary<string,object>
How do I need to change this code Because I am new to asp.net I am still learning..
View 12 Replies
Apr 4, 2011
I am having problem in session time out in Asp.net with Ajax Call.Once the session times out,when a control calls asynchrous this is notredirecting to login page.(I am using forms Authentication)In the same page if i try to redirect(in Preinit) to login page if session expired..the login page appears with the previous page(because of the ajax call).Please let me know the way to redirect to the login page when the session time out and when a ajax call is made.
View 1 Replies
Jan 14, 2011
There is one master page in my application. Left side it display menu and right side there is a Iframe where page will be displayed when user click on menu. so entire page will not be refreshed only Iframe will be refreshed.
Everything is working fine for me but I am facing problem when session expire, my loginUrl page display inside Iframe so user is able to see left menu.
I am thinkin that LoginPage should be display in main screen instead of Iframe.
My web.config is as below.
<authentication mode="Forms">
<forms loginUrl="Login.aspx" defaultUrl="Default.aspx" protection="All"></forms>
</authentication>
View 1 Replies
Jul 22, 2010
Below is some code. The save() method was pre-existing. I added the saveRanking() method. When I walk through the code, it hits the method, but then it just bails out of it. No exception (that I can see). Do I need that function(data) part?
Code:
function save() {
$.post(
"/Applications/SaveStatus",
[code]....
View 1 Replies
Feb 28, 2011
I am trying to use some page methods on an aspx page. I've done this several times before in other asp.net applications and never had issues until now. I believe that maybe the issue has something to do with the methods be exposed to POST but I'm not entirely sure. Everything on the page loads correctly then once it attempts to make an ajax call rather than hitting the "test" function, the page tries to reload and the page_load method is called again. I chacked the URL string on both cases when page_load is called and both are correct. I am suspicous that there is some need to do with the web.config but I'm not sure what. The application is close to 10 years old and has been grandfathered up all the way to ASP.net 3.5. On another note, I can hit asmx functions perfectly fine its only page methods that seem not to work.
Imports System.Web.Script.Services
Imports System.Web.Services
Partial Public Class CustomDataFilter[code].....
View 1 Replies