Dear Evan, <englund.evan <at> epamail.epa.gov> writes: > > > Hello, > > I haven't been able to find an example for the second case below -- or > perhaps I didn't recognize it when I saw it. > Is there a value for x such that svalue(x) will return "bbb", either by > itself or as part of an array? Or do I need to do something else > entirely? > (R2.5.1; Windows XP) >
You will need to store the widget. See below. > > ### Case 2: this makes an identical window & widget, with "b" > replacing "a" > > ### but does't return the value > > wtesta = gwindow("wtestb",visible=TRUE) > > wtestb = glayout(visible=TRUE,container=wtesta) > > wtestb[1,1]=gedit("bbb",container=wtestb) > > print(svalue(wtestb[1,1])) the glayout container doesn't work that way. You don't get a [ method, just a [<- one. Try something like this instead to store the widget: wtestb[1,1]=(bbb <- gedit("bbb",container=wtestb) ) print(svalue(bbb)) --John > Evan Englund > U.S. EPA > 702-798-2248 > > ______________________________________________ > R-help <at> stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > > ______________________________________________ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.