<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=us-ascii" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.18999"></HEAD>
<BODY>
<DIV><FONT size=2 face=Arial>
<DIV><SPAN class=698563309-18012011><FONT size=2 face=Arial>Dear
Users</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial></FONT></SPAN> </DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2 face=Arial>I have a
gridpanel with a WMSCapabilitiesStore in a windows that is fired when
a button is pressed. At the moment it works fine only the the first
time I push the button. The problem is that when I push that button
again I get exactly the same grid and store, though I change the url
of WMS store every time. How can I get the grid and its store
updated with new data?</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2 face=Arial>Here is the piece of
code I use within a function:</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial></FONT></SPAN> </DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial>###</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2 face=Arial>function myfunc()
{<BR>
var uid =
Ext.getDom('userid').title;<BR> win
= new
Ext.Window({<BR>
width:
400,<BR>
height:
400,<BR>
layout:
'fit',<BR>
closeAction:
'destroy',<BR>
closable:
true,<BR>
});<BR> <BR> <BR> var
url="<A
title=blocked::http://localhost:8080/geoserver/wms?service=wms&version=1.1.1&request=GetCapabilities&namespace
href="http://localhost:8080/geoserver/wms?service=wms&version=1.1.1&request=GetCapabilities&namespace">http://localhost:8080/geoserver/wms?service=wms&version=1.1.1&request=GetCapabilities&namespace</A>="
+ uid;<BR> mystore=new
GeoExt.data.WMSCapabilitiesStore({}); <BR>
mystore.proxy.setUrl(url);<BR>
mystore.proxy.setApi(Ext.data.Api.actions.read,
url);<BR>
mystore.reload()</FONT></SPAN></DIV>
<DIV> </DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial>
mygrid=new
Ext.grid.GridPanel({<BR>
//title: "Available
Layers",<BR>
region:
'center',<BR>
store: mystore,</FONT></SPAN></DIV>
<DIV><SPAN
class=698563309-18012011>
<FONT size=2 face=Arial>.......</FONT></SPAN></DIV>
<DIV><SPAN
class=698563309-18012011>
<FONT size=2 face=Arial>.......});</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial>
win.add(mygrid);<BR> win.doLayout();<BR> win.show();</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial>}</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial>###</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial></FONT></SPAN> </DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2 face=Arial>Any
advice?</FONT></SPAN></DIV>
<DIV><SPAN class=698563309-18012011></SPAN> </DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial></FONT></SPAN> </DIV>
<DIV><SPAN class=698563309-18012011><FONT size=2
face=Arial>Manouchehr</FONT></SPAN></DIV></FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV></BODY></HTML>