Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
177 views
As in:

<CommandItemTemplate>

<asp:Button runat="server" ID="btnUA" Text="Update All" CommandName="UpdateAll" CssClass="CommandButton" />

<asp:Label ID="lblUpdMsg" runat="server" ForeColor="Red"></asp:Label>

</CommandItemTemplate>


I want to be able to set the value of  lblUpdMsg in code behind but it isn't recognized.  is this possible?

Thanks!

Shinu
Top achievements
Rank 2
 answered on 29 Aug 2008
2 answers
193 views
I have a radgrid with some textboxes and a button in an edit template like this:

<telerik:GridTemplateColumn DataField="DepositID" HeaderText="Related Deposit #" 
   SortExpression="DepositID" UniqueName="DepositID">  
 <EditItemTemplate> 
    <asp:Label ID="lblDepositID" runat="server" Text='<%# Bind("DepositID") %>' Visible="false"></asp:Label> 
    <asp:Label ID="lblDepositNum" runat="server" Text='<%# Bind("DepositNum")%>' Width="120px" ToolTip="Click [...] to assign a deposit"></asp:Label> 
    <button style="width:22px; height:22px;" onclick="return OpenDeposit()">...</button> 
  </EditItemTemplate> 
  <ItemTemplate> 
     <asp:Label ID="lblDepositID" runat="server" Text='<%# Bind("DepositID") %>' Visible="false"></asp:Label> 
     <asp:Label ID="lblDepositNum" runat="server" Text='<%# Bind("DepositNum")%>'></asp:Label> 
   </ItemTemplate> 
</telerik:GridTemplateColumn> 

OpenDeposit() opens a RadWindow which allows them find and select an item.   The RadWindow returns a pair of parameters.  This all works great.  So now I would like to take those parameters and update the lblDepositID and lblDepositNum fields in the RadGrid for the row that is being edited.

I can find the Grid in the client side API.  I can get access to all of the rows or the "selected" rows.   But I can't figure out how to find the row that is in edit or insert mode, which is the only one I care about.  

So somehow in the client side javascript either I need to be able to store the row being edited when they go into edit mode so I can reference it later or find it after the window returns.

Any way of doing this?
Dave
Top achievements
Rank 2
 answered on 29 Aug 2008
2 answers
120 views
I have a sub

    Public Sub NodeLocation(ByRef tree_root As RadTreeNode, ByVal  a As Byte, ByVal node_value As String())

        Dim find_node As RadTreeNodeCollection

        find_node = tree_root.Nodes 'give find_node  tree_root's childnode
        End sub
tree_root is my tree's root

but when i debug my program,I found my find_node is nothing.
why,please help me.thanks
zong
Top achievements
Rank 1
 answered on 29 Aug 2008
1 answer
104 views
Hi

When the page do to postback, every rad control dont load the css images, only happens when Internet Explorer 7.

Thanks.

Ruben Herrera Uribe.
Sean
Top achievements
Rank 2
 answered on 28 Aug 2008
1 answer
107 views
I have a window with a RadGrid on it. I am attaching to the RowClick event of the RadGrid in order to open a new window. What is happening is that when I click the row, it is opening a new window, but the new window is appearing behind the main window with the grid on it. I am assuming that this is because the grid is "Highlighting" the row that I clicked on after it has opened the new window which brings the focus back to the same window. Is there anyway around this? Is there a different event that I should be using?

Thanks!
Charlie Bross
Top achievements
Rank 1
 answered on 28 Aug 2008
2 answers
99 views
I have just started using the new ASP.NET AJAX versions of all the controls and I noticed in the Editor that there is now a new feature to edit an image. This is great and I apologize if I have not noticed it there before.
One thing that would be a great enhancement would be the ability to set the alignment of the image. I didn't notice that it was there, and have used this before in the "FreeTextBox" version (if I can mention that ugly word on this site) ;o).
Of course the RadEditor is MUCH better, but if you look at the demo:
http://freetextbox.com/demos/ and click on the insert image, there is an option to align the image so that the text will wrap around the image. so the image gets the html setting: align="left", etc.
I'm having to do this manually either by creating a table and putting the image in one cell and the text in another cell, or editing the html.
Unless, I'm missing something, I think this would be a helpful setting.
Thanks,
~bg
GDPR_erased
Top achievements
Rank 1
 answered on 28 Aug 2008
1 answer
131 views
Hi all

When I use the following code I get combo2 as null
var combo2 = $find('<%= rcb_DbPrefixes.ClientID %>');

When I try one of the following I get a get an object
var combo2 = $get('<%= rcb_DbPrefixes.ClientID %>'); 
var combo2 = document.getElementById('<%= rcb_DbPrefixes.ClientID %>');

However, when I try using functions such as:
var item = combo2.findItemByText(text);  
or 
combo2.get_items()

I get that those functions are undefined for the object.  When I look at the object's methods with the debugger I see many methods but non of them are the ones shown above.

What am I doing wrong?

Thanks a million,
Avi
Daniel
Telerik team
 answered on 28 Aug 2008
1 answer
155 views

This one really has me fuming.  I have a rad Grid that has a couple of linkbutton template columns which when clicked open up RadWindows.  Everything was working fine until I added a RadAjaxManager.  Then suddenly the linkbuttons no longer open the Rad Windows.  What could possibly cause this?  Do I need to add a  sepcific setting to the ajax manager for the linkbuttons to open the rad windows?

Here is my Grid:

<telerik:RadGrid ID="rgT" runat="server" Skin="WebBlue" AutoGenerateColumns="False"

GridLines="None" AllowFilteringByColumn="True" AllowMultiRowEdit="true" AllowMultiRowSelection="true"

OnItemDataBound="rgT_ItemDataBound" OnItemCommand="rgT_ItemCommand" Width="98%">

<MasterTableView CommandItemDisplay="Top" EditMode="InPlace">

<Columns>

<telerik:GridEditCommandColumn EditImageUrl="../images/edit.gif" CancelImageUrl="../images/tb_cancel.gif"

Resizable="False" ButtonType="ImageButton" Reorderable="False" UniqueName="CommandEditButton">

<ItemStyle HorizontalAlign="Left" Width="20px" />

<HeaderStyle HorizontalAlign="Left" Width="20px" />

</telerik:GridEditCommandColumn>

<telerik:GridTemplateColumn DataField="TRANS_SEQ" HeaderText="" UniqueName="TRANS_SEQ"

Display="false">

<ItemTemplate>

<asp:Label runat="server" ID="lblTransSeq" CssClass="Normal" Width="1px" Text='<%#DataBinder.Eval(Container, "DataItem.TRANS_SEQ") %>'></asp:Label>

</ItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridBoundColumn DataField="TRANS_DTE" HeaderText="Trans Date" UniqueName="TRANS_DTE"

ReadOnly="True">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Center" Width="100px" Wrap="False" />

</telerik:GridBoundColumn>

<telerik:GridTemplateColumn DataField="RECEIPT" HeaderText="Receipt" UniqueName="RECEIPT"

AllowFiltering="False">

<HeaderStyle HorizontalAlign="Left" Width="60px" Wrap="False" />

<ItemStyle HorizontalAlign="Left" Width="20px" Wrap="False" />

<ItemTemplate>

<asp:LinkButton ID="lbDoc" runat="server" Width="15px" CssClass="Normal" ToolTip="Click to open receipt PDF"

Text='<%#DataBinder.Eval(Container, "DataItem.RECEIPT") %>'></asp:LinkButton>

</ItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn DataField="JOBNUM" HeaderText="Job" UniqueName="JOBNUM">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemTemplate>

<asp:Label runat="server" ID="lblJobNum" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.JOBNUM") %>'></asp:Label>

</ItemTemplate>

<EditItemTemplate>

<asp:TextBox ID="tbJobNum" runat="server" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.JOBNUM") %>'></asp:TextBox>

</EditItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn DataField="PHASE" HeaderText="Phase" UniqueName="PHASE">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemTemplate>

<asp:Label runat="server" ID="lblPhase" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.PHASE") %>'></asp:Label>

</ItemTemplate>

<EditItemTemplate>

<asp:TextBox ID="tbPhase" runat="server" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.PHASE") %>'></asp:TextBox>

</EditItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn DataField="CATEGORY" HeaderText="Category" UniqueName="CATEGORY">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemTemplate>

<asp:Label runat="server" ID="lblCategory" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.CATEGORY") %>'></asp:Label>

</ItemTemplate>

<EditItemTemplate>

<asp:TextBox ID="tbCategory" runat="server" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.CATEGORY") %>'></asp:TextBox>

</EditItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn DataField="DEPT" HeaderText="Dept" UniqueName="DEPT">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemTemplate>

<asp:Label runat="server" ID="lblDept" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.DEPT") %>'></asp:Label>

</ItemTemplate>

<EditItemTemplate>

<asp:TextBox ID="tbDept" runat="server" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.DEPT") %>'></asp:TextBox>

</EditItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn DataField="ACCT" HeaderText="GL Acct" UniqueName="ACCT">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemTemplate>

<asp:Label runat="server" ID="lblAcct" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.ACCT") %>'></asp:Label>

</ItemTemplate>

<EditItemTemplate>

<asp:TextBox ID="tbAcct" runat="server" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.ACCT") %>'></asp:TextBox>

</EditItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn DataField="LINE_TYPE" HeaderText="Line Type" UniqueName="LINE_TYPE"

AllowFiltering="false">

<HeaderStyle HorizontalAlign="Left" Width="60px" Wrap="False" />

<ItemStyle HorizontalAlign="Left" Width="60px" Wrap="False" />

<ItemTemplate>

<asp:Label runat="server" ID="lblLineType" CssClass="Normal" Width="60px" Text='<%#DataBinder.Eval(Container, "DataItem.LINE_TYPE") %>'></asp:Label>

</ItemTemplate>

<EditItemTemplate>

<telerik:RadComboBox ID="rcLt" runat="server" Skin="WebBlue" AutoPostBack="True"

Width="40px" AllowCustomText="false" OnSelectedIndexChanged="lineTypeChange">

<Items>

<telerik:RadComboBoxItem runat="server" Text="J" Value="J" />

<telerik:RadComboBoxItem runat="server" Text="G" Value="G" />

</Items>

</telerik:RadComboBox>

<asp:Label ID="lblLT" runat="server" Visible="false" Text='<%#DataBinder.Eval(Container, "DataItem.LINE_TYPE") %>'></asp:Label>

</EditItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridBoundColumn DataField="MERCHANT_NAME" HeaderText="Merchant" UniqueName="MERCHANT_NAME"

ReadOnly="True">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Center" Width="100px" Wrap="True" />

</telerik:GridBoundColumn>

<telerik:GridBoundColumn DataField="TRANS_AMOUNT" HeaderText="Amount" UniqueName="TRANS_AMOUNT"

ReadOnly="True">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Right" Width="100px" Wrap="False" />

</telerik:GridBoundColumn>

<telerik:GridTemplateColumn DataField="SUBS" HeaderText="Subs" UniqueName="SUBS"

AllowFiltering="False">

<HeaderStyle HorizontalAlign="Left" Width="36px" Wrap="False" />

<ItemStyle HorizontalAlign="Right" Width="36px" Wrap="False" />

<ItemTemplate>

<asp:LinkButton ID="lbSubs" runat="server" Width="36px" CssClass="Normal" OnClick="subsClick"

CommandName="Subs" ToolTip="Click to edit sub transactions" Text='<%#IIF(DataBinder.Eval(Container, "DataItem.SUBSCOUNT") is Nothing, "0", DataBinder.Eval(Container, "DataItem.SUBSCOUNT")) %>'></asp:LinkButton>

</ItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn DataField="USE_TAX_AMT" HeaderText="Use Tax" UniqueName="USE_TAX_AMT"

AllowFiltering="False">

<HeaderStyle HorizontalAlign="Left" Width="45px" Wrap="False" />

<ItemStyle HorizontalAlign="Right" Width="45px" Wrap="False" />

<ItemTemplate>

<asp:LinkButton ID="lbUseTax" runat="server" CommandName="Taxes" Width="45px" CssClass="Normal"

ToolTip="Click to edit use Tax" Text='<%#DataBinder.Eval(Container, "DataItem.USE_TAX_AMT") %>'

OnClick="useTaxClick"></asp:LinkButton>

</ItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridBoundColumn DataField="TRANS_POST_DATE" HeaderText="Post Date" UniqueName="TRANS_POST_DATE"

ReadOnly="True">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Center" Width="100px" Wrap="False" />

</telerik:GridBoundColumn>

<telerik:GridTemplateColumn DataField="ITEM_DESCR" HeaderText="Item Description"

UniqueName="ITEM_DESCR" AllowFiltering="False">

<ItemTemplate>

<asp:Label runat="server" ID="lblItemDescr" CssClass="Normal" Width="100px" Text='<%#DataBinder.Eval(Container, "DataItem.ITEM_DESCR") %>'></asp:Label>

</ItemTemplate>

<EditItemTemplate>

<asp:TextBox ID="tbItemDescr" runat="server" CssClass="Normal" Width="100px" Text='<%#DataBinder.Eval(Container, "DataItem.ITEM_DESCR") %>'></asp:TextBox>

</EditItemTemplate>

<HeaderStyle HorizontalAlign="Left" Wrap="False" />

<ItemStyle HorizontalAlign="Center" Wrap="True" />

</telerik:GridTemplateColumn>

<telerik:GridTemplateColumn HeaderText="Approved" Resizable="False" UniqueName="Approved"

Reorderable="False">

<HeaderStyle HorizontalAlign="Left" Width="100px" Wrap="False" />

<ItemStyle HorizontalAlign="Center" Width="100px" Wrap="False" />

<ItemTemplate>

<asp:CheckBox ID="chkApproved" runat="server" Checked='<%#DataBinder.Eval(Container, "DataItem.APPROVE_STATUS") %>'>

</asp:CheckBox>

</ItemTemplate>

</telerik:GridTemplateColumn>

<telerik:GridBoundColumn DataField="MERCHANT_STATE" HeaderText="" UniqueName="MERCHANT_STATE"

ReadOnly="True" Display="false">

</telerik:GridBoundColumn>

</Columns>

<CommandItemTemplate>

<asp:Button runat="server" ID="btnUA" Text="Update All" CommandName="UpdateAll" CssClass="CommandButton" /></CommandItemTemplate>

<ExpandCollapseColumn>

<HeaderStyle Width="20px" />

</ExpandCollapseColumn>

<RowIndicatorColumn>

<HeaderStyle Width="20px" />

</RowIndicatorColumn>

</MasterTableView>

<ClientSettings>

<Scrolling AllowScroll="True" UseStaticHeaders="True" />

<Selecting AllowRowSelect="True" />

</ClientSettings>

<FilterMenu EnableTheming="True" Skin="WebBlue">

<CollapseAnimation Duration="200" Type="OutQuint" />

</FilterMenu>

</telerik:RadGrid>



And here is my RadAjaxManager:

<telerik:RadAjaxManager ID="ram1" runat="server">

<AjaxSettings>

<telerik:AjaxSetting AjaxControlID="rcCn">

<UpdatedControls>

<telerik:AjaxUpdatedControl ControlID="rgT"></telerik:AjaxUpdatedControl>

</UpdatedControls>

</telerik:AjaxSetting>

<telerik:AjaxSetting AjaxControlID="btnUA">

<UpdatedControls>

<telerik:AjaxUpdatedControl ControlID="rgT"></telerik:AjaxUpdatedControl>

</UpdatedControls>

</telerik:AjaxSetting>

<telerik:AjaxSetting AjaxControlID="rcP">

<UpdatedControls>

<telerik:AjaxUpdatedControl ControlID="rcC"></telerik:AjaxUpdatedControl>

</UpdatedControls>

</telerik:AjaxSetting>

<telerik:AjaxSetting AjaxControlID="btnApplyJPC">

<UpdatedControls>

<telerik:AjaxUpdatedControl ControlID="rgT"></telerik:AjaxUpdatedControl>

</UpdatedControls>

</telerik:AjaxSetting>

</AjaxSettings>

</telerik:RadAjaxManager>


Thanks

Acadia
Top achievements
Rank 1
Iron
 answered on 28 Aug 2008
2 answers
177 views
Is there a way to make a row selected on clicking Delete button?

In my grid, I have a GridButtonColumn with a Delete button. I use a classic confirmation dialog. When I click the Delete button on a grid row, I would like the row to become Selected before the confirmation dialog is produced. With the row selected, the dialog could contain just a generic text "Woud you like to delete the selected row?". As it is now, it is not clear from the dialog what row is about to be deleted.

Eliyahu Goldin
Top achievements
Rank 1
 answered on 28 Aug 2008
2 answers
201 views
Hi,

I have  problem with tabstrip.When i click tab it postback twice.Here is my code.Am i missing anythink.

<radTab:RadTabStrip ID="tabstrip1" runat="server" MultiPageID="RadMultiPage1" AutoPostBack="true" OnTabClick="tabstrip1_TabClick" ClickSelectedTab="true">
<Tabs >
<radTab:Tab Text="test1"  ID="Tabtest1" runat="server" Value="1" PageViewID="PageView1" ></radTab:Tab>
<radTab:Tab Text="test2" ID="Tabtest2" runat="server" Value="2" PageViewID="PageView2"></radTab:Tab>
</Tabs></radtab:RadTabStrip>

<radTab:RadMultiPage ID="RadMultiPage1" runat="server" SelectedIndex="0">
<radTab:PageView ID="PageView1" runat="server">
<radgrid>
</radTab:PageView>
<radTab:PageView ID="PageView2" runat="server">
<radgrid>
</radTab:
PageView>

Protected Sub tabstrip1_TabClick(ByVal sender As Object, ByVal e As Telerik.WebControls.TabStripEventArgs) Handles tabstrip1.TabClick
End Sub

thanks.
Eva

Eva
Top achievements
Rank 1
 answered on 28 Aug 2008
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?