What is an Literal Control.

The Literal control is similar to the Label control, except the Literal control does not enable you to apply a style to the displayed text.. <div> <asp:Literal ID=’Literal1′ runat=’server’></asp:Literal> </div> protected void Page_Load(object sender, EventArgs e) { Literal1.Text = ‘LiteralTextDemo’; } Now the Resultant text will be in the format: LiteralTextDemo

How to make VS.Net use FlowLayout as the default layout rather than the GridLayout

For VB.NET, go to path C:\Program Files\Microsoft Visual Studio .NET\Vb7\VBWizards\WebForm\Templates\1033 Change the following line in the existing WebForm1.aspx <body MS_POSITIONING='[!output DEFAULT_HTML_LAYOUT]’> to <body> For C#, go to path C:\Program Files\Microsoft Visual Studio .NET 2003\VC#\VC#Wizards\CSharpWebAppWiz\Templates\1033 Change the following line in the existing WebForm1.aspx <body MS_POSITIONING='[!output DEFAULT_HTML_LAYOUT]’> to <body> Note:Before changing any templates it’s a good idea to make backup copies of them Or rather than above approach you can change the behavior for new files on a per project basis in Visual Studio by: Right clicking on the project name (Ex: ‘WebApplication1)’ in Solution Explorer, and select ‘Properties’. From project properties window, under Common Properties>Designer Defaults>Page Layout change ‘Grid’ to ‘Flow’.

How can I access a webpage from a windows form

Use the WebRequest class found in the System.Net namespace. //create the request object WebRequest req = WebRequest.Create(@’http://www.syncfusion.com’); //get the response and use the response WebResponse resp = req.GetResponse(); Stream stream = resp.GetResponseStream(); StreamReader sr = new StreamReader(stream); string s = sr.ReadToEnd(); textBox1.Text = s;

Is it possible to identify the source webpage where I came from?

You can identify the source webpage using the document.referrer command. The document object is the page currently loaded in the browser window – presumably your Web page. The referrer property is the page the visitor was at immediately prior to visiting the current page. You can code it as, functionIdentifySourceWebPage() { if(document.referrer != ’’) document.write(’You came from ’ + document.referrer); }

How to draw a shadow for a given transparent image?

The following method will draw a shadow of the supplied image at the specified location. The general usage pattern is to call this method first to draw a shadow at a (2,2) offset from where the original image will be drawn and then draw the original image itself. public static void DrawShadow(Graphics g, Image iconImage, int left, int top) { ImageAttributes ia = new ImageAttributes(); ColorMatrix cm = new ColorMatrix(); cm.Matrix00 = 0; cm.Matrix11 = 0; cm.Matrix22 = 0; cm.Matrix33 = 0.25f; ia.SetColorMatrix(cm); g.DrawImage(iconImage, new Rectangle(left, top, iconImage.Width, iconImage.Height), 0, 0, iconImage.Width, iconImage.Height, GraphicsUnit.Pixel, ia); }