Blog Archives

Knockoutjs and Jquery UI Slider

How to filter an observable array based on Jquery UI slider using knockoutJs: Html <span id=”minFare” data-bind=”text : minFare”></span> &nbsp;&nbsp;-&nbsp;&nbsp;Rs&nbsp; <span id=”maxFare” data-bind=”text : maxFare”></span> <div id=”slider-range”></div> Js //Min & Max Slider function vm() { var self = this; self.minFare

Tagged with: , ,
Posted in Asp.Net, Jquery UI, KnockoutJS, MVC

Best way to Parse Query String value in Asp.Net

Best way to parse query string value in Asp.Net //Use it string cityCode = Request.QueryString.GetValue<string>(“City”); //Extension method public static T GetValue<T>(this NameValueCollection collection, string key)         {             if (collection == null)             {                 throw new ArgumentNullException(“collection”);             }

Tagged with: ,
Posted in .Net, Asp.Net, C#

Export MS Chart to PDF using Itextsharp in Asp.Net

Export MS Chart to PDF in Asp.Net Using itextsharp, export ms chart into pdf file I am rendering a chart using chart control in asp.Net 4.0. Now we want to export that chart image into pdf file. Interesting point is,

Tagged with: , , , ,
Posted in .Net, Asp.Net, C#, ms Chart

Bar Chart random color in asp.Net

Display bars in random colors: IDictionary<string, int> list= new Dictionary<string, int>(); list.Add(“Val 1”, 90); list.Add(“Val  2”, 89); list.Add(“Val 3”, 50); list.Add(“Val 5”, 87); chrtBar2.Series[“Categories”].XValueMember = “key”; chrtBar2.Series[“Categories”].YValueMembers = “value”; chrtBar2.ChartAreas[“MainChartArea”].AxisX.MajorGrid.Enabled = false; chrtBar2.ChartAreas[“MainChartArea”].AxisX.MajorTickMark.Enabled = true; chrtBar2.ChartAreas[“MainChartArea”].AxisX.MinorGrid.Enabled = false; chrtBar2.ChartAreas[“MainChartArea”].AxisX.MinorTickMark.Enabled =

Tagged with: , , ,
Posted in .Net, Asp.Net, C#

Wrap Label Text in

Today I found one issue with my site, that is a label text was not wrapped and display continued. Found finally working solution:  <div style=”float:left;overflow-y:auto;overflow-x:auto; word-break:break-all;”> <asp:Label ID=”lbDesc” runat=”server” /> </div>

Tagged with: ,
Posted in Asp.Net 4.0 web form routing in iis7

Today I have completed my first phase of the project on Asp.Net 4.0 and I have implemented Web Form routing feature. It was working fine on VS inbuilt IIS server but when I deployed on IIS server, it was not

Tagged with: ,
Posted in Asp.Net, IIS7

RadioButtonList change event in jquery

Trap RedioButtonList change event in Jqury OR RadioButtonList selected value in Jquery: <asp:RadioButtonList ID=”rblBannerType” ClientIDMode=”Static” runat=”server”  RepeatDirection=”Horizontal” > <asp:ListItem Value=”image” Selected=”True”>Image</asp:ListItem> <asp:ListItem Text=”html” >Html</asp:ListItem> </asp:RadioButtonList>  //jquery script <script> $(function () { var t = $(“#rblBannerType input:checked”).val(); SetBannerType(t); //Banner Type $(“#rblBannerType”).change(function () { var type = $(“#rblBannerType input:checked”).val(); SetBannerType(type); }); }); function SetBannerType(type) { if (type == “image”) { $(“#divImage”).show(); $(“#divHtml”).hide(); } else { $(“#divHtml”).show(); $(“#divImage”).hide(); } } </script>

Tagged with: ,
Posted in Asp.Net, C#
Top Rated

Error: Please make sure the Twitter account is public.

Blog Stats
  • 30,874 hits