GoWeb View Refresh


- I am using the latest GoWeb and VS2008.

- I have a list of items on the page (like a menu). When I click any item, I need to (re)draw its’ corresponding GoView diagram, in Ajax style, no full postback.

- I wrote a method (DrawView) that creates the diagram.

- If I call DrawView in the PageLoad() then the view renders nicely.

- If I click an item in the list mentioned above, DrawView gets called but the view is not (re)drawn until I click on it!

Can you please tell me where I go wrong? Thanks!



Can you add your company email address to your profile? thanks.

It sounds like your DrawView is on the server side? What you need is some script on the client side to trigger the refresh.

Read through the GoWebIntro section on client side event handling and the section after that on Server-side event handling. It sounds like you need some sort of goAction call to update the GoView. (the “request” goAction is there for your use)

Hi Jake,

Thanks for you answer.

I updated my email and I will look at the document. And you are right, the DrawView is a server side method.

BTW, does any of the samples implement such Ajax refreshing?



A lot of our demo have things like a button that deletes a node or selects all the nodes, and those all work via the builtin goAction requests. I don’t see any of our samples that use the “request” keyword though.

Hi again,
I think I found a temporary solution to my problem, at least until I understand the goviewWeb a little better. The page has a scriptmanager. After calling my server side DrawView method, I add the following script to the scriptmanager (sm):
//server side call
sm.AddScript("clientRefreshGoView('" + theViewControl.UniqueID + "');");
and my javascript function on the client side is:
function clientRefreshGoView(imgID)
setTimeout('goPost("' + imgID + '", "");', 250);
This does the trick. If I call goPost without the timeout, the page gets into an postback loop.