|
that will work even if a user close the page?
|
|
|
|
|
hi
yes
Mohammad Khansari
|
|
|
|
|
for some reason, once the user(in this case, me) close the page, every process stops.
Can you please give me some example, chunk of code to see your idea, please.
Thx in advance, Laziale
|
|
|
|
|
hi
the application pool is always run.
when the process is stopped the secondary thread is working to finish
it's task. when it finish it's task the result must be saved on
application state or database or hard disk
It is only an idea and I have not implement it yet.
hope to help you
another solution:
you can use Ajax and a httphandler(it can be your page) without any
submit and any multithreading.
(I think it is better than previous approach)
Mohammad Khansari
|
|
|
|
|
Hi,
I wish to implement the following behaviour:
Once logged in to my webapplication if the user hits back button on the browser .... log them out.
I am researching a possible solution for this using the "onbeforeunload" Javascript event.
However how does do you request a logout initiated from the client side ?
Any help would be appreciated
|
|
|
|
|
Well, But there are few browsers which doesnt places a server call when back button is hit. Even your ajax request in the page will be invoked but with same parameter.
I am unsure if it actually can be done. onbeforeunload event is generated when you navigate away from the page, like you close the window, you click on any link etc. By this, you cant trap if back is hit or not...
gerrybrennan wrote:
However how does do you request a logout initiated from the client side ?
Just invoke an AJAX request to the server which will remove the authentication variable in the server.(might be in session)
|
|
|
|
|
... or in load event of login.aspx page, just clear the authentication variables! (Session.Remove("Credentials") ? or something like that) ...
And if you want, you can add
Response.AddHeader("pragma", "no-cache");
Response.AddHeader("cache-control", "private");
Response.CacheControl = "no-cache";
Response.Cache.SetCacheability(HttpCacheability.NoCache);
Response.Cache.SetNoStore(); on load event to prevent the Back button of browser and let the user see the last page before the log out... good luck!
|
|
|
|
|
Hi I have a webapplication with many pages.
I wish to put a check in the page_load of the masterloggedinpage to check if Javascript is enabled & cookies are enabled.
Reason being i do not want to place a check on every page.
If they are not enabled I will force a FormsAuthentication.SignOut()
Can anyone help with some suggestions on how to perform this operation ?
Thank you in advance.
|
|
|
|
|
|
Hi !
I need to create the HttpModule that will work not for specific application, but rather for the whole site, like ISAPI filter defined on the Web Site level.
How I can register it without application, and hence without web.config?
Seems to be simple question, but I burned away enough time looking for the answer in the internet (including CP site) with no luck. All examples end up in application and it's web.config.
May be it is evident, and I simply too dumb to see it?
Thanks in advance.
Regards,
Gennady
My English is permanently under construction. Be patient !!
|
|
|
|
|
hi
You should know how the native asp.net httpmodules were registered to
the websites and register your own like them
I think that they were registered in Machine.config file
Hope to be useful
Mohammad Khansari
modified on Thursday, January 7, 2010 3:11 AM
|
|
|
|
|
Hi !
Thanks for your response and sorry for delay - I had no access to the internet.
Yes, this is one of methodes that I thought about. Another is - place the short web.config
to the root of web site. I'm not sure that any one of these methodes is right, so I wanted to
get the "authoritive" answer. I'm new in this field, so when my first HttpModule will fail to
work, I'd like to exclude the registration mistakes. At least.
Regards,
Gennady
My English is permanently under construction. Be patient !!
|
|
|
|
|
My page uses an asp .net menu that is not enabled like this:
|
|
|
|
|
Hi,
You are using it correctly but just one mistake you have made is making the Menu disabled in server side.
Use
<asp:Menu disabled="true"
Rather than
<asp:Menu Enabled="False"
Because when you make a control disable from server side you will not be able to get it from client side.
Also try using getElementById only in place of getElementByIdWithReplaceCheck if it does not work out.
Hope it Helps.
Regards,
Kaushal Arora
|
|
|
|
|
|
<p>Hi,</p><p>Try this: <font face="Verdana">getElementByIdWithReplaceCheck("ctl00_Menu1").visibility= false;<br /></font></p><p><font face="Verdana">hope this helps.</font></p>
April
Comm100 - Leading Live Chat Software Provider
modified 27-May-14 9:00am.
|
|
|
|
|
|
Do the following thing :
step 1 :load file
FileInfo fileinfo = new FileInfo(yourfilePath);
step 2 : open file using jet provider
string strSql = "SELECT * FROM [" + fileinfo.Name + "]";
string strCSVConnString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + fileinfo.Directory.FullName + ";" + "Extended Properties='text;HDR=No;'";
step 3 : load data set
OleDbDataAdapter oleda = new OleDbDataAdapter(strSql, strCSVConnString);
DataTable dtbCSV = new DataTable();
oleda.Fill(dtbCSV);
step 4 : wite to xml
dtbCSV.WriteXml()
|
|
|
|
|
yes u r right, when we are using datatable/dataset.
But i want any other way without using the datatable/dataset...b'coz it will consume much memory...
Thanks & Regards,
Jeneesh k. v.
|
|
|
|
|
|
Hi All,
I want to to develop HTML editor in ASP.net page where user can write his template can make a define his own size own font
For this i m using tinymce but this is giving very weird behavior.
thanks and regards,
Amit Patel
|
|
|
|
|
Amit Patel1985 wrote: For this i m using tinymce but this is giving very weird behavior.
With this amount of information how do you expect anyone to help?
Bob
Ashfield Consultants Ltd
Proud to be a Code Project MVP
|
|
|
|
|
Hi All,
if any one used the FreeTextBox please help me to find out how to enable the print preview.
Thanks and regards,
Amit Patel
|
|
|
|
|
Hi all,
I have a ConfirmButtonExtender that I need to display only if a start time dropdown is later than an end time dropdown. i.e. Start time = 23:00 and the End time = 01:30. I need the ConfirmButtonExtender to display, but if Start time = 13:00 and End time = 14:00 then it should not display. Is there a way to do this in C#?
Thanks in advace for your help,
Lee
|
|
|
|
|
Make Use Of JavaScript..!
Use OnClientClick..!
LatestArticle :Log4Net
Why Do Some People Forget To Mark as Answer .If It Helps.
|
|
|
|