Telerik Forums
UI for ASP.NET AJAX Forum
7 answers
156 views

I am using a radgrid to display data. I want to place a banner on the pdf file that gets downloaded.

this is my code:

<PageHeader>
<MiddleCell Text="<img src='Images/CME-Transcript-HeaderLong.jpg' />" TextAlign="Center" />

<RightCell TextAlign="Center" />
</PageHeader>

 

this inserts a small image in the center but I need it to be displayed as the same length as my radgrid on the pdf. How do I change the size of this image to make it a banner size?

 

Also, I am displaying some data generated dynamically in the middle of the header. I need to move it below the header but before the radgrid on the pdf. I need to display it in a horizontal line above the grid. How do I go about changing the position of data?

 

headerText += "<br /><span style='font-size:8px;font-family:Segoe UI;'>Report Date: " + DateTime.Now.Date.ToShortDateString() + "</span>" ;
headerText += "<br /><span style='font-size:8px; font-family:Segoe UI;'>" + lblParticipantName.Text + "</span>";
headerText += "<br /><span style='font-size:8px; font-family:Segoe UI;'>SDMS Member #: " + lblNo.Text + "</span>";

RadGrid1.ExportSettings.Pdf.PageHeader.RightCell.Text = headerText;

Thanks,

Kostadin
Telerik team
 answered on 09 Jun 2015
5 answers
253 views
i have use RadAutoCompleteBox control in asp.net. and  everything working fine but i have one problem.

when i type in autocomplete text both then its show me result in
dropdown and when i click out side of that dropdown (without select any
item from result) then first item automatically selected :(.

i don't need auto selection until i hit enter or click on item.

How can i do it?

Thanks,
Hiren Suthar
Plamen
Telerik team
 answered on 09 Jun 2015
5 answers
238 views
Hi,

I'm trying to setup a RadTreeList with a nested RadGrid in one of the columns using a TemplateColumn. I've had a look at some of the demo's on the Telerik site with nested grids but I haven't been able to figure out how to pass the Key Id of the TreeList row to the Grid so the correct data is loaded into the grid. I'm using a SQLDataSource like some of the examples on the telerik demo's which uses a session parameter but I haven't figured out how this is set? (no sessions are set in the code behind in the demo's)

Any help would be great,

Thanks,
JC
Angel Petrov
Telerik team
 answered on 09 Jun 2015
1 answer
82 views
First of all, my apologies for the length of this post.

Could you please advise me on this problem? When I click on the down
arrow shown in the image below:

I get the following error message:  Cannot find a cell bound to colunm name ‘EditColumn’

The MasterTable is populated by a stored
procedure and bound by an ItemDataBound subroutine in the vb codebehind. The
Detail Table is populated using a different stored procedure by the following
subroutine:

Protected Sub rgvObjective_DetailTableDataBind(source As Object, e As Telerik.Web.UI.GridDetailTableDataBindEventArgs) Handles rgvObjective.DetailTableDataBind

        Dim dataItem As GridDataItem = DirectCast(e.DetailTableView.ParentItem, GridDataItem)

        Dim poid = Integer.Parse(dataItem.GetDataKeyValue("PO_ID"))

        Dim dd As New CSREntities

        e.DetailTableView.DataSource =
dd.usp_ProjectIndicator_Get_Grid(poid)

   
End Sub

Both stored procedures bring back PO_ID.

 

Thank you,

Jerry Saunders

 

The code is as follows:

<telerik:RadGrid ID="rgvObjective" EnableEmbeddedSkins="false" Skin="MySkin" AllowSorting="True" OnDetailTableUpdateCommand="rgvObjective_DetailTableUpdateCommand"
AutoGenerateColumns="False" runat="server" CellSpacing="0" GridLines="None" PageSize="20" OnDetailTableDataBind="rgvObjective_DetailTableDataBind"

AllowPaging="true" PagerStyle-AlwaysVisible="true"

OnNeedDataSource="rgvObjective_NeedDataSource"  AllowResizeToFit="true"
OnUpdateCommand="rgvObjective_UpdateCommand" OnDeleteCommand="rgvObjective_DeleteCommand" OnInsertCommand="rgvObjective_InsertCommand">

