hello, I'm trying to disable an tkentry widget with a tkcheckbutton using an R function via the command flag. but I get an error regardding copy of the pointer: 'externalptr' which properly way to avoid this?
thanks, cleber #################### > library( tcltk ) > tp <- tktoplevel() > > chk <- tclVar( TRUE ) > statusentry <- tclVar( "normal" ) # normal, disabled > anystring <- tclVar( "anystring" ) > > chebut <- ttkcheckbutton( tp, variable=chk, text='Save with new name: ', onvalue=TRUE, offvalue=FALSE, + command=function(...) ifelse( as.numeric(tclvalue(chk)), + tkconfigure(ent1,'-state','normal'), + tkconfigure(ent1,'-state','disabled') ) + ) > tcl( 'pack', chebut ) <Tcl> > > ent1 <- ttkentry( tp, textvariable=anystring, state='normal' ) > tcl( 'pack', ent1 ) <Tcl> Error in rep(no, length.out = length(ans)) : attempt to replicate an object of type 'externalptr' > --- Este email foi escaneado pelo Avast antivĂrus. https://www.avast.com/antivirus [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see 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.