What can you learn here?
- sing cRest
- Advanced capabilities
- Building new libraries
Accessing the cRest class directly get it now
Try it out first ?
- jObjects As Collection
- Returns a collection of cJobject, one for each query executed since the object was initialized
- jObject() As cJobject.
- Returns the latest cJobject to be deserialized. In other words, the response to the last query executed.
- erType() As erRestType.
- Returns enum erRestType to indicate the type of query, erSingleQuery or erQueryPerRow being executed.
- response() As String
- Returns the raw response received from the last query executed
- encodedUri() As String
- Returns the URI and query that was sent in encoded http format
- queryhCell() As cCell
- Returns a cCell Class representing the column header being used to generated erQueryPerRow queries.
- queryString(p As String)
- sets the queryString that will be encoded into the encodedUri
- restUrlStem(p As String)
- Sets the Rest Url that will be encoded into encodedUri
- dSet() As cDataSet
- returns the cDataSet that represents the abstraction of the worksheet being processed
How to use cRest
Public Sub testcrdirect() Dim cr As New cRest, dset As New cDataSet cr.init("responseData.results", erSingleQuery, , , _ dset.populateData(wholeSheet("patent"), , "patent", , , , True), , _ "https://ajax.googleapis.com/ajax/services/search/patent?v=1.0&rsz=8&q=", _ , False).execute "excel" End Sub
Here’s the code for cRest