OpenEdge.Net.pl - Forum - OpenEdge Development - Progress Community
 Forum

OpenEdge.Net.pl

This question is not answered

Hi,

I am trying to use OpenEdge.Net.pl. The propath is C:/JCA/OpenEdge.Net.pl and I have include the libray, compiler is giving below error messages:

Impossibile trovare la classe o interfaccia OpenEdge.Net.HTTP.RequestBuilder. (12886)

** Impossibile interpretare linea 1. (196)
Impossibile trovare la classe o interfaccia OpenEdge.Net.HTTP.IHttpRequest. (12886)
** Impossibile interpretare linea 2. (196)
Tipo di dati specificato non valido: IHttpRequest. Specificare un tipo di dati come 'character' o il nome di una classe. (5638)
** Impossibile interpretare linea 5. (196)

OpenEdge V. 11.7 and OS - Windows.

Thanks in advance,

G.

All Replies
  • Put is very similar.
     
    RequestBuilder:Put(<uri>, <message-body>):Request.
     
    The <message-body> will depends on what you’re sending. You can send a variety of data (JSON, XML, binary, etc).
     
     
  • Thanks. Sorry another question: and for POST?

    Inviato dal mio dispositivo Huawei


    -------- Messaggio originale --------
    Oggetto: RE: [Technical Users - OE Development] OpenEdge.Net.pl
    Da: Peter Judge
    A: TU.OE.Development@community.progress.com
    CC:


    Update from Progress Community
    Peter Judge

    Put is very similar.
     
    RequestBuilder:Put(<uri>, <message-body>):Request.
     
    The <message-body> will depends on what you’re sending. You can send a variety of data (JSON, XML, binary, etc).
     
     

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

  • Same for Put(), Post(), Delete(), etc.
     
     
  • I Jason,
     
    this is correct?
     
    oJson = new JsonObject().
    /* assume that there's some real data in this object */
    oJson:Add('temp/entity.xml', new JsonObject()).
     
    oRequest = RequestBuilder:POST(httpUrl, oJson)
                    :AcceptJson() /* we want to get JSON back */
                    :Request.
    Thx
     
    Da: Peter Judge [mailto:bounce-pjudge@community.progress.com]
    Inviato: giovedì, 10. maggio 2018 22:52
    A: TU.OE.Development@community.progress.com
    Oggetto: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    Update from Progress Community
     
    Put is very similar.
     
    RequestBuilder:Put(<uri>, <message-body>):Request.
     
    The <message-body> will depends on what you’re sending. You can send a variety of data (JSON, XML, binary, etc).
     
     

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

     

     Mail priva di virus. www.avast.com
  • The previuos example is wrong. I need to send XML. maybe there is an example.

    Thx

  • Hi Peter,

    I tried a lot of solutions without success. My problem is to define object for XML data file. An help is appreciate. Thx a lot in advance.

    xmlfile = "c:/jca/temp/entity.xml".

    hXmlRequestData:LOAD("LONGCHAR", xmlfile, FALSE).

    httpUrl = "obsv:5493/.../Clients".

    oXmlRequestData = NEW WidgetHandle(hXmlRequestData).

    oRequest = RequestBuilder:POST(httpUrl, oXMLRequestData):ContentType("application/xml")

                    :AcceptXml()

                    :Request.

  • That the code you have there should work.

    What’s failing? What errors do you see?
     
  •  
     
    Da: Peter Judge [mailto:bounce-pjudge@community.progress.com]
    Inviato: venerdì, 11. maggio 2018 22:32
    A: TU.OE.Development@community.progress.com
    Oggetto: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    Update from Progress Community
     
    That the code you have there should work.

    What’s failing? What errors do you see?
     

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

     

     Mail priva di virus. www.avast.com
  • DEFINE VARIABLE hXmlRequestData AS HANDLE NO-UNDO.

    DEFINE VARIABLE oXmlRequestData AS WidgetHandle NO-UNDO.

  • You need to create the X-DOC handle first.

    DEF VAR hXmlRequestData AS HANDLE.

    CREATE X-DOCUMENT hXmlRequestData.

    hXmlRequestData:LOAD(...)

    Alternatively you can just try

    DEF VAR lxXml AS LONGCHAR.

    COPY-LOB FILE "c:/jca/temp/entity.xml" to lcXml.

    oRequest = RequestBuilder:POST(httpUrl, NEW OpenEdge.Core.String(lcXml))

                   :AcceptJson() /* we want to get JSON back */

                   :Request.

  • With the first example:
    After
     
    I must to pass the credential as GET I think.
     
    Da: Peter Judge [mailto:bounce-pjudge@community.progress.com]
    Inviato: venerdì, 11. maggio 2018 22:47
    A: TU.OE.Development@community.progress.com
    Oggetto: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    Update from Progress Community
     

    You need to create the X-DOC handle first.

    DEF VAR hXmlRequestData AS HANDLE.

    CREATE X-DOCUMENT hXmlRequestData.

    hXmlRequestData:LOAD(...)

    Alternatively you can just try

    DEF VAR lxXml AS LONGCHAR.

    COPY-LOB FILE "c:/jca/temp/entity.xml" to lcXml.

    oRequest = RequestBuilder:POST(httpUrl, NEW OpenEdge.Core.String(lcXml))

                   :AcceptJson() /* we want to get JSON back */

                   :Request.

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

     

     Mail priva di virus. www.avast.com
  • For the second example:
     
    Da: Peter Judge [mailto:bounce-pjudge@community.progress.com]
    Inviato: venerdì, 11. maggio 2018 22:47
    A: TU.OE.Development@community.progress.com
    Oggetto: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    Update from Progress Community
     

    You need to create the X-DOC handle first.

    DEF VAR hXmlRequestData AS HANDLE.

    CREATE X-DOCUMENT hXmlRequestData.

    hXmlRequestData:LOAD(...)

    Alternatively you can just try

    DEF VAR lxXml AS LONGCHAR.

    COPY-LOB FILE "c:/jca/temp/entity.xml" to lcXml.

    oRequest = RequestBuilder:POST(httpUrl, NEW OpenEdge.Core.String(lcXml))

                   :AcceptJson() /* we want to get JSON back */

                   :Request.

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

     

     Mail priva di virus. www.avast.com
  • If xmlfile is a Character variable holding a file-name, the first parameter of the LOAD method should be “FILE”
     
    Von: Giancarlo Alberto Somma <bounce-obonelinux@community.progress.com>
    Gesendet: Freitag, 11. Mai 2018 22:21
    An: TU.OE.Development@community.progress.com
    Betreff: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    /cfs-file/__key/communityserver-discussions-components-files/19/380367.image001.png
    Update from Progress Community
    /cfs-file/__key/communityserver-discussions-components-files/19/5430.image002.jpg
     

    Hi Peter,

    I tried a lot of solutions without success. My problem is to define object for XML data file. An help is appreciate. Thx a lot in advance.

    xmlfile = "c:/jca/temp/entity.xml".

    hXmlRequestData:LOAD("LONGCHAR", xmlfile, FALSE).

    httpUrl = "obsv:5493/.../Clients".

    oXmlRequestData = NEW WidgetHandle(hXmlRequestData).

    oRequest = RequestBuilder:POST(httpUrl, oXMLRequestData):ContentType("application/xml")

                    :AcceptXml()

                    :Request.

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

    Das Bild wurde vom Absender entfernt.
     

    Architect of the SmartComponent Library and WinKit

    Consultingwerk Ltd.

  • Thanks Mike. That’s right. But I have another error:
     
     
    In both code.
     
    oRequest = RequestBuilder:POST(httpUrl, oXMLRequestData):ContentType("application/xml")
                     :AcceptXml()
                     // Add credentials to the request
                     //:UsingBasicAuthentication(oCredentials)
                     :Request.  */
                    
                   
    DEF VAR lcXml AS LONGCHAR.
    COPY-LOB FILE "c:/jca/temp/entity.xml" to lcXml.
    oRequest = RequestBuilder:POST(httpUrl, NEW OpenEdge.Core.String(lcXml))
                   :AcceptJson() /* we want to get JSON back */
                   // :UsingBasicAuthentication(oCredentials)
                   :Request.
     
     
    Da: Mike Fechner [mailto:bounce-mikefechner@community.progress.com]
    Inviato: venerdì, 11. maggio 2018 23:52
    A: TU.OE.Development@community.progress.com
    Oggetto: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    Update from Progress Community
     
    If xmlfile is a Character variable holding a file-name, the first parameter of the LOAD method should be “FILE”
     
    Von: Giancarlo Alberto Somma <bounce-obonelinux@community.progress.com>
    Gesendet: Freitag, 11.
    Mai 2018 22:21
    An:
    TU.OE.Development@community.progress.com
    Betreff: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    /cfs-file/__key/communityserver-discussions-components-files/19/380367.image001.png
    Update from Progress Community
    /cfs-file/__key/communityserver-discussions-components-files/19/5430.image002.jpg
     

    Hi Peter,

    I tried a lot of solutions without success. My problem is to define object for XML data file. An help is appreciate. Thx a lot in advance.

    xmlfile = "c:/jca/temp/entity.xml".

    hXmlRequestData:LOAD("LONGCHAR", xmlfile, FALSE).

    httpUrl = "obsv:5493/.../Clients".

    oXmlRequestData = NEW WidgetHandle(hXmlRequestData).

    oRequest = RequestBuilder:POST(httpUrl, oXMLRequestData):ContentType("application/xml")

                    :AcceptXml()

                    :Request.

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

    Das Bild wurde vom Absender entfernt.
     

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

     

     Mail priva di virus. www.avast.com
  • Server not accessible? Server software not started?
     
    (Personal) firewall active?
     
    Try to open a web browser on that address:
     
     
     
    Von: Giancarlo Alberto Somma <bounce-obonelinux@community.progress.com>
    Gesendet: Samstag, 12. Mai 2018 08:58
    An: TU.OE.Development@community.progress.com
    Betreff: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    /cfs-file/__key/communityserver-discussions-components-files/19/81351.image001.png
    Update from Progress Community
    /cfs-file/__key/communityserver-discussions-components-files/19/2746.image002.jpg
     
    Thanks Mike. That’s right. But I have another error:
     
     
    In both code.
     
    oRequest = RequestBuilder:POST(httpUrl, oXMLRequestData):ContentType("application/xml")
                     :AcceptXml()
                     // Add credentials to the request
                     //:UsingBasicAuthentication(oCredentials)
                     :Request.  */
                    
                   
    DEF VAR lcXml AS LONGCHAR.
    COPY-LOB FILE "c:/jca/temp/entity.xml" to lcXml.
    oRequest = RequestBuilder:POST(httpUrl, NEW OpenEdge.Core.String(lcXml))
                   :AcceptJson() /* we want to get JSON back */
                   // :UsingBasicAuthentication(oCredentials)
                   :Request.
     
     
    Da: Mike Fechner [mailto:bounce-mikefechner@community.progress.com]
    Inviato: venerdì, 11. maggio 2018 23:52
    A: TU.OE.Development@community.progress.com
    Oggetto: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    Update from Progress Community
     
    If xmlfile is a Character variable holding a file-name, the first parameter of the LOAD method should be “FILE”
     
    Von: Giancarlo Alberto Somma <bounce-obonelinux@community.progress.com>
    Gesendet: Freitag, 11.
    Mai 2018 22:21
    An:
    TU.OE.Development@community.progress.com
    Betreff: RE: [Technical Users - OE Development] OpenEdge.Net.pl
     
    /cfs-file/__key/communityserver-discussions-components-files/19/380367.image001.png
    Update from Progress Community
    /cfs-file/__key/communityserver-discussions-components-files/19/5430.image002.jpg
     

    Hi Peter,

    I tried a lot of solutions without success. My problem is to define object for XML data file. An help is appreciate. Thx a lot in advance.

    xmlfile = "c:/jca/temp/entity.xml".

    hXmlRequestData:LOAD("LONGCHAR", xmlfile, FALSE).

    httpUrl = "obsv:5493/.../Clients".

    oXmlRequestData = NEW WidgetHandle(hXmlRequestData).

    oRequest = RequestBuilder:POST(httpUrl, oXMLRequestData):ContentType("application/xml")

                    :AcceptXml()

                    :Request.

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

    Das Bild wurde vom Absender entfernt.
     

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

    Das Bild wurde vom Absender entfernt.
     
     
    Das Bild wurde vom Absender entfernt.
    Mail priva di virus. www.avast.com

    View online

     

    You received this notification because you subscribed to the forum.  To unsubscribe from only this thread, go here.

    Flag this post as spam/abuse.

    Das Bild wurde vom Absender entfernt.
     

    Architect of the SmartComponent Library and WinKit

    Consultingwerk Ltd.