This project was made to showcase what you could do with my Cloudflare Resolver API & async programming
Uses JSON.NET to deserialize JSON response from the API
Download source code here: https://a.pomf.cat/lpqoqk.zip
DO NOT DEAL WITH THIS MEMBER
Feb 12, 2017 08:33 AM
(This post was last modified: Feb 12, 2017 08:35 AM by Ninja.)
Try using GitHub my man. This way I dont have to download, extract, etc. to view your code.
EDIT: This is just an over-hyped API... I mean, you just need like 4 lines of code to do all this, and that includes a using statement.
Feb 13, 2017 11:38 PM
(This post was last modified: Feb 14, 2017 04:35 AM by xaHyeG.)
![[Image: wuTJduD.jpg]](https://i.imgur.com/wuTJduD.jpg) If it is " human", you can NOT " trust" it. If it is " alien" you will find it at NASA. If it is " ape" you have already been robbed.. If it is "me" I will say HI!
I can tell when someone is bad just by looking at the file and element name.
Also, code in Form, sshhhh.
Feb 14, 2017 06:00 AM
(This post was last modified: Feb 14, 2017 06:10 AM by gigajew.)
(Feb 13, 2017 11:38 PM)xaHyeG Wrote: its just http://resolvr.cf/?resolve=cloudflare&host=
well good start at c#
What do you mean? I made it to showcase my API..
(Feb 14, 2017 04:13 AM)Sakuto Wrote: I can tell when someone is bad just by looking at the file and element name.
Also, code in Form, sshhhh.
Why would there be anything wrong with putting code in the main form.cs? It's perfectly fine. Yes I'm sure you're an expert at finding bad code by only looking at names and where the code is (sarcasm in case you didn't pick it up by the post title)
Anyhow, the code consists of
API.cs (main functionality, which you'd know if you could read code)
Form1.cs (interface)
Program.cs (auto generated winforms logic)
</bash>
(Feb 12, 2017 08:33 AM)Ninja Wrote: Try using GitHub my man. This way I dont have to download, extract, etc. to view your code.
EDIT: This is just an over-hyped API... I mean, you just need like 4 lines of code to do all this, and that includes a using statement.
Are you talking about the API, or the program?
Feb 14, 2017 08:43 PM
(This post was last modified: Feb 14, 2017 08:51 PM by SL x TnT.)
(Feb 14, 2017 06:00 AM)gigajew Wrote: Why would there be anything wrong with putting code in the main form.cs? It's perfectly fine.
=Removed initial post=
Decided to take a look at the code. Honestly doesn't look bad. Thought it would've been the typical "everything in the form class" from the other guy's post.
"textBox1", "checkBox1", and "listView1" <- That really needs to be named better.
Looks like you're using JSON.Net too. In that case, name your properties better.
Code public class FullResult
{
[JsonProperty("host")]
public string Host { get; set; }
[JsonProperty("host_ipv4")]
public string HostIPv4 { get; set; }
}
You have a method in your form who perform something and contain logic, it does not belong here, that's all. You should have a service to handle this.
The form class are just here to bind event, nothing more.
|