Error in use of "gwindow" and ".First" function

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Error in use of "gwindow" and ".First" function

mrzung
Hi,

I saved an image and planed to open it whenever I want to load it.
However, when I open it, It doesn't work.
The code is following, and saved it as an image.

.First<-function(){
        require(tcltk)
        require(TeachingDemos)
        library(gWidgetstcltk)
        options(guiToolkit = "tcltk")
        win <- gwindow("Don't worry", visible = FALSE)
}

Error message is following,

Error : .onLoad failed in loadNamespace() for 'tcltk2', details:
  call: .tk2dde.require()
  error: Unable to find the 'dde' Tcl/tk package!
Warning messages:
1: In tclRequire("dde") : Tcl package 'dde' not found
2: In tclRequire("dde", warn = TRUE) : Tcl package 'dde' not found
Failed with error:  ‘package ‘tcltk2’ could not be loaded’

Loading required package: gWidgetstcltk
Loading required package: tcltk2
Error : .onLoad failed in loadNamespace() for 'tcltk2', details:
  call: .tk2dde.require()
  error: Unable to find the 'dde' Tcl/tk package!
Warning messages:
1: In tclRequire("dde") : Tcl package 'dde' not found
2: In tclRequire("dde", warn = TRUE) : Tcl package 'dde' not found
Failed with error:  ‘package ‘tcltk2’ could not be loaded’
Loading required package: gWidgetstcltk
Loading required package: tcltk2
Error : .onLoad failed in loadNamespace() for 'tcltk2', details:
  call: .tk2dde.require()
  error: Unable to find the 'dde' Tcl/tk package!
Failed with error:  ‘package ‘tcltk2’ could not be loaded’
Warning messages:
1: In tclRequire("dde") : Tcl package 'dde' not found
2: In tclRequire("dde", warn = TRUE) : Tcl package 'dde' not found

How can I solve the problem?

Thanks.