vb.net - Class ' cannot be indexed because it has no default property -


i following error class 'propgenie_webservice.branch' cannot indexed because has no default property. , not sure why. have googled don't proper explanation or fix. c# welcome.

my code in branch.vb class:

public function update() branch     return update(me, path) 'error @ update. end function 

and in base class (resources.vb) have:

public shared function update(of t {resources, new})(resource t, path string) t         dim request = createrequest(path & "/{id}", method.patch)         request.addurlsegment("id", resource.id.tostring(cultureinfo.invariantculture))         request.addbody(resource)         dim client = createclient()         dim responce = client.execute(of t)(request)         if responce.statuscode <> httpstatuscode.ok             throw new invalidoperationexception("update failed" & convert.tostring(responce.statuscode))         end if         return responce.data     end function 

you need specify class in shared function also, or try use update function in object in.

public function update() branch     return resources.update(me, path) end function 

Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -