I have a webform with this event procedure:
Private Sub Page_Unload( _
ByVal sender As Object, _
ByVal e As System.EventArg s _
) Handles MyBase.Unload
Logger.Logout(U ser.Identity.Na me)
End Sub
Logger is my class that has methods for putting a username into a database
table when they login, and removing the entry when they log out.
So, in the implementation above, I want the code to log them out when they
surf off the page. But in stepping through it in the debugger, It's hitting
this event procedure when they *enter* the page, and does *not* hit it when
they *leave*
What gives?!?
--
Peace & happy computing,
Mike Labosh, MCSD
"Escriba coda ergo sum." -- vbSensei 1 1334
Is your unload event wired up correctly? Does it ever fire - in other words?
A correctly wired page unload event fires when the page unloads
--
Regards,
Alvin Bruney - ASP.NET MVP
[Shameless Author Plug]
The Microsoft Office Web Components Black Book with .NET
Now available @ www.lulu.com/owc, Amazon.com etc
"Mike Labosh" <ml*****@hotmai l.com> wrote in message
news:%2******** ********@tk2msf tngp13.phx.gbl. .. I have a webform with this event procedure:
Private Sub Page_Unload( _ ByVal sender As Object, _ ByVal e As System.EventArg s _ ) Handles MyBase.Unload
Logger.Logout(U ser.Identity.Na me)
End Sub
Logger is my class that has methods for putting a username into a database table when they login, and removing the entry when they log out.
So, in the implementation above, I want the code to log them out when they surf off the page. But in stepping through it in the debugger, It's hitting this event procedure when they *enter* the page, and does *not* hit it when they *leave*
What gives?!?
-- Peace & happy computing,
Mike Labosh, MCSD "Escriba coda ergo sum." -- vbSensei This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Harry J. Smith |
last post by:
I have written a Visual Basic program that does a long calculation and
writes the results to disk as it runs. If I click the Close button the
window closes but the program keeps running. How can I get the program
to recognize that its window has been closed and quit running?
-Harry http://home.netcom.com/~hjsmith
|
by: razheev |
last post by:
Hi,
I have a Table which contains 1 million rows. I want to do an unload of
the table and do some massaging (tranforming) of data and do a load to
a different table where the column attributes are different.
My question is
1) What options should I use to do a unload so that the unload is very
fast using Platinum Fast unload. The table has many columns which
defined as VARCHAR.
2)Is there a provision to convert the column values from...
|
by: Lauren Hines |
last post by:
Hello,
I have read numerous post stating that the only way to unload an assembly
(DLL in my case) is to create a separate AppDomain, load the assembly, then
unload it by calling AppDomain.Unload.
When trying to delete the DLL file I get an exception that access is denied.
When trying to copy over the DLL file, I get an exception that it is being
used by another process.
|
by: Wal Turner |
last post by:
Hi there. There are various snippets on forums regarding issues with
AppDomain.Unload and how it just doesnt work.
Fortunately, I got it working with the base case, after much fiddling.
Consider this 5 line program:
AppDomain domain = AppDomain.CreateDomain("MyDomain");
domain.CreateInstance("TempDLL", "TempDLL.Class1");
MessageBox.Show("try deleting file now"); //cant delete file
AppDomain.Unload(domain);
|
by: brianbender |
last post by:
I am trying to load and unload assemblies dynamically and call methods
and properties when loaded into an Appdomain
I can load assemblies all day in the current AppDomain without
references and without interfaces if need be. But try as I may they
will ot unload. I have been working on this problem for weeks. I have
seen other apps using Remoting but I know there has got to be a way to
create a child AppDomain and reference obkect via...
| |
by: hal |
last post by:
I have an application that includes an activex component
that consumes resources that must be released when the a
page is unloaded.
Toward this end I subscribe to the unload event of the
body of my page in javascript.
However, if I turn on smart navigation, any button that
does a server.transfer fails to fire the javascript unload
event.
|
by: Hal |
last post by:
My most sincere gratitude to anyone who can help me work
around this!
I have work that needs to be done in javascript on the
client whenever a page is unloaded.
To this end, I subscribe to the unload event (client side
not server side) of the <body> HTML element through
javascript.
|
by: Gauthier Segay |
last post by:
Hello,
I've an application where all my pages implement a PAGE_CODE string
property, this property is stored in HttpContext.Current.Items.
In some page, I must persist data in session while the user perform
operation on this page (postback navigation based). I also need to
clean up the session data when the user leave the page (by a anyway).
My question is about the Unload event, is it safe to use the unload
|
by: Timofmars |
last post by:
I'm try to Unload DB2 data from a table into a record sequential file
on NT. I can an unload on Mainframe, but it doesn't seem to be an
option in NT.
In NT, all I can do is export/import. I can do a Load too, but not an
Unload. I just want the only the data from the table in a record
sequential file. Export seems only to give options to have a delimited
line sequential file or a record sequential file where the data is
preceeded by...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |