Print from WebQuerySave agent

Hello,I want to print some output to the browser from the WebQuerySave agent. I have seen in this forum that this should work, but I do not see anything when I try it.

  • I have checked with the msgbox() command that the agent runs.

  • If I start the agent manualy from a push button it works fine.

  • In the Target Frame field of the form I put “_self” or nothing.

I am getting crazy what am I doing wrong ?

Pls help

Martin

Subject: solution

Hello,for anybody who will have this problem.

Do not use @Command([Filesave]) in your push button. (I think especially when you do not close the form), but use document.forms[0].submit().

CU Martin

Subject: print from WebQuerySave agent

  1. Make sure the agents 'Target’is ‘None’. Not on selected documents or anything else, just ‘None’.

  2. If the agent is set to ‘Agent list selection’ instead of the default ‘Action menu selection’, you must remember to put “(” and “)” around the agent name in the form event.

For example:

@Command([ToolsRunMacro]; “(myagent)”)

  1. Edit your agent’s 2 first lines to:

Print {Hello Happy World}

Exit Sub

This should work.

Subject: print from WebQuerySave agent

  1. Make sure the agents 'Target’is ‘None’. Not on selected documents or anything else, just ‘None’.

  2. If the agent is set to ‘Agent list selection’ instead of the default ‘Action menu selection’, you must remember to put “(” and “)” around the agent name in the form event.

For example:

@Command([ToolsRunMacro]; “(myagent)”)

  1. Edit your agent’s 2 first lines to:

Print {Hello Happy World}

Exit Sub

This should work.

Subject: RE: print from WebQuerySave agent

Hello Kenneth,thanx for yout answer.

I did all of this. Remember if I start the agent from a push button with @Command([ToolsRunMacro]; “(myagent)”) everything works fine.

Perhaps this is a problem:

I have a frameset. In this frameset is one page with a push button to create a new document. The new document opens in a new Browser window. I suppose somehow, that when the agent runs from the WebQuerySave event, he does not know the target where to put the output ?

Greetings Martin

Subject: RE: print from WebQuerySave agent

No, that can’t be the problem.The agent will produce output in the current window and it doesn’t matter if that is a new window, a frame window, or whatever.

Subject: RE: print from WebQuerySave agent

Hello Kenneth,thanx for yout answer.

I did all of this. Remember if I start the agent from a push button with @Command([ToolsRunMacro]; “(myagent)”) everything works fine.

Perhaps this is a problem:

I have a frameset. In this frameset is one page with a push button to create a new document. The new document opens in a new Browser window. I suppose somehow, that when the agent runs from the WebQuerySave event, he does not know the target where to put the output ?

Greetings Martin

Subject: solution

Hello,for anybody who will have this problem.

Do not use @Command([Filesave]) in your push button. (I think especially when you do not close the form), but use document.forms[0].submit().

CU Martin