Ask a Question

TestComplet 14 - support for dotNET Functions

SOLVED
tuanlv
Regular Visitor

TestComplet 14 - support for dotNET Functions

We just migrated to TC14 from TC10 and we are having this weird problem:

we are trying to hold the test from running while the application is in a non-responsive state,
we are using this code:

var affinityPtr = dotNET.System.IntPtr.zctor(intAffinity);
var process = dotNET.System_Diagnostics.Process.GetProcessById(intProcessID);
process.ProcessorAffinity = affinityPtr;

 

When we are executing the dotNET line(red color), we get an exception - "Object doesn't support this property or method"

 

check value of ProcessorAffinity:

Error: System.ComponentModel.Win32Exception (0x80004005): Access is denied
at System.Diagnostics.ProcessManager.OpenProcess(Int32 processId, Int32 access, Boolean throwIfExited)
at System.Diagnostics.Process.GetProcessHandle(Int32 access, Boolean throwIfExited)
at System.Diagnostics.Process.get_ProcessorAffinity()

 

Please help me resolve this issue. 

Thanks to all helpers, Tuan

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
AlexKaras
Community Hero

Re: TestComplet 14 - support for dotNET Functions

Hi,

 

Access is denied

Sounds like lack of permissions. Have you tried to start TestComplete using Run As Administrator option?

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================

View solution in original post

3 REPLIES 3
Marsha_R
Community Hero

Re: TestComplet 14 - support for dotNET Functions

That's a big jump in TC versions.  I would contact Support directly to ask your question.  Here's the link:

https://support.smartbear.com/testcomplete/message

Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
AlexKaras
Community Hero

Re: TestComplet 14 - support for dotNET Functions

Hi,

 

Access is denied

Sounds like lack of permissions. Have you tried to start TestComplete using Run As Administrator option?

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================

View solution in original post

sonya_m
Community Manager

Re: TestComplet 14 - support for dotNET Functions

Hi @tuanlv ! Looks like you replied to the email notification, this way your reply won't be posted. Let me copy it here this time around:

>>

Hi,

I have solved this issue. The solution is to start TestComplete using Run As Administrator.

Many thank for your support.

Tuan,

<<


Sonya Mihaljova
Community and Education Specialist

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
cancel
Showing results for 
Search instead for 
Did you mean: