Nice. Here's the code in Perl (untested, but it should be the same). ############################
use Win32::OLE; my $xl = (Win32::OLE->GetActiveObject('Excel.Application') || Win32::OLE->new('Excel.Application')); $xl->Application->Goto({Reference => $xl->Application->PreviousSelections(1)}); ############################ -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of ?????? ????????? Sent: Wednesday, May 03, 2006 1:05 AM To: perl-win32-users@listserv.ActiveState.com Subject: Re: Returning to a Worksheet where a hyperlink was used - in Excelwith Win32::OLE Здравствуйте Glen, Monday, May 01, 2006, 11:47:28 PM, Вы написали: GP> I know that the user can get back to a Sheet from where they originally GP> clicked on the hyperlink ( that brought them to the current definition GP> page ) by executing: GP> Control-G <ENTER> It corresponds to Application.GoTo method call. GP> ( Control-G here brings up the "Go To" dialog box, listing a GP> series of "References", one of which is highlighted, which is the GP> reference for the sheet from where they came. These series of references are the Application.PreviousSelections property. This property is 4-element array. Previous selection is always first element. So You can create on definition sheet the command button and put in its OnCliCk event handler following code Application.Goto Reference:=Application.PreviousSelections(1) Or You can create an hyperlink and dinamycally adjust its SubAddress property, but its more sofisticated. P.S. Excuse my English (and VBA too :)) -- С уважением, Сергей mailto:[EMAIL PROTECTED] _______________________________________________ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs _______________________________________________ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs