SignDocument - Command is disabled currently - Urgently  SOLVED

PDF-XChange Viewer SDK for Developer's
(ActiveX and Simple DLL Versions)

Moderators: TrackerSupp-Daniel, Tracker Support, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Post Reply
cvpereira
User
Posts: 4
Joined: Wed Apr 21, 2021 8:55 pm

SignDocument - Command is disabled currently - Urgently

Post by cvpereira »

Hi everyone

I'm trying to run the command "36516 - SignDocument", but it always shows "Command is currently disabled" in my app. In the full demo, this command works correctly.

I read this topic
https://forum.pdf-xchange.com/viewtopic.php?f=36&t=16526&p=67217&hilit=sign#p67217
but unfortunately I couldn't make it work. My code is below. I'm using Delphi 5 and Windows 10.

Code: Select all

  Result := False;
  try
     //=> This point my doc is open
     //    Viewer.OpenDocument(AArquivo, '', DocId, 0); => I tried open, but the message continue
    Viewer.SetProperty('Commands[#36516].State', 'OnLine', 0); //Habilitar Assinatura Digital...
    Viewer.DoVerb('', 'ExecuteCommand', 36516, EmptyParam, 0);
    Result := True;
  except
    on ex: EOleException do
      ShowErrorMessage(Viewer, ex.ErrorCode);
  end;
I did everything to work, including calling the OpenDocument method before enabling the command

Best regards

Claudemir
Instituto das Cidades Inteligentes
Message on execute command
Message on execute command
Message show that exist open doc and IsOperationGranted is equal 1
Message show that exist open doc and IsOperationGranted is equal 1
Executing on the full demo
Executing on the full demo
the same file Work propertly
the same file Work propertly
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17765
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: SignDocument - Command is disabled currently - Urgently

Post by Tracker Supp-Stefan »

Hello cvpereira,

There seems to be another topic with the same issue:
viewtopic.php?f=36&t=16526&p=67173&hili ... 516#p67173
And the problem there was an older build of the Viewer SDK.

Can you please make sure that the "Fill Demo" and your own project are using the same build number?

Kind regards,
Stefan
cvpereira
User
Posts: 4
Joined: Wed Apr 21, 2021 8:55 pm

Re: SignDocument - Command is disabled currently - Urgently  SOLVED

Post by cvpereira »

Tracker Supp-Stefan wrote: Mon Jun 14, 2021 11:31 am Hello cvpereira,

There seems to be another topic with the same issue:
https://forum.pdf-xchange.com/viewtopic.php?f=36&t=16526&p=67173&hilit=%27ExecuteCommand%27%2C+36516#p67173
And the problem there was an older build of the Viewer SDK.

Can you please make sure that the "Fill Demo" and your own project are using the same build number?

Kind regards,
Stefan
Hi Stefan

I managed to solve it, the Viewer's ReadOnly property was set to "True", when I set it to "False", the command returned "Enabled"

Best regards
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17765
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: SignDocument - Command is disabled currently - Urgently

Post by Tracker Supp-Stefan »

Hello cvpereira,

Glad to hear that you figured it out!

Kind regards,
Stefan
Post Reply