chriscamicas / vscode-abl

An extension for VS Code which provides support for the Progress OpenEdge ABL language. https://marketplace.visualstudio.com/items?itemName=chriscamicas.openedge-abl
MIT License
50 stars 37 forks source link

Help needed to set up checking of syntax #44

Closed Orionsg closed 5 years ago

Orionsg commented 5 years ago

I have a really simple setup on a local machine without the application server. Thus I either run Progress with direct -1 connection to the database or through shared memory connection to the local Progress development server (no TCP connection).

I would like to have the ABL Check Syntax function to work. Running a program from VSCode is not necessary as I already have the application running from a Progress editor (where all setups are done from the first program of the application) and in the rare case I need debugging, I will just use the Progress debugger. But it would be nice if the check syntax function could work so the VSCode could go to any problems in the code and show the error message.

I guess that the launch. json needs to be configured and I have looked at the example files included under Code, but I must admit that much of it does not give meaning for me. I have mostly used VSCode for HTML, CSS and now OpenEdge ABL. Thus I have not delved deeper into setting up of launch configurations and all the various variables.

What is the minimal needed configuration for Check Syntax to work. I have the .openedge.json config file with the correct DLC path included. When I use Check Syntax now, nothing happens, except that "Checking Syntax" is shown in status bare at the bottom.

chriscamicas commented 5 years ago

inside the .openedge.json file, you'd probably need to specify some pf files with the db connection. Depending on your project, you may also need to specify the different PROPATH entries

Orionsg commented 5 years ago

Thanks for the help getting it to work!

The .openedge.json file:

{
    "workingDirectory": "c:\\dtmwork\\trunk",    
    "proPath": [
        "c:\\dtmwork\\trunk",
        "c:\\source\\trunk\\source",
        "c:\\source\\trunk\\source\\src",
        "c:\\source\\trunk\\source\\iconsmf",
        "c:\\source\\udvkutil",
        "c:\\source\\udvkutil\\translation",
        "c:\\progress\\dlc102b\\probuild\\eucapp",
        "c:\\progress\\dlc102b\\probuild\\eucapp\\euc.pl",
        "c:\\progress\\dlc102b\\gui",
        "c:\\progress\\dlc102b\\gui\\adeweb.pl",
        "c:\\progress\\dlc102b\\gui\\adecomm.pl",
        "c:\\progress\\dlc102b\\gui\\adecomp.pl",
        "c:\\progress\\dlc102b\\gui\\adedesk.pl",
        "c:\\progress\\dlc102b\\gui\\adedict.pl",
        "c:\\progress\\dlc102b\\gui\\adeedit.pl",
        "c:\\progress\\dlc102b\\gui\\adeicon.pl",
        "c:\\progress\\dlc102b\\gui\\aderes.pl",
        "c:\\progress\\dlc102b\\gui\\adeshar.pl",
        "c:\\progress\\dlc102b\\gui\\adeuib.pl",
        "c:\\progress\\dlc102b\\gui\\adexml.pl",
        "c:\\progress\\dlc102b\\gui\\as4dict.pl",
        "c:\\progress\\dlc102b\\gui\\prodict.pl",
        "c:\\progress\\dlc102b\\gui\\protools.pl",
        "c:\\progress\\dlc102b",
        "c:\\progress\\dlc102b\\bin",
    ],
    "dlc": "c:\\progress\\dlc102b", 
    "proPathMode": "overwrite", // overwrite, prepend
    "parameterFiles": [ 
        "c:\\dtmwork\\trunk\\udvk.pf",
    ],
}

The specified propath and pf file works with the Progress editor, i.e. connects to the database and can compile the procedure files. However, I still get no check of syntax. Since you did not mention launch.json, I have not created such.

Any ideas what could be wrong?

chriscamicas commented 5 years ago

I never tested with Progress 10.2b. It's probably the reason why it does not work. Unfortunately, I don't have time to work on supporting this version. Could you try with a more recent version, to confirm this hypothesis ? If you'd like to contribute, you could fork and run this extension from the source to try to find why.

Orionsg commented 5 years ago

@chriscamicas Thanks for your reply.

I don't have the later version of Progress on this computer and we don't need it for the current project, so I am not going to install it just for this.

I am okay about testing Progress code and settings, etc. but Running VSCode Extensions from source to debug is not feasible as I am not using VSCode at the level of programming Extensions. I guess I will just have to compile code in the editor until we at some point upgrade to the later version.

chriscamicas commented 5 years ago

I'm sorry I couldn't help.