Big data acquisitions pave way to fast, effective innovation - ZDNet Asia News http://t.co/vDZpl0lu
58 minutes ago by servicemarq on twitterZDNet is available in the following editions:
Discover client-side coding's many applications in ASP.NET, and see why using client-side code is often necessary to provide the desired result.
ASP.NET's codebehind structure provides a great way to separate application code from Web page markup and controls. While it is suitable for most situations, client-side code is not extinct.
There are many situations where client-side code may be more appropriate and sometimes the best approach. Let's explore the basics of client-side code usage and why it may be necessary.
Page structure
An ASP.NET page is comprised of the following elements:
As this list suggests, an ASP.NET page can become a bit overwhelming as the number of items included in a page escalate. Also, client-side code does not mean the codebehind model is not possible. The two may be combined as necessary depending on the situation.
You may be thinking that these elements resembled the older days of classic ASP development. It does seem to be true, but there are differences. Most notable is the fact that ASP only allowed the VBScript language. In addition, ASP.NET allows page directives to appear anywhere within a page while ASP restricted them to the top of the file.
Page elements in action
A simple example can easily demonstrate these elements used
on a sample ASP.NET page. The C# code in
Listing A is a good start. (Listing B
contains the VB.NET equivalent.) The code is simplistic, but it does demonstrate the elements
previously described. First, a couple server-side comments are utilized.
Developers often use such comments as reminders for themselves or fellow
developers. In addition, a code block is included in the header portion of the
HTML. The function (test) is called later in the page. In addition, a couple
inline code blocks are used to display output based upon values passed via the
URL QueryString (name/value pairs appended to page
address). The latter portion of the sample page issues a command to load
another file into that place in the file via the INCLUDE directive. The footer.aspx file includes basic HTML for including a
copyright statement on multiple pages:
<div id="footer">
©2005
</div>
Including the file on multiple pages allows the footer to be maintained in a central location. ASP.NET provides many other avenues for this type of functionality with a custom control being the most popular choice. The last element is the standard HTML that is sprinkled throughout the page with the most notable element being the header tag (<h1>).
Hiding elements
While the previous example demonstrates the basic usage of
various elements, there may be situations where one approach is necessary to
gain the required functionality. One good example is a recent application that
displayed buttons within a Repeater control based upon the type of user logged
into the application. One other application caveat was the use of JavaScript
and DHTML to present a tabbed interface where individual Repeater controls are
contained on each of three tabs—clicking one tab hid the other two tabs and
displayed the Repeater control for the tab selected.
Each row in the Repeater controls contained an edit button that was only displayed if the user was a certain type. Initially, button display was controlled via the Repeater control's ItemCreated event. While this did work upon initial page load, all related formatted was lost when different tabs were selected. That is, the ItemCreated event was only fired when the page was initially loaded or data control populated. It was not executed when client-side JavaScript or DHTML was executed. In fact, any formatting attained via the ItemCreated event was lost when JavaScript or DHTML code is processed. The workaround was utilizing client-side inline code to control element display. You may discover other situations where combining elements provides the desired effect.
Developer options
An ASP.NET page includes many elements that provide the
developer with many options for (often) completing a single task. You may use a
server-side include or develop a custom control for a common footer element for
all pages. In addition, you may place source code in a separate codebehind file or include code declaration blocks within
the ASP.NET page or even utilize inline code. You may reminisce about class ASP
coding when reviewing some of the elements, but they have changed. In the end,
the approach used in your application rests upon the development team.
Big data acquisitions pave way to fast, effective innovation - ZDNet Asia News http://t.co/vDZpl0lu
58 minutes ago by servicemarq on twitter"Big data acquisitions pave way to fast, effective innovation" including @Vivisimo_Inc (client) in @ZDnetAsia http://t.co/yNSdPqbb
58 minutes ago by FreestylePR on twitterHomegrown smartphone OSes gaining favor in China: 59 Jakarta 10350, Indonesia Locally-made mobile operating syst... http://t.co/BruP98Es
1 hour ago by SmartPhoneHonch on twitterRT @MDMGeek: Big data acquisitions pave way to fast, effective innovation - ZDNet Asia http://t.co/ky8YgPAn #Bigdata #analytics via @ciropuglisi
2 hours ago by data_nerd on twitterIntegration, focused investments to propel Windows Phone http://t.co/6JkDa9sB
2 hours ago by bestwaytoinvest on twitterRT @AsianFashionLaw: Malaysia offers some manufacturing benefits over China http://t.co/bMquIFiX
2 hours ago by Serend1p1ty9 on twitterAcquisitions in the Big Data market increasingly important to enterprises… http://t.co/Br4BkXyZ
2 hours ago by iProConLtd on twitterExperience trumps content in apps monetization http://t.co/iaCY5ebX
2 hours ago by monetize_me on twitterMalaysia offers some manufacturing benefits over China http://t.co/bMquIFiX
2 hours ago by AsianFashionLaw on twitterRT @MDMGeek: Big data acquisitions pave way to fast, effective innovation - ZDNet Asia http://t.co/ky8YgPAn #Bigdata #analytics via @ciropuglisi
2 hours ago by GarnieBolling on twitterThats it.Im digging up an old bus plan i wrote around acquisition of #bigdata talent. http://t.co/gpkha5A1 Any investors want2 read/discuss?
2 hours ago by BigDataInsights on twitterIntegration, focused investments to propel Windows Phone: By Kevin Kwang , ZDNet Asia on May 23, 2012 (2 mins ag... http://t.co/aaa0Cb73
3 hours ago by jamstrit on twitterHomegrown smartphone OSes gaining favor in China http://t.co/lOBVp1T6
3 hours ago by smartfone on twitterHomegrown smartphone OSes gaining favor in China: 59 Jakarta 10350, Indonesia Locally-made mobile operating syst... http://t.co/gHypbdIY
3 hours ago by androidnewshome on twitterIntegration, focused investments to propel Windows Phone - ZDNet Asia http://t.co/7sZi6Dhb
3 hours ago by sonuise on twitterSo much as we know , MTK6575 extremely integrated frequency1GHz ARM Cortex-A9 processor, the superiority of 3G / HSPA Modem, and help the...
1 day ago by y15822137359 on 5 SaaS adoption speed bumps to avoidI reckon your view: "CRM is strategy, not software", if a company replicating the approach uses in ERP implementation into CRM, what they...
2 days ago by wykoong on Gartner: Mobile CRM gives better ROI than socialThis video will teach you about the Excel fill handle but also provide you with a workook to download... http://www.youtube.com/watch?v=...
3 days ago by TradeBrother on A quick fill handle trick for Microsoft Excelwaiting...
5 days ago by eapete on What should count in a company's market value?Boy, you've opened a can of worms now.
Wait for the rants & raves.
I was puzzling before this whether to replicate the success formula we executed for a financial institute, and come out with a standard s...
5 days ago by wykoong on Drop the egos, copy ideas, then innovateThreats and malware know no boundaries. Neither should your web security. See how far Blue Coat Unified Web Security goes to protect your network.
Echelon 2012 - The Awesomer Tech Event in Asia
Echelon 2012 – SEA’s longest running tech startup event goes Awesomer. Catch 50 of Asia’s most promising startups & over 40 international speakers on June 11-12.
Startup Asia Jakarta showcases new product-ready tech startups. Plus: hackathon, exhibition, and speakers. Use promo code CBSi50 for 50% discount.
ZDNet Asia Intelligent Singapore video series
Featuring inteviews with CXOs who define "intelligence" in their markets and reveal how their companies drive business efficiencies through ICT.