Highlighted
Absent Member.
Absent Member.
1794 views

Immediate windows

Jump to solution

Can this be used for cobol commands?  Example moving spaces to field.  Is so, can you please provide the syntax.  Here is what I have tried

 

move spaces to w-policy-num

and here is the error that I get.....Error: Invalid expression (at 'spaces to w-policy-num')

Tags (1)
0 Likes
1 Solution

Accepted Solutions
Highlighted
Absent Member.
Absent Member.

RE: Immediate windows

Jump to solution

This works if I wanted to change a value, but what if I wanted to issue a write/rewrite command?  There is no way of doing "on the fly" coding?

View solution in original post

0 Likes
3 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Immediate windows

Jump to solution

No, sorry but we have not yet implemented this type of functionality in the Visual Studio Immediate Window.

The current support is very limited in scope as there is no way to actually perform an assignment of a data item to a value using commands.

If you specify a command like:

>Debug.EvaluateStatement x="123"

It will return with the following

FALSE

That is because the "=" is currently viewed as an equivalence operator and not an assignment operator in COBOL.

The easiest way to change the value of a data item while debugging is to simply hover the mouse over the item and then change its value.

Thanks.

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: Immediate windows

Jump to solution

This works if I wanted to change a value, but what if I wanted to issue a write/rewrite command?  There is no way of doing "on the fly" coding?

View solution in original post

0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Immediate windows

Jump to solution

No, the ability to enter and run COBOL statements directly from within the Visual Studio immediate or command windows is not something that is supported.

Although we did have this type of support for .int code run within Net Express using the Do command this has not been implemented in Visual COBOL.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.