Error with C# Code

PapyRef

Client
Регистрация
28.02.2012
Сообщения
70
Благодарностей
6
Баллы
0
I tested interface between a Zenno variable and C# code.
I got this error when i tested C# code. Can you explain me why ?

Zenno-Test-csharp.png
 

shade

Client
Регистрация
19.11.2010
Сообщения
580
Благодарностей
346
Баллы
63
I tested interface between a Zenno variable and C# code.
I got this error when i tested C# code. Can you explain me why ?

Посмотреть вложение 2781
In test mode of code you can't get access to yours variables from current project. In test mode you should add to list name and value of variable and test code will be use variables from this list (not from your project). Also in test you can't use lists and tabels.
When you are testing your code you haven't variable "text" and variable "yourText" is null or empty string. Then method "Substring" is called, your code is throwing exception. Because substring from this range can not be got.

In action, you can't use code like this "var yourText = {-Variable.text-};" for getting variable's value. You should use variable "project" like you have done it in test form.
 
  • Спасибо
Реакции: PapyRef

Кто просматривает тему: (Всего: 1, Пользователи: 0, Гости: 1)