You might want to look at the CGI::Application POD (and the CGI::Application HomePage). This will explain how to use runmodes rather well. Also have a look at the example CGI::Application::Mailform.
Runmodes can either be passed on by a variable (usually named rm), or by $ENV{'PATH_INFO'}. See the documentation on mode_param().
It might help to specify your problem a little more in detail, for I -and I'm sure there are many other monks with me here- don't really get your "question".
--
b10m
All code is usually tested, but rarely trusted.