Suppose I have a web application which accepts a small amount of data from the client (so the data transfer is not an issue), then performs some very lengthy operation (minutes or tens of minutes) on the server, and returns the result back to the user. My question is - what is the preferred method of dealing with long requests? If I use regular postback, the browser will wait for the response and time out prematurely. Increasing the timeout is not a solution, because I do not want the browser to get stuck and seem unresponsive for so long.
One way I thought of is running the time-consuming operation in another thread. This way the server response is sent immediately, so there is no timeout problem. Then I use periodical page refresh to check if the thread finished its work - it displays either "Please wait" on each negative check or "Finished" with the results. The drawback of this approach is that the time intervals in which I check if the work is done are constant (say 10 secs), so even if the work happened to be very fast (finished immeditely), the user has to wait for at least 10 seconds before the first check requst is sent. Is there any way the server itself can inform when the operation is finished?
Any help regarding this matter is appreciated, I suppose this must be a well-known issue so I'll be happy if you just point me the right way.
Place a application state value at the end of the process(long execution)
check if there is a entry in AppValue, If it is so then the process should be completed. and take the user to corresponding page
1. I have a Virtual Dedicated Server.
2. I am getting "Unable to load DLL 'LCE.dll': Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))" where LCE.DLL is a C++ dll.
3. I have .NET dll that access the C++ dll.
The error occurs when I try to call a function in the c++ dll.
//__declspec(dllexport) int __stdcall siv(LPWSTR inbuf, int seed, bool div) C++
public static extern int siv([MarshalAs(UnmanagedType.LPWStr)]string outbuf, int x, bool b);
I am pretty certain that it is NOT the dll but the permissions on the bin directory of the web site, I have tried a number of things to give the permissions to execute the dll but nothing has worked so far.
Does anyone know or point me in the direction where I can resolve this issue
I am looking for a solution to a Java Script question. My question is this, I have a gridview, and in this gridview I have a column, which I use as a flag. The gridview itself is dynamically added to a user control and then to the page. What I would like to do is to use Java Script to hide this column, but I do not know how to do this. Unfortunately, I cannot use code behind, because of the gridview being dynamically added.
Also, I have one further question, I already have some Java Script code that can hide some of the rows based upon the values in my column when a button is clicked. What I want to do is when the page is loaded for the first time, to hide some of these rows, and to use the button in reverse to reveal them again. How do I achieve this?
I just had a quick look at this, and I am slightly confused as to how I can use JQuery to hide the rows when the page is first loaded; then to use a button show them, or hide them based on a click. Please explain.
This script will run when the page is loaded and hide any TR element with the class hidden. It will also hook up the click event of the button to show all TR elements with the class hidden when clicked.
Yes, I had a brief look at the article, and I got the general idea. You to excuse my ignorance, but I have never used JQuery before. So, it take me a few days to get use to it.
What is happening is that when I add my gridviews to these nested panels, the panel is just getting larger, the scroll bars are not scrolling, in other words the panels are stretching rather than their height staying fixed.
Hi, i created a simple web application in which App_Data folder contains .mdf and .ldf files. When i try to publish this application i am getting below error.
"Error 1 The process cannot access the file 'D:\Projects\SqlTest\App_Data\MyTestDB.mdf' because it is being used by another process."
i added button into gridview at designtime in first column.
after running the application if gridview get populated with data.
suppose it contain 4 rows.
if user click on button of 2nd row,i want show the message that you clicked 2nd row.
i.e. according to clicking of button i want to show the message of which row was clicked.
but how can i identify which button was clicked....
please, help me....