$frame->DragAcceptFiles(1); EVT_DROP_FILES( $frame, \&ondrop ); sub ondrop { my ($self, $this) = @_; Wx::DropFilesEvent::GetFiles($this); our $dropfile = $this->GetFiles(); extract($dropfile); # or i can assign a button to do the subroutine :) #print "$dropfile"; <----prints the filepath/name }