This is a migrated thread and some comments may be shown as answers.

Open a project Test Studio VS Plugin in Test Studio StandAlone

3 Answers 42 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
José
Top achievements
Rank 1
José asked on 18 Jun 2013, 02:11 PM
Hi,

I have a project with GUI tests, I try to open the project but i found this error message :"Cannot find code-behind of guiTest.tstest", but the file is there. Why can open but all code-behind in C# isn't charge for the Test Studio StandAlone? what i can do?


Thanks,

José Teles

3 Answers, 1 is accepted

Sort by
0
Boyan Boev
Telerik team
answered on 18 Jun 2013, 02:51 PM
Hi Jose,

Could you send me please the exact text of the error massage/trace log.

Try to delete the .dll file in the bin folder of your project folder. Test Studio will recompile the next time you execute the test.

Please go ahead and send us your test project - we would like to examine it. 
 

Regards,
Boyan Boev
Telerik
Free summer webinars on advanced web automation tactics hosted by Jim Holmes & Adam Goucher.
Reserve your seat today!
0
José
Top achievements
Rank 1
answered on 18 Jun 2013, 03:01 PM
In this moment I can open my project, but i can't run. I give you the log:

c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 184: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Worksheet'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 192: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 196: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 238: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Worksheet'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 246: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 250: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 278: (CS0168) The variable 'e' is declared but never used
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\Information.cs: Line 507: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Worksheet'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes.tstest.cs: Line 121: (CS0168) The variable 'e' is declared but never used
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes.tstest.cs: Line 131: (CS0168) The variable 'ex' is declared but never used
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes.tstest.cs: Line 136: (CS0168) The variable 'exx' is declared but never used
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes2.tstest.cs: Line 88: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Worksheet'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes2.tstest.cs: Line 96: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes2.tstest.cs: Line 152: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes2.tstest.cs: Line 154: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesAttributes2.tstest.cs: Line 219: (CS0168) The variable 'e' is declared but never used
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesVersionedAttributes.tstest.cs: Line 91: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Worksheet'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesVersionedAttributes.tstest.cs: Line 99: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesVersionedAttributes.tstest.cs: Line 153: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesVersionedAttributes.tstest.cs: Line 155: (CS0266) Cannot implicitly convert type 'object' to 'Microsoft.Office.Interop.Excel.Range'. An explicit conversion exists (are you missing a cast?)
c:\Users\jf-teles\Desktop\GenericTests\GenericTests\GenericsSteps\Utilities\PutValuesVersionedAttributes.tstest.cs: Line 233: (CS0168) The variable 'e' is declared but never used

 

In Visual Studio the same tests work
0
Accepted
Boyan Boev
Telerik team
answered on 19 Jun 2013, 12:05 PM
Hi Jose,

In Test Studio you should explicitly cast the object as Microsoft.Office.Interop.Excel.Range.

Here is an example:

Microsoft.Office.Interop.Excel.Range r = xlRange.Cells[k, 2] as Microsoft.Office.Interop.Excel.Range; // CAST !
if (r.Value2 != null) // ADDED IN EDIT
    {
  if (r.Value2.ToString().Equals("Extracted_Value"))
     {
}
}

If the issue persists please send us the test project so we can investigate what is causing the problem.

Regarding the "The variable 'e' is declared but never used" it's just a compiler warning, so it is not causing a compilation fail.

Hope this helps.

Regards,
Boyan Boev
Telerik
Free summer webinars on advanced web automation tactics hosted by Jim Holmes & Adam Goucher.
Reserve your seat today!
Tags
General Discussions
Asked by
José
Top achievements
Rank 1
Answers by
Boyan Boev
Telerik team
José
Top achievements
Rank 1
Share this question
or