Files as attachm. via context menu (Send to) no longer works

Here you can propose new features, make suggestions etc.

Moderators: Hacker, petermad, Stefan2, white

Post Reply
DoobieB
Junior Member
Junior Member
Posts: 2
Joined: 2012-05-22, 12:32 UTC

Files as attachm. via context menu (Send to) no longer works

Post by *DoobieB »

I'm running TC 8.0 RC 2 under Win7 32-bit with Office/Outlook 2010 Professional Plus 2010 (... most recent fixes applied) and sending files as attachements via context menu (Send to) no longer works. No problem with "vanilla" Windows Explorer. Context menu opens properly but neither by right click nor by shift + F10 a new email opens and file will be attached .... no error msg - nothing happens.

:(
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, DoobieB.

Just tried it here. No problem. Total Commander 8.0rc2 32-bit => Sendto => E-Mail Recipient works as expected. Outlook 2010 opens. The selected file has been attached.

Windows 7 Enterprise SP1 32-bit
Office 2010 SP1
Outlook 2010
Total Commander 8.0rc2

Cheers,
Karl
MX Linux 21.3 64-bit xfce, Total Commander 11.50 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
Horst.Epp
Power Member
Power Member
Posts: 6950
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Post by *Horst.Epp »

Sendto => E-Mail Recipient
works here with TC 8 RC2 x86 and x64
under Windows 7 x64 Ultimate.
User avatar
HolgerK
Power Member
Power Member
Posts: 5408
Joined: 2006-01-26, 22:15 UTC
Location: Europe, Aachen

Post by *HolgerK »

Confirmed (TC8.0RC2 x64/x86, Win7 x64, Office2010 x86, all updates applied)
But : only under the condition that TC runs elevated (as administrator).
<Edit>
BTW: This seems to be a general problem of "send to" because an elevated Explorer fails as well.
Oops,sorry: after trying a second time, elevated Explorer seems to work correct.
</Edit>

<Edit2>
Same effect with ThunderBird 12.01. So it's not an Office specific problem.
</Edit2>

Regards
Holger
DoobieB
Junior Member
Junior Member
Posts: 2
Joined: 2012-05-22, 12:32 UTC

Post by *DoobieB »

Hello karlchen,

you're saying"... Outlook 2010 opens. The selected file has been attached.". It's only working for me when Outlook is not up and running. If it's already running it doesn't work.
User avatar
petermad
Power Member
Power Member
Posts: 15997
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Post by *petermad »

Works fine here with TC 8.0RC2 on Windows XP (32bit TC) and Windows 7 (32bit and 64bit TC).

All tests with Mozilla SeaMonkey as email client, both when Seamonkey is already running, and when it is not.

I an NOT running TC elevated, but I am running Windows as administrator.
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
karlchen
Power Member
Power Member
Posts: 4605
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, DoobieB.
you're saying"... Outlook 2010 opens. The selected file has been attached.". It's only working for me when Outlook is not up and running. If it's already running it doesn't work.
Does not matter here. In case Outlook is not running it will be launched and closed after sending the mail. In case Outlook had been started before a new e-mail window will be opened instead and after sending the e-mail only this window will be closed, but Outlook will be still open.

I assume that the factor which HolgerK has reported may be one possible source of trouble: Outlook and Total Commander having different security contexts, most likely T.C. being run elevated "as administrator", but Outlook being run non-elevated. (Unless UAC has been switched off completely this may happen, even though your user account is named "Administrator". The name "Administrator" does not imply you are doing anything in elevated mode automatically. "Administrator" is just a name.)

Kind regards,
Karl
MX Linux 21.3 64-bit xfce, Total Commander 11.50 64-bit
The people of Alderaan keep on bravely fighting back the clone warriors sent out by the unscrupulous Sith Lord Palpatine.
The Prophet's Song
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50386
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Outlook and Total Commander having different security contexts, most likely T.C. being run elevated "as administrator", but Outlook being run non-elevated.
I also think that this is the problem. Windows blocks the communication between a program with normal rights and one with higher rights.
Author of Total Commander
https://www.ghisler.com
User avatar
MarcinW
Power Member
Power Member
Posts: 852
Joined: 2012-01-23, 15:58 UTC
Location: Poland

Post by *MarcinW »

There is a way to enable communication with lower privileged processes. I've found a description of enabling drag&drop somewhere in the internet and I created the following piece of code:

Code: Select all

procedure DragDropInit(Wnd : HWND = 0);
const
  WM_COPYGLOBALDATA = $0049;
  MSGFLT_ADD = 1;
  MSGFLT_ALLOW = 1;
var
  ChangeWindowMessageFilter : function(message : UINT; dwFlag : DWORD) : BOOL; stdcall;
  ChangeWindowMessageFilterEx : function(hWnd : HWND; message : UINT; action : DWORD; pChangeFilterStruct : Pointer) : BOOL; stdcall;
begin
  @ChangeWindowMessageFilter:=GetProcAddress(GetModuleHandle(user32),'ChangeWindowMessageFilter');
  @ChangeWindowMessageFilterEx:=GetProcAddress(GetModuleHandle(user32),'ChangeWindowMessageFilterEx');
  if Assigned(ChangeWindowMessageFilter) then
  if (Wnd <> 0) and Assigned(ChangeWindowMessageFilterEx) then
  begin
    if not ChangeWindowMessageFilterEx(Wnd,WM_DROPFILES,MSGFLT_ALLOW,nil) then
      ChangeWindowMessageFilter(WM_DROPFILES,MSGFLT_ADD);
    if not ChangeWindowMessageFilterEx(Wnd,WM_COPYDATA,MSGFLT_ALLOW,nil) then
      ChangeWindowMessageFilter(WM_COPYDATA,MSGFLT_ADD);
    if not ChangeWindowMessageFilterEx(Wnd,WM_COPYGLOBALDATA,MSGFLT_ALLOW,nil) then
      ChangeWindowMessageFilter(WM_COPYGLOBALDATA,MSGFLT_ADD);
  end else
  begin
    ChangeWindowMessageFilter(WM_DROPFILES,MSGFLT_ADD);
    ChangeWindowMessageFilter(WM_COPYDATA,MSGFLT_ADD);
    ChangeWindowMessageFilter(WM_COPYGLOBALDATA,MSGFLT_ADD);
  end;
end;
Regards
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50386
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Wow, that's nice! Unfortunately I haven't seen this before. Is there any overview of new Windows Vista/7 functions anywhere?

Anyway, I will try to add it to the next version of TC (probably 8.1).
Author of Total Commander
https://www.ghisler.com
User avatar
MarcinW
Power Member
Power Member
Posts: 852
Joined: 2012-01-23, 15:58 UTC
Location: Poland

Post by *MarcinW »

I suppose that the easiest way to obtain a full list of new API functions is to download Visual Studio 2010 Express (it's free). There is a lot of *.h files there (the most important is "WinUser.h") - new Vista functions are surrounded by "#if(_WIN32_WINNT >= 0x0600)" or "#if(_WIN32_WINNT >= 0x0601)".

Regards!
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50386
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Thanks for the suggestion. Moving thread to suggestions forum.
Author of Total Commander
https://www.ghisler.com
Post Reply