package My::Tmain; sub new { #somewhere... $self_>{_TMAIN_}=Win32::OLE->new('mynifty.application') or barf('badly'); #... bless $pkg $self; } #override something sub foo { my $self=shift; my $res = $self->{_TMAIN_}->foo(@_); munge($res); } #elsewhere sub AUTOLOAD { my($self,@args)=(@_); my($cmd); ($cmd=$AUTOLOAD)=~s/.*:://; return if $cmd eq 'DESTROY'; # should not even be called { #this may be bititing toma... no strict 'refs'; # this does the delegation hokey dokey $self->{_TMAIN_}->$cmd(@args); } } #in another file use My::Tmain; my $t= My::Tmain->new(); $t->foo(); # calls the overridden method $t->bar(); # autoloaded