Nice. Thanks!
CodeHawkz
Posts
-
CodeProject Infrastructure - Network Configuration, Sever Specifications -
CodeProject Infrastructure - Network Configuration, Sever Specificationsjeez thanks
-
CodeProject InfrastructureOh, I am sorry. I understood it differently. Thank you for your articles, I am reading them at the moment. They seem to have alot on ASP.NET side of the website, very informative. Regards
-
CodeProject Infrastructure - Network Configuration, Sever SpecificationsHey, With all the buzz going on about with No-SQL being faster and better than SQL Server like RDBMS systems, I am not sure I am agree. Therefore, I am collecting evidence to build a case that websites like CodeProject, StackOverflow still manage to keep the performance of the website pretty high while having a RDBMS in the back-end. Therefore, I would like to get some information on your servers, network configuration, load balancers, etc. I found an article in StackOverflow elaborating on their configuration in detail (see link below). I couldn't find anything like that on CodeProject, so something similar would be highly appreciated. http://meta.stackoverflow.com/questions/10369/which-tools-and-technologies-are-used-to-build-the-stack-exchange-network[^] Kind Regards
-
CodeProject InfrastructureHey, sorry if I didn't post enough information for you to answer my question. I am interested in the web servers, operating systems, database servers (including innformation on Processors, RAM, SSDs, hard disks, etc.) that CodeProject uses. Basically, it's the architecture that I am interested. If you are still confused, take a look at the link below. http://meta.stackoverflow.com/questions/10369/which-tools-and-technologies-are-used-to-build-the-stack-exchange-network[^] Cheers
-
CodeProject InfrastructureWill do, thanks
-
CodeProject InfrastructureDoes anyone know about what tools and technologies are used to develop CodeProject? I am also interested in the hardware configuration. I tried to search for it, but couldn't find any information on it. I would appreciate it if anyone can share that information
-
Microscopes. They should be banned.Look at this also[^] Perhaps, this might make you like microscopes :P
-
Which code you suggest?First of all, the second code should have a 'break' as follows. Otherwise, it just continues to loop pointlessly, even if it find "ABC" in the first item.
Boolean DoSomething(string[] values)
{
bool retValue = false;
foreach (string s in values)
{
if (s == "ABC")
{
retValue=true;
break;
}
}
return retValue;
}Personally, I choose the this method over your first method, since it has a single point of return to the method. About the performance, both versions should be identical as this method would only execute 2 steps extra.
-
Clean Code Cheat SheetNice :thumbsup:
-
Method chaining with short-circuit parameter evaluationThe first code block doesn't make any sense to me but this line
var result = Test.NotNull(myObject).NotNull(myObject.MyProperty).IsPositive(myObject.MyProperty.Id);
can be represented like this, can't you?
var result = (myObject == null ? false: myObject.MyProperty == null ? false : IsPositive(myObject.MyProperty.Id);
Just bouncing off an idea :) P.S. You can do it much simpler by using exceptions, I believe Cheers
-
Look what I did on my summer breakAwesome stuff! keep it up
-
Awesome new look CodeProjectI know this is a duplcate thread, but the new look is brilliant! Got few things to brush up in it I guess, but nothing critical. Good luck! :-D :laugh: ;) ;P :thumbsup::thumbsup:
-
A liitle help on submitting a json array, no-primitive to a web servicehehe :) It's my pleasure to have a good discussion and help someone out. XML is not slow for your eye, but it's really slow when it comes to traversing the nodes (i.e. compared to others of course). Anyways, am sure for your purpose it won't effect much. However I'll try to write a sample code that would perform json serialization easily, over the weekend, and share it. regards
-
A liitle help on submitting a json array, no-primitive to a web serviceHey there, I am sorry about the really late reply. But I've been working with web technologies and XML manipulation much. One thing I've learnt is that XML is great for data transferring but it's slow and heavy. For instance, if you want to send one piece of data that is huge XML is fine. But if you want to send lots of small pieces of data, the number of tags generated for each small object, adds an unnecessary weight. I hope this gives you the basic idea of what I mean. I won't have time to write a fully generalized JSON class :( But it should be really easy to write a logic to generalize your specific class without using XML. Let me know if you still want it. Basic idea for it would be to implement an interface on all the classes you want to JSONify (I made that word up :P) and pass it on to a special class. The implementation of the interface would return a JSON data string for that specific object. The special class would bind them all to one piece of data. Hope this helps, Regards
-
A liitle help on submitting a json array, no-primitive to a web serviceWoahh.. That's one long solution :omg: I think you can simplify that solution by compiling the logic into one class using a dictionary object or a stringbuilder object internally to hold the data. I will post a sample, if I get time around one of these days.
-
A liitle help on submitting a json array, no-primitive to a web serviceHey there, Glad it worked out. Post your method here as well, so I can see whether I can improve my solution :) ExpandoObject Documentation[^] JSON Library[^] that I used
// This only works in .NET 4.0
dynamic result = new ExpandoObject();
IDictionary resultData = (IDictionary)result;resultData.add("templateName", "tshirts");
var templateArray = new [] {
new { Name = "Red", Code = "RED" },
new { Name = "Green", Code = "GRN" },
new { Name = "Blue", Code = "BLU" }
};resultData.add("templateArray", templateArray);
string jsonString = JsonConvert.SerializeObject(result);
This will output a JSON string like the one you initially mentioned. I think the code is self explanatory. Feel free to reach out for further clarifications. Hope this helps, cheers
-
window openThere are 2 ways that you can achieve this. 1. Use a Ajax call to the other page and based on the result you get, you can update the current page. This is the easiest way. 2. Use a normal postback to the server, to the other page. While you do that, post the current URL as a parameter too. So in the other page, perform your logic, redirect to the passed URL and use session (recommended) or viewstate or some data store to send the values that you want to update the other page :) Hope this helps and makes sense Regards
-
window openYour question is vague. We cannot help you unless you mention the specifics. What do you want to do? Do you want to redirect user to another page when the user clicks on a link? Or do you want to post data to another page? Or do you want to post data to server and redirect the user based on the response you get?
-
A liitle help on submitting a json array, no-primitive to a web serviceI dealt with this problem just yesterday. I found a really really convenient way to that. But I am horrible with VB.Net otherwise I could have helped you out. Do you think if I post the C# code, you would be able to figure the VB.Net version of it? Btw, my methods only works with .Net Framework 3.0 and above. Is that what you use? If it's 4.0 I can give you a very easy method :)