-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some examples in C# #1
Comments
First thing is to get the unit tests supplied with the project working.Run a test (it will probably fail) - this will create a settings file in your personal app settings folder (see readme for where that is). Edit it to put in your Nextcloud server url, your login name and password, etc. Make sure login tests are set to run (in the settings file). Then run the tests again, starting with login. Regards Nikki On 24 Dec 2019 8:27 am, Carsten Giesen <[email protected]> wrote:Dear Nikki,
I just start to use your API.
I'm a really newby in NextCloud! Thats why I run in lot of errors.
Are thre some examples for C# and FW472 for testing an looking?
In the momentI allways run in this error:
"the requested address is not valid in its context" in line 670 api.cs and I didn't know, is that a error from my NextCloud server or an error of my coding.
Regards Carsten
—You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or unsubscribe.
|
Thats the problem. I see the folder, but no setting.json or TestSettings.json for that, save must be called, but isn't I change the code, if no JSON file, create one. But I get the error by this row: "listener.Bind(localEndPoint);"
Perhaps wrong settings in JSON, but I didn't have any idea, whats the correct on. |
Why not put in a call to save?Regards Nikki On 24 Dec 2019 11:55, Carsten Giesen <[email protected]> wrote:Thats the problem. I see the folder, but no setting.json or TestSettings.json
for that, save must be called, but isn't
—You are receiving this because you commented.Reply to this email directly, view it on GitHub, or unsubscribe.
|
a Demo for the TestSettings.json would be Nice.... |
Yes, that would be nice! Even a bit more descriptions of how to. |
Hi, news about this issue? we have a demo of this file? |
Hi, I just managed to create a TestSettings.json file in the
I did set all the fields marked with
I think it would be nice to include this settings file in the repo too. Can anyone test and confirm this? |
This is great stuff! Here is a short C# console app written in VS 2022 (.Net Framework 4.8) that illustrates one function: using System; namespace NextcloudHelper
} You will need to reference Newtonsoft.Json 12.0.2 and MimeMapping 1.0.1.12 from Nuget. What I would like to know is how do you form the link to a file that I can provide to an eligible user for them to access/download the file from Nextcloud? You can copy the internal link to the clipboard in Nextcloud, which looks something like: How can I derive this internal link programmatically? |
Answer to my question (pretty simple) - Insert these lines:
|
Dear Nikki,
I just start to use your API.
I'm a really newby in NextCloud! Thats why I run in lot of errors.
Are thre some examples for C# and FW472 for testing an looking?
In the momentI allways run in this error:
"the requested address is not valid in its context" in line 670 api.cs and I didn't know, is that a error from my NextCloud server or an error of my coding.
Regards Carsten
The text was updated successfully, but these errors were encountered: