Handling Event To Cause A PostBack

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



All,

First a little information...
I have a class library that was developed for a GUI application that I
am trying to get to work on my ASP.NET application. The library
essentially is used to query a SQL database. It build the SQL Select
statement based on specified criteria and submits it to the database.
The statement is run on its own thread and when results are returned,
it fires an event, passing a dataset of information as one of the
parameters. In a GUI app, I simply handle the event and display the
results of the dataset.

Here's my problem...
I have a button on my ASP.NET form that instantiates the query class,
defines the criteria, and calls execute (method off the query class).
Because the execute is run on its own worker thread, execution
continues and the button thinks it is done. It appears to be executing
a postback as I see the page be "refreshed". However, when the
query.Execute is done, an event gets fired, which I am handling in a
method that assigns the dataset to a datagrid and I call databind. The
grid, however, is never displayed. It appears that a postback or
something is needed to refresh the page. How can I get this to work?

I am new to ASP.NET development so I hope this makes sense.

Your help is appreciated!

Dave Wurtz

.



Relevant Pages

  • Moving a time-consuming task out of the event-dispatching thread
    ... I have constructed a GUI with a JButton and a JTextArea. ... When the JButton is pressed I want to execute a method that reads ...
    (comp.lang.java.gui)
  • Re: Handling Event To Cause A PostBack
    ... building the http response, sends it to the client and ceases to exist. ... I simply handle the event and display the ... and calls execute (method off the query class). ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: How to change JPanels?
    ... I call a SwingWorker's execute method. ... After that method call I can call another method which updates a gui ... No, *you* create the SwingWorker. ... been writing Java for years but I'm new to the gui. ...
    (comp.lang.java.help)
  • Re: Execute function when GUI is closed and timer function in GUI?
    ... As I am closing my GUI, I would like to execute ... some cleanup functions. ... % --- Executes on button press in btnExit. ...
    (comp.soft-sys.matlab)
  • Re: How to append to textarea immediately?
    ... cp.add (new JScrollPane(textArea)); ... Construct the first part of your GUI on the EDT as shown in the example, up to where you append "Begin Counting" to the text area. ... It'll execute long tasks "in the background" more or less automatically for you, then run a foreground process on the EDT when it's done. ... protected Object doInBackground() ...
    (comp.lang.java.programmer)