Geeks With Blogs


Agha Usman Ahmed JILAWATAN April 2009 Entries
Disable Special Keys in Win App C#
Today, when I was planning to write an article on Grid View. I got a message from a very good friend of mine who is asking to disable the special keys(Windows Keys) in his application. When I start researching on it, I was thinking that it can be done using e.KeyChar but unfortunately, it is not showing any information about windows keys. So in this post I will explain you, how can we disable the special keys (in our case windows keys) in C# Application. 1. Crete a c# windows application project ......

Posted On Sunday, April 26, 2009 11:32 PM

How to pass parameters to the dynamically added user control
In this post, I will explain how you can pass parameter to the dynamically added (from code behind) User Control. Most of you might aware of how we can achieve this in web application project. Following is the code for that 1: Dim objCon As Control = Page.LoadControl("~/Control... 2: Ctype(objCon,MyControl).Pro... = "Test" 3: Ctype(objCon,MyControl).Pro... = "USAM" 4: MyPanel.Controls.add(objCon) Now what if you have a web site project which does not have the pre-compiled ......

Posted On Wednesday, April 15, 2009 8:36 PM

Get Repeater Control Output in String
In this post I will share with you a small code snippet which will help you to get the repeater control output in string variable. 1: Dim sb As New StringBuilder() 2: Dim objHtml As New HtmlTextWriter(New System.IO.StringWriter(sb)) 3: 4: If dt.Rows.Count > 0 Then 5: Repeater1.DataSource = dt 6: Repeater1.DataBind() 7: End If 8: 9: Repeater1.RenderControl(obj... 10: Return sb.ToString() Well, I have used a little trick here. The RenderControl method of repeater control can put all the HTML in ......

Posted On Monday, April 13, 2009 8:29 PM

Copyright © Agha Usman Ahmed | Powered by: