cancel
Showing results for 
Search instead for 
Did you mean: 

cannot apply indexing to an expression of type vardelegate

SOLVED
chrislukasik
Occasional Contributor

cannot apply indexing to an expression of type vardelegate

return obj[firstPropertyName][secondPropertyName].UnWrap();

 

This is giving me a visual studio compiler error of

cannot apply indexing with [] to an expression of type var.VarDelegate

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
AlexKaras
Community Hero

Re: cannot apply indexing to an expression of type vardelegate

Hi,

 

Connected Applications are deprecated in TestComplete (though still exist) and might not be updated to be supported by VisualStudio 2019.

I would recommend to ask Support directly via the https://support.smartbear.com/testcomplete/message/ form and would appreciate it if you update this thread with the reply from Support.

 

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

4 REPLIES 4
chrislukasik
Occasional Contributor

Re: cannot apply indexing to an expression of type vardelegate

this problem is occurring  for visual studio 19

tphillips
Community Leader

Re: cannot apply indexing to an expression of type vardelegate

1. What are you trying to do? What are you trying to achieve?

2. Why are you compiling anything?

3. How does this relate to TestComplete?

 

Also, it is better to edit your original comment if you add more information (before someone else has commented) instead of writing a reply to your original message, so it still shows up as an unanswered post 🙂


--------------------
QA Systems Architect
chrislukasik
Occasional Contributor

Re: cannot apply indexing to an expression of type vardelegate

I am attempting to compile test complete code in visual studio 19, in the C# language.   This code compiles in visual studio 11/12. 

 

public string GetText(var obj)

{

try

{

var.VarDelegate varDelegate = obj["Text"];

return obj["Text"]["OleValue"].UnWrap().ToString();

}

 

This has a compiler error of:    cannot apply indexing with [] to an expression of type var.VarDelegate.

 

 

AlexKaras
Community Hero

Re: cannot apply indexing to an expression of type vardelegate

Hi,

 

Connected Applications are deprecated in TestComplete (though still exist) and might not be updated to be supported by VisualStudio 2019.

I would recommend to ask Support directly via the https://support.smartbear.com/testcomplete/message/ form and would appreciate it if you update this thread with the reply from Support.

 

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

New Here?
Join us and watch the welcome video:
Announcements
Top Kudoed Authors