Highlighted
Super Contributor.
Super Contributor.
1447 views

Dialog error 18

I have imported a Net Express project that uses Dialog System into Visual COBOL, and I changed all the screen properties to 'Always copy' so they would could to the debug dir.  However, instead of going to ...\Visual Cobol\bin\x86\Debug\, they are going to ...\Visual Cobol\DEBUG, so I still get 'not found error 18.'  How to I tell the 'screen copy' where to put the screen?

0 Likes
4 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Dialog error 18

When you set Copy to Output Directory to "Always" for a file such as a screenset it tells Visual Studio to copy that file to whatever folder is specified in the project properties COBOL page -->Output Path field.

If you are changing the working directory on the Debug tab to a value other than the one set in Output Path then it will not find the screenset because it is assuming it is in the current directory.

I would advise that you use the same folder for your Output Path and your working directory whenever you require that files within the project are in the current directory.

You could also add a post build step under Build Events on the COBOL tab to do the copy to a different location but this seems like something that shouldn't really be required.

Thanks.

0 Likes
Highlighted
Super Contributor.
Super Contributor.

RE: Dialog error 18

That makes sense, Chris, but my output path for the  cobol projects is .\bin\x86\Debug\ - I haven't changed them, but for some reason, the always copy is not recognizing that.  Do the corressponding screens have to be under each project? For instance, do the Customer.gs and customer.cpb have to be under the Customer.cblproj project?   I really hope not.

Customer.cblproj

 Properties

    Customer.pco

       customer.cpy

0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Dialog error 18

Each project has its own build structure and Output Folder. You can set each project to point to the same Output Folder if you wanted all output to go to the same directory. If you are using a particular .gs file within two different projects and they do not share the same output folder then yes the .gs would have to be referenced in each project in order for the Copy Always to work properly. The .cpb files are just copybooks and are only required at compile time so they do not actually have to be in the project itself but they do need to be available to the project either within the copy path or in the project folder.

I would suggest that you open up a support incident and we can do a screen share to see how you have this setup.

Thanks.

0 Likes
Highlighted
Super Contributor.
Super Contributor.

RE: Dialog error 18

Ok, will do that in am.  Thanks.

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.