<MasterTableView DataKeyNames="PO_ID" CommandItemDisplay="Top" EditMode="InPlace" Name="POID">

  <HeaderStyle Font-Bold="true" />

    <NoRecordsTemplate>

       <div class="emptyGrid">

          No objectives found.

       </div>

    </NoRecordsTemplate>

    <DetailTables>

      <telerik:GridTableView DataKeyNames="PI_INDICATOR" CommandItemDisplay="Top" EditMode="InPlace"    Name="PIINDICATOR">

      <ParentTableRelation>

         <telerik:GridRelationFields DetailKeyField="PO_ID" asterKeyField="PO_ID"></telerik:GridRelationFields>

      </ParentTableRelation>

        <Columns>

          <telerik:GridBoundColumn DataField="PO_ID" Display="false"></telerik:GridBoundColumn>

          <telerik:GridBoundColumn DataField="PI_ID" Display="false"></telerik:GridBoundColumn>

          <telerik:GridDropDownColumn UniqueName="PI_INDICATOR" DataField="PI_INDICATOR" ListDataMember="PI_INDICATOR" ListTextField="PI_INDICATOR" ListValueField="PI_INDICATOR"  HeaderText="Indicator" ></telerik:GridDropDownColumn>

          <telerik:GridBoundColumn UniqueName="PI_FIELD_SUFFIX" DataField="PI_FIELD_SUFFIX" HeaderText="Measurement" ></telerik:GridBoundColumn>

          <telerik:GridBoundColumn UniqueName="PI_CALC_DESC" DataField="PI_CALC_DESC" HeaderText="Measurement
Calculation" ></telerik:GridBoundColumn>

          <telerik:GridEditCommandColumn UniqueName="EditColumn1" ItemStyle-HorizontalAlign="Right"  ItemStyle-Width="50px"></telerik:GridEditCommandColumn>

<telerik:GridButtonColumn UniqueName="DeleteColumn" ConfirmText="Are you sure you want to delete this
Indicator?" ConfirmDialogType="Classic" CommandName="Delete" Text="Delete"></telerik:GridButtonColumn>

         </Columns>

       </telerik:GridTableView>

     </DetailTables>

     <Columns>

        <telerik:GridDropDownColumn UniqueName="POG_NAME"  DataField="POG_NAME" ListDataMember="POG_NAME" ListTextField="POG_NAME" ListValueField="POG_NAME" HeaderText="Project
Owner" DropDownControlType ="DropDownList" ></telerik:GridDropDownColumn>

        <telerik:GridDropDownColumn UniqueName="PC_NAME"  DataField="PC_NAME" ListDataMember="PC_NAME" ListTextField="PC_NAME" ListValueField="PC_NAME" HeaderText="Project
Category" DropDownControlType ="DropDownList" ></telerik:GridDropDownColumn>

        <telerik:GridDropDownColumn UniqueName="PBT_NAME"  DataField="PBT_NAME" ListDataMember="PBT_NAME" ListTextField="PBT_NAME" ListValueField="PBT_NAME" HeaderText="Project
Beneficiary" DropDownControlType ="DropDownList" ></telerik:GridDropDownColumn>

       <telerik:GridBoundColumn UniqueName="PO_OBJECTIVE"  DataField="PO_OBJECTIVE" HeaderText="Project Objective"></telerik:GridBoundColumn>

       <telerik:GridBoundColumn DataField="PO_ID" Display="false"></telerik:GridBoundColumn>

       <telerik:GridBoundColumn DataField="PO_PC_ID" Display="false"></telerik:GridBoundColumn>

       <telerik:GridBoundColumn DataField="PO_PBT_ID" Display="false"></telerik:GridBoundColumn>

       <telerik:GridEditCommandColumn UniqueName="EditColumn" ItemStyle-HorizontalAlign="Right"  ItemStyle-Width="50px"></telerik:GridEditCommandColumn>

       <telerik:GridButtonColumn UniqueName="DeleteColumn" ConfirmText="Are you sure you want to delete this
