umm... what is this error I see on every pages?
a[i].getAttribute("href") is null
It seems in this function: (line 33 is where it breaks)
| // Iterates through all the <a> links on a page and adds | |
| // them to the queue to be prefetched. | |
| function doEnhancedPrefetch(aEvent, pos) { | |
| // exit if enhanced prefetching is turned off | |
| // or if the site has opted out of prefetching | |
| if(!PreferencesService.getBoolPref("extensions.fasterfox.enhancedPrefetching")) return; | |
| // doc is document that triggered "onload" event | |
| var doc = aEvent.originalTarget; | |
| // if this isn't an http:// page, retun | |
| if (doc.location.href.indexOf("http://") != 0) return; | |
| // load whitelist | |
| var whitelist = PreferencesService.getCharPref("extensions.fasterfox.whitelist").split(","); | |
| var whitelistLen = whitelist.length; | |
| // find all links | |
| var a = doc.getElementsByTagName('a'); | |
| var href, numLinksToPrefetch, i, j; | |
| // prefetch a max of 100 links | |
| numLinksToPrefetch = (a.length>100) ? 100 : a.length; | |
| // if its the first time, set the pos to 0, | |
| // if a pos was passed in, we'll start the for loop there instead | |
| if (pos == null || pos <=0) pos = 0; | |
| // iterate through the links | |
| mainLinkLoop: | |
| for (i=pos; i<numLinksToPrefetch; i++) { | |
| href = a[i].getAttribute('href').toLowerCase(); | |
| // make sure there is a link | |
| if(href && href.length > 4) { | |
| // Don't prefetch links w/ query strings | |
| // or the same page we are on | |
| if(href.indexOf('?')>=0 || href == doc.location.href) continue; | |
| // Don't prefetch things that look like a logout link | |
| // Special thanks to b1naryb0y and Kai Risku for this bug fix | |
| if(href.indexOf('logout')>=0 || href.indexOf('logoff')>=0) continue; | |
| // Only prefetch static content, this causes dynamic pages to be ignored | |
| fileExtensionStartPos = href.length-4; | |
| if(!(href.indexOf('.htm') == fileExtensionStartPos | |
| || href.indexOf('.html') == fileExtensionStartPos-1 | |
| || href.indexOf('.jpg') == fileExtensionStartPos | |
| || href.indexOf('.gif') == fileExtensionStartPos | |
| || href.indexOf('.png') == fileExtensionStartPos | |
| || href.indexOf('.jpeg') == fileExtensionStartPos-1 | |
| || href.indexOf('.txt') == fileExtensionStartPos | |
| || href.indexOf('.text') == fileExtensionStartPos-1 | |
| || href.indexOf('.xml') == fileExtensionStartPos | |
| || href.indexOf('.pdf') == fileExtensionStartPos)) continue; | |
| // Don't prefetch whitelist links | |
| href = ff_GetAbsoluteUrl(href, doc.location.href); | |
| for(j=0; j<whitelistLen; j++) { | |
| if(whitelist[j].length > 0 && href.indexOf(whitelist[j]) >= 0) continue mainLinkLoop; | |
| } | |
| // test if site is opting out of prefetching | |
| var shouldOptOut = ff_IsSiteOptOut(href, aEvent, i); | |
| if(shouldOptOut) { | |
| continue; | |
| } else if (shouldOptOut == -1) { | |
| return; | |
| } | |
| try { | |
| PrefetchService.prefetchURI(ff_makeURI(ff_GetAbsoluteUrl(a[i].getAttribute('href'), doc.location.href)), ff_makeURI(doc.location.href), true); | |
| } catch(e) { | |
| //if(e.name != "NS_ERROR_ABORT") alert(ff_GetAbsoluteUrl(href, doc.location.href) + '\n' + e.toString()); | |
| } | |
| } | |
| } | |
| } | |
| Public Sub AddAppointments() |
| RadCal.Appointments.Clear() |
| Dim rd As SqlClient.SqlDataReader = Data.SqlHelper.ExecuteReader(ConnString, "dbo.JobSelect") |
| While rd.Read |
| Dim range As New RecurrenceRange |
| range.Start = rd.GetDateTime(12) |
| range.EventDuration = rd.GetDateTime(13) - rd.GetDateTime(12) |
| Select Case rd.GetInt32(5) |
| Case 4 |
| Dim DailyRR As New DailyRecurrenceRule(rd.GetInt32(6), range) |
| Dim da As New Appointment(rd.GetInt32(0), rd.GetDateTime(12), rd.GetDateTime(13), rd.GetString(1), DailyRR.ToString) |
| RadCal.InsertAppointment(da) |
| RadCal.DataKeyField = da.ID |
| RadCal.DataStartField = da.Start |
| RadCal.DataEndField = da.End |
| RadCal.DataSubjectField = da.Subject |
| Case 8 |
| Dim WeeklyRR As New WeeklyRecurrenceRule(rd.GetInt32(10), rd.GetInt32(6), range) |
| Dim da As New Appointment(rd.GetInt32(0), rd.GetDateTime(12), rd.GetDateTime(13), rd.GetString(1), WeeklyRR.ToString) |
| RadCal.InsertAppointment(da) |
| RadCal.DataKeyField = da.ID |
| RadCal.DataStartField = da.Start |
| RadCal.DataEndField = da.End |
| RadCal.DataSubjectField = da.Subject |
| Case 16 |
| Dim MonthlyRR As New MonthlyRecurrenceRule(rd.GetInt32(6), rd.GetInt32(10), range) |
| Dim da As New Appointment(rd.GetInt32(0), rd.GetDateTime(12), rd.GetDateTime(13), rd.GetString(1), MonthlyRR.ToString) |
| RadCal.InsertAppointment(da) |
| RadCal.DataKeyField = da.ID |
| RadCal.DataStartField = da.Start |
| RadCal.DataEndField = da.End |
| RadCal.DataSubjectField = da.Subject |
| Case 32 |
| Dim MonthlyRelativeRR As New MonthlyRecurrenceRule(rd.GetInt32(9), rd.GetInt32(6), rd.GetInt32(10), range) |
| Dim da As New Appointment(rd.GetInt32(0), rd.GetDateTime(12), rd.GetDateTime(13), rd.GetString(1), MonthlyRelativeRR.ToString) |
| RadCal.InsertAppointment(da) |
| RadCal.DataKeyField = da.ID |
| RadCal.DataStartField = da.Start |
| RadCal.DataEndField = da.End |
| RadCal.DataSubjectField = da.Subject |
| End Select |
| End While |
| rd.Close() |
| End Sub |
| <%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Site1.master.cs" Inherits="TelerikTools.Site1" %> | |
| <%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %> | |
| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | |
| <html xmlns="http://www.w3.org/1999/xhtml" > | |
| <head runat="server"> | |
| <title>Untitled Page</title> | |
| <asp:ContentPlaceHolder ID="head" runat="server"> | |
| </asp:ContentPlaceHolder> | |
| </head> | |
| <body> | |
| <form id="form1" runat="server"> | |
| <div> | |
| <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> | |
| </telerik:RadAjaxManager> | |
| <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server"> | |
| </asp:ContentPlaceHolder> | |
| <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" Runat="server" | |
| height="75px" InitialDelayTime="10" IsSticky="True" MinDisplayTime="5000" | |
| width="75px"> | |
| <img alt="Loading..." src="RadControls/Ajax/Skins/Default/loading1.gif" | |
| style="border:0px;" /><br /> | |
| Add Some Text | |
| </telerik:RadAjaxLoadingPanel> | |
| </div> | |
| </form> | |
| </body> | |
| </html> |
| <%@ Page Language="C#" MasterPageFile="~/Site1.Master" AutoEventWireup="true" CodeBehind="RadAjaxManager.aspx.cs" Inherits="TelerikTools.RadAjaxManager" %> | |
| <%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %> | |
| <asp:Content ID="Content1" runat=server ContentPlaceHolderID=ContentPlaceHolder1> | |
| <div> | |
| <telerik:RadScriptManager ID="RadScriptManager1" Runat="server"> | |
| </telerik:RadScriptManager> | |
| </div> | |
| <asp:CheckBox ID="CheckBox1" runat="server" AutoPostBack="True" | |
| oncheckedchanged="CheckBox1_CheckedChanged" Text="Check Me" /> | |
| <asp:Label ID="Label1" runat="server"></asp:Label> | |
| <telerik:RadGrid ID="RadGrid1" runat="server" AllowPaging="True" | |
| DataSourceID="SqlDataSource1" GridLines="None"> | |
| <MasterTableView AutoGenerateColumns="False" DataSourceID="SqlDataSource1"> | |
| <RowIndicatorColumn> | |
| <HeaderStyle Width="20px"></HeaderStyle> | |
| </RowIndicatorColumn> | |
| <ExpandCollapseColumn> | |
| <HeaderStyle Width="20px"></HeaderStyle> | |
| </ExpandCollapseColumn> | |
| <Columns> | |
| <telerik:GridBoundColumn DataField="STATE_NM" EmptyDataText="&nbsp;" | |
| HeaderText="STATE_NM" SortExpression="STATE_NM" UniqueName="STATE_NM"> | |
| </telerik:GridBoundColumn> | |
| <telerik:GridBoundColumn DataField="CITY_NM" EmptyDataText="&nbsp;" | |
| HeaderText="CITY_NM" SortExpression="CITY_NM" UniqueName="CITY_NM"> | |
| </telerik:GridBoundColumn> | |
| <telerik:GridBoundColumn DataField="ZIPCODE" EmptyDataText="&nbsp;" | |
| HeaderText="ZIPCODE" SortExpression="ZIPCODE" UniqueName="ZIPCODE"> | |
| </telerik:GridBoundColumn> | |
| </Columns> | |
| <PagerStyle Mode="NextPrevAndNumeric" /> | |
| </MasterTableView> | |
| <FilterMenu EnableTheming="True"> | |
| <CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation> | |
| </FilterMenu> | |
| </telerik:RadGrid> | |
| <asp:SqlDataSource ID="SqlDataSource1" runat="server" | |
| ConnectionString="<%$ ConnectionStrings:ConnectionString %>" | |
| ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>" | |
| SelectCommand="SELECT "STATE_NM", "CITY_NM", "ZIPCODE" FROM "TBL_STATECITY_V""> | |
| </asp:SqlDataSource> | |
| <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"> | |
| <AjaxSettings> | |
| <telerik:AjaxSetting AjaxControlID="CheckBox1"> | |
| <UpdatedControls> | |
| <telerik:AjaxUpdatedControl ControlID="Label1" /> | |
| </UpdatedControls> | |
| </telerik:AjaxSetting> | |
| <telerik:AjaxSetting AjaxControlID="RadGrid1"> | |
| <UpdatedControls> | |
| <telerik:AjaxUpdatedControl ControlID="RadGrid1" /> | |
| </UpdatedControls> | |
| </telerik:AjaxSetting> | |
| </AjaxSettings> | |
| </telerik:RadAjaxManagerProxy> | |
| </asp:Content> |
| using System; | |
| using System.Collections; | |
| using System.Configuration; | |
| using System.Data; | |
| using System.Linq; | |
| using System.Web; | |
| using System.Web.Security; | |
| using System.Web.UI; | |
| using System.Web.UI.HtmlControls; | |
| using System.Web.UI.WebControls; | |
| using System.Web.UI.WebControls.WebParts; | |
| using System.Xml.Linq; | |
| namespace TelerikTools | |
| { | |
| public partial class RadAjaxManager : System.Web.UI.Page | |
| { | |
| protected void Page_Load(object sender, EventArgs e) | |
| { | |
| } | |
| protected void CheckBox1_CheckedChanged(object sender, EventArgs e) | |
| { | |
| System.Threading.Thread.Sleep(1000); | |
| if (CheckBox1.Checked) | |
| { | |
| Label1.Text = "This box is checked"; | |
| } | |
| else | |
| { | |
| Label1.Text = "The box is NOT checked"; | |
| } | |
| } | |
| } | |
| } | |
| <telerik:RadGrid ID="RadGrid1" runat="server" BorderColor="Black" |
| DataSourceID="SqlDataSource1" OnColumnCreated="RadGrid1_ColumnCreated" |
| AutoGenerateColumns="False" GridLines="None" > |
| <ClientSettings> |
| <Scrolling AllowScroll="True" UseStaticHeaders="True" |
| FrozenColumnsCount="1"> |
| </Scrolling> |
| </ClientSettings> |
Hopefully this is a very easy one. How do I set the selected text property declaritively with the bind syntax? I do not want selectedvalue, i need to use SelectedText or the Telerik equivalent?
This does not work and there is no "SelectedText" property:
| <telerik:RadComboBox ID="rcbCategory" runat="server" |
| DataSourceID="odsCategories" DataTextField="Category" |
| DataValueField="CategoryID" Width="75px" |
| ShowDropDownOnTextboxClick="true" |
| Height="150px" Text='<%# Bind("CategoryName") %>'> |
| </telerik:RadComboBox> |
Thanks!
If
(TypeOf (e.Item) Is GridDataItem) Then
Dim dataBoundItem As GridDataItem = Nothing
Dim bFound As Boolean = False
Try
dataBoundItem = e.Item
If Session("sessSaveIds") <> "" Then
Dim sArrayString As String = Session("sessSaveIds")
Dim sArray() As String = sArrayString.Split(",")
Dim sID As String
For Each sID In sArray
If dataBoundItem("user_id").Text = sID Then
bFound =
True
Exit For
End If
Next
If bFound = True Then
dataBoundItem.Edit =
True
Else
dataBoundItem.Edit =
False
End If
End If ...