You are not authenticated! Error code: 0 exception occurred only for UiPath background process - uipath

I started a development using the UiPath template called ‘Background Process’ and currently I’m facing an issue when reading orchestrator assets. It throws the error ‘You are not authenticated! Error code: 0’. But when I tried out UiPath RE-Framework based developments, this issue was not emerged. However I’m using the community editions of both studio and the orchestrator where the version is 2021.10.5. I’ve been struggling for whole 1 day trying out different solutions, but failed. No idea whether there is something with background processes or not. I would really appreciate your support ahead in time.
Image 1 - Normal flow without using either RE Framework or Background process
Image 2 - RE Framework process
Image 3 - Background process
Image 4 - The main file of background process

I sorted out the issue by downgrading "UIPath.System.Activities" version into 20.4.0.
Thank you.

Related

VS Codespaces bash shell failed to initiate

I'm using VS codespaces to complete the current CS50X course.
I've been getting on very well with it but have hit a snag where the Terminal doesn't seem to be loading correctly. I think i'm missing a couple of options at the top of the Terminal section - Debug and Port. I'm trying to complete the Finance section of the course which involves connecting to a development server but when i try i get the following erroe message:
{"type":"https://tools.ietf.org/html/rfc7231#section-6.5.4","title":"Not Found","status":404,"traceId":"00-76b8a3e0c4eaccf805373ec05e5ec917-dccabf0efd4cf681-00"}
I've tried to Google what might be going on but i'm very new to programming and don't understand a lot of what i'm reading!!
I did notice that the shell has failed to initiate, but again, i don't really know what that means.
I've tried re-loading the window repeatedly but still get the same situation.
Any ideas would be much appreciated!!

How to reference active document in Solidworks when there are multiple instances

I am using the following code in Solidworks 2017 Visual Studio Tools for Applications. It's Microsoft Visual Studio 2005 Version 8.0.50727.42 running Microsoft Visual Basic 2005 and Microsoft .NET Framework Version 2.0.50727 SP2.
Public Sub Reference_GetCurrentPartorAssembly(ByRef CurrentFile As SolidWorks.Interop.sldworks.ModelDoc2)
CurrentFile = swApp.ActiveDoc
If IsNothing(CurrentFile) Then Throw New Exception("Could not get reference to current part or assembly.")
End Sub
Generally, the code works fine. However, sometimes there are extra instances of Solidworks running which are listed under the "background processes" list in Windows Task Manager. When that happens, my code throws the exception. To get my code to execute without the exception, I have to find the stray solidworks background process and force kill it using Task Manager.
(I have no idea why these background versions of Solidworks show up.)
I did not find Solidworks' documentation on ActiveDoc to be very helpful: http://help.solidworks.com/2017/english/api/sldworksapi/solidworks.interop.sldworks~solidworks.interop.sldworks.isldworks~activedoc.html?verRedirect=1
My question is: how can I get a reference to the current document without having to force-kill those background processes? I tried looking for other ways to get the reference to the active document but most code samples I have find all use ActiveDoc.
In my experience multiple instances of solidworks can function perfectly fine, I don't think background version of solidwork would affect your main one.
As I understand you are running a macro, not an addin, so make sure you are starting VSTS from your foreground version of solidworks. Maybe somehow your macro is executing against one of the background version that obviously has no activedoc.
Also I would take a look into backround instances, if you're not starting them - no reason for them to execute, try to take a note at which moment they appear to try to determine the cause.

Windows CE: Debug Output: Failed on waiting multiple events

i use for an old device(client) (ARMV4I-architecture) VS2008 to develop a server-client application with a GUI(MFC). OS is WindowsCE. The communication works with the Server, but in the Debug-Mode it appears the following text in the output-window:
"Error: failed on waiting multiple events."
If i run only the GUI without network-connection, the text not appears.
My first question is: Could this issue run into communication disruption?
I have read some articles suggesting to use Shutdown( 2 ), AsyncSelect(0) before closing a socket (CSockets/CAsyncSocket). But this does not solve this issue.
The second question is:
Are other possibilities known to solve this problem?
Thx in advance

Why would an application popup an error, "Control doesn't have parent window," after running for 3 weeks?

I have been running an application developed under Windows 7 in Delphi XE on Windows 7 machine for about 3 weeks non-stop, but it stopped working after that and popped up a message box with "Control doesn't have parent window." After that nothing seem to work right in the software, unless it is shutdown and restarted.
I have an idea of what that error means, but I am trying to figure out. Why?
Any hints or suggestions will be greatly appreciated. Thank you.
Sign of a resource leak, window handles most likely. Diagnose with TaskMgr.exe, Processes tab. View + Select Columns and tick Handles, USER Objects and GDI Objects. Keep on eye on the values for your program while you are using it. A steady increase spells trouble, Windows stops giving more after 10,000.
If that doesn't help then improve your exception handling so you can get a better diagnostic, a stack trace is important to diagnose trouble like this.
You should install a copy of MadExcept, JclExcept, or other exception handling library that supports displaying/logging the call stack when an uncaught exception is raised (if you cannt reproduce the exception while running inside the IDE debugger, that is). Then you can figure out what your app was trying to do at the time of the exception, and hopefully narrow it down to the spot in your code that is accessing the specific UI control that is missing its Parent window.

Detect/Redirect core dumps (when a software crashes) on Windows

For my work, I need to create a service that will detect an abnormal program termination and, instead of displaying a message to the user (default behavior), send the generated core dump to a remote server.
I'm pretty sure this can be done, but I have absolutely no clue on where to start. Is there any API/registry settings for this ?
Thank you.
One method is to install an Unhandled Exception Filter and then write a minidump from it which you can then upload to some place of your choosing. I wouldn't totally disregard Windows Error Reporting -- that's an addition to any crash reporting of your own. If your application is for public release then registering for Windows Error Reporting is well worthwhile as you get information about which crashes users are encountering in the wild and when crashes have been fixed you can add a response code to point them to a new version or other relevant information.
Another tool that may be useful depending on how your application is deployed in your organisation is to run Adplus on a user's machine which will collect together crash dumps. This is more useful for one-off crashes that seem to affect an individual user but aren't reproducible in a development environment.
Some other useful links:
http://www.debuginfo.com/articles/effminidumps.html - some useful sample code
http://www.codeproject.com/KB/debug/postmortemdebug_standalone1.aspx
It seems my question was either obvious or stupid (both ?) but anyway, i found some interesting pages after some researches.
Here are the links I found useful:
Track application crashes and disable Windows Error Reporting at the same time!
Disable error reporting

Resources