Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.

serviceBonnen

We have table called "SERVICEBONNEN" so we created a resource called serviceBonnen.
The API SERVICEBONNEN_API was created, but the compiler won't compile. We think maybe because of the reserved word "Service". If so is there a way around?

Comments

  • I was about to agree with your assessment but during my own testing I was able to get this to compile for me. What is the version of the SRP Editor and SRP Utilities that you are using? You can get the SRP Editor version from the Help > About menu. The SRP Utilities version comes from the SRPUtilities.dll file using the Properties > Details tab.

    Also, if you want to email me your API code I'll see if there is anything unique about your routine that is causing the problem.
  • Editor 2.9.1
    Utility 2.1.9
    We installed the ocxcontrols on my PC, deleted some SRP-files from the root of OI-dev folder.
    Suddenly the editor came up blank. We installed the latest available version, but was nagging about unlicensed.
    Eventually got it to work, but we are confused what did it.
    We want to upgrade the srp libraries to the latest version, and remove some old garbage..
    What is the best practice?
    What files need to be in the root of OpenInsight?
    Does the latest .srplic license all libraries?

    The API code was out of the box...
    ====================================================================================
    Function Servicebonnen_API(@API)


    #pragma precomp SRP_PreCompiler


    $insert APP_INSERTS
    $insert API_SETUP
    $insert HTTP_INSERTS

    GoToAPI else
    // The specific resource endpoint doesn't have a API handler yet.
    HTTP_Services('SetResponseStatus', 204, 'This is a valid endpoint but a web API handler has not yet been created.')
    end

    Return Response OR ''


    ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
    // Endpoint Handlers
    ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////


    API servicebonnen.HEAD
    API servicebonnen.GET

    HTTP_Resource_Services('LoremIpsum')


    end api


    API servicebonnen.POST

    HTTP_Resource_Services('LoremIpsum')

    end api


    API servicebonnen.PUT

    HTTP_Resource_Services('LoremIpsum')

    end api
  • Installing the latest Editor did the job... Compiled with success. We are glad to use this endpoint.
  • Great news. That should also have updated your SRP Utilities at the same time, which is where the Enhanced BASIC+ support resides.
Sign In or Register to comment.