Skip to main content
Solved

How do I receive the browser javascript console.log result as an a360 variable value?

  • October 31, 2023
  • 2 replies
  • 185 views

Forum|alt.badge.img
  • Ground Control | Tier 1

topic,
I want receive the browser javascript console.log result as an a 360 variable value..

can i get some guide? or a360 browser document? 

my code is here
i = 0;
while (i < 7) {
    element = 'listitem' + i + 'innerListBoxdropdownlisteditorgrd2';
    textContent = document.getElementById(element).textContent;
    console.log(textContent);
    i++;
}

I would appreciate really. it if solution 

Best answer by JLogan3o13

You cannot read the console.log output natively, last I knew. I know you can incorporate a separate logging tool like Winston or Bunyan that can capture logging, but not sure how that would be implemented in an AA bot.

There are also a couple of Chrome extensions that allow viewing of the console log outside the console. But again, not sure how well you’d be able to capture these real-time in a bot.

2 replies

Forum|alt.badge.img
  • Cadet | Tier 2
  • November 5, 2024

logs will be available 

C:\ProgramData\AutomationAnywhere\BotAgent\Logs (for Windows).

 

FYI, 

 

"console" is not defined

 


Forum|alt.badge.img+17
  • Most Valuable Pathfinder
  • Answer
  • November 8, 2024

You cannot read the console.log output natively, last I knew. I know you can incorporate a separate logging tool like Winston or Bunyan that can capture logging, but not sure how that would be implemented in an AA bot.

There are also a couple of Chrome extensions that allow viewing of the console log outside the console. But again, not sure how well you’d be able to capture these real-time in a bot.