Objective?" ConfirmDialogType="Classic" CommandName="Delete" Text="Delete"></telerik:GridButtonColumn>

      </Columns>

      <CommandItemSettings  AddNewRecordText="Add New Objective"  ShowRefreshButton="false" />

    </MasterTableView>

    <GroupingSettings CaseSensitive="False" />

  </telerik:RadGrid>

</ContentTemplate>

 

Kostadin
Telerik team
 answered on 09 Jun 2015
6 answers
582 views
Hello,

I use the AutoCompleteBox in my project to check if a string already exists in the database and display the already existing items to the user.

My problem is that a user types in the AutoCompleteBox and as soon as the result list pops up the first item in this list is automatically selected. If the user now presses tab or return or clicks into a different area if the screen, the selected entry in the result list is automatically selected and replaces the string entered by the user. This is very annoying if the user tries to enter a string which is only a part of an already existing string but not the same.

In my example the database contains the following strings: 000100, 000110, 000200, 000210

Now the user wants to add a new item 0001. This is not possible because as soon as the user has entered 0001 the AutoCompleteBox displays a list containing 000100 and 000110 and it automatically selects the first item in that list.
It is possible to get rid of that autoselection by pressing the up arrow key or explicitly moving the mouse out of the dropdown list - but from a usability point of view this is not acceptable. It would be very helpful if I could tell the AutoCompleteBox to avoid the automatic selection in such cases.

Does anyone know a way to get around this issue?

Best regards,
Markus



Heera
Top achievements
Rank 1
 answered on 09 Jun 2015
1 answer
341 views

I have a RADGrid using AJAX where I create a custom ButtonColumn. This column holds buttons (obviously) which need to use Full-PostBacks rather than Partial-PostBacks. The grid also allows for paging. In the grid's ItemCreated() event I add the visible buttons (ie: the first 10 items if paging is set to 10 items per page) to the ScriptManager's RegisterPostBackControl() method. This works perfectly fine.

The problem I have is that when a user jumps to another page, they are causing a Partial-PostBack which redraws the grid with the next set of records to be viewed, which also runs the code to RegisterPostBackControl's. However, these buttons do not perform Full-PostBacks...they stay as Partial-PostBack controls. It seems that the ScriptManager.RegisterPostBackControl() method does not function when called from a Partial-PostBack.

Anyone know how I can add the buttons within the grid to the list of Full-PostBack controls when a user moves to another page of records within the grid?

 

-Ben

Kostadin
Telerik team
 answered on 09 Jun 2015
0 answers
99 views
I put together some code for my web admin so I can see the versions and the descriptive title (tells you if it is trial or not)

in my example it showed "Telerik.Web.UI Trial Version 2014.3.1209.40"
until I updated it with the full version then it showed "Telerik.Web.UI 2014.3.1209.40"

here is my code I used

Dim item = System.Reflection.Assembly.LoadFile(Server.MapPath("~/bin/Telerik.Web.UI.dll"))
Dim title As String = ""
For Each attr In item.GetCustomAttributes(True)
If TypeOf attr Is System.Reflection.AssemblyTitleAttribute Then
Dim attrTitle As System.Reflection.AssemblyTitleAttribute = CType(attr, System.Reflection.AssemblyTitleAttribute)
title = attrTitle.Title
End If
Next
lblTelerikVersion.Text = title & " " & System.Reflection.Assembly.LoadFile(Server.MapPath("~/bin/Telerik.Web.UI.dll")).GetName().Version.ToString()
Doug
Top achievements
Rank 1
 asked on 08 Jun 2015
9 answers
281 views
Hi Telerik,
                

                        Is there a way to drag a file from windows explorer into the "Rad File Explorer" and have it upload the file?

Vessy
Telerik team
 answered on 08 Jun 2015
0 answers
84 views

I found a thread about how to do lines using GeoJSON with RadMap, but I haven't been able to find anything for doing lines with the Kendo Map.  The only Kendo Map things I've found with GeoJSON are about doing shapes.  Is it possible to do lines on a Kendo Map?

 

Matt
Top achievements
Rank 1
 asked on 08 Jun 2015
3 answers
346 views
how to upload image to RadImageEditor using RadAsyncUpload and save image in particular path
Vessy
Telerik team
 answered on 08 Jun 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?