PHP
Server Uptime Statistics in PHP
JavaScript
this code block lets any scrollable control to scroll bottom not the page
C#
This Code Illustrates Method Hiding
PHP
Decoding HTML Entities in PHP
C#
C# Program to Display the Date in Various Formats
Java
Demonstrating method mouseDrag in Java
Delphi
This code shows the use of the TCalendar component. It uses a Calendar, some buttons, a checkbox, an edit box and some labels. Basic calendar cycling functionality is covered by the btnNextMonth, btnPrevMonth, btnNextYear, and btnPrevYear buttons.
C#
This code block clones a model with values and so that referencial changes does not affect new class.
Delphi
This example shows how to dynamically change the Vcl.Samples.Spin.TSpinButton.DownNumGlyphs and the Vcl.Samples.Spin.TSpinButton.DownGlyph of a Vcl.Samples.Spin.TSpinButton. The same principle is applied for Spin.TSpinButton.UpNumGlyphs and Spin.TSpinButton.UpNumGlyph. To do this example, you need two .bmp files that have drawn on them the 4 states of the button listed in Vcl.Samples.Spin.TSpinButton.DownGlyph. glyphd.bmp is used for the Down button and glyphu.bmp--for the Up button.
C#
This code blocks returns random number each call
C#
this code wll get you current or caller method names
JavaScript
Get Bing Image of the Day using C#
Bing Image of the Day has become quite popular over the years, it comprises of essentially the most spectacular user-submitted images from all over the world which have been showcased on the Bing homepage for the past 5 years.
The first step is to retrieve the JSON string from the Bing REST API endpoint. We retrieve the string using an HttpClient,we have an option of using Windows.Web.Http or System.Net.Http namespace. I prefer to choose Windows.Web.Http.HttpClient for the simple reason that the System.Net.Http.HttpClient might get deprecated over time. Another reason is that System.Net.Http.HttpClient supports only .Net Languages, whereas Windows.Web.Http.HttpClient was written with the aim of consolidating all the HTTP APIs for different Windows Application Languages, and therefore it supports all the Windows Store application languages. For the avid readers here is a detailed comparison between the two.
Step 2. Parse the JSON string:
Now we can parse the retrieved JSON string using 3 methods
• Using Windows.Data.Json (Native Way)
• Using LINQ-to-JSON API’s JObject from JSON.NET (Newtonsoft)
• Using dynamic object and DeserializeObject method JSON.NET (Newtonsoft)
JSON.Net has existed since long before Windows.Data.Json came into existence, however, Microsoft introduced Windows.Data.Json with native support for parsing JSON. To use JSON.NET, you need to add the Newtonsoft Nuget package, which adds an additional library dependency. I personally prefer the native way, however for the purpose of this app I have discussed both the ways of parsing the JSON string using both JSON.NET and Windows.Data.Json namespaces.
Delphi
This example shows how to use the TCanvas drawing functions and their results.
The TCanvas drawing functions are: DrawArc, DrawBitmap, DrawEllipse, DrawLine, DrawPath, DrawPolygon, DrawRect, DrawRectSides, CreateThumbnail.
To build and test this example, create a Multi-Device Application - Delphi and add the following controls on the form:
A TImage
A TGroupBox with nine TRadioButton objects (a radio button for each function). Change the TRadioButton.Text property for each radio button with the name of a function.
A TButton
A TOpenDialog
The example draws on the canvas of the bitmap. The bitmap is displayed on the TImage.
Java
A Ball Moving round the window in Java
PHP
Returning Numeric Array Indexes with MYSQL_NUM in PHP
C#
This Code Demonstrates Trigger Concept
C++
Implementation for stack in C++
C#
This Code Shows How to Select XML Nodes by Attribute Value
PHP
A very simple and efficient split bar the B-Z bar , for mysql and php
Contact Us