Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
158 views
Hi

I have inserted a simple grid in a page, set up for automatic generation of edit and delete columns, allowing automatic
update insert and delete.  The edit and delete parts works fine but the 'add new' button does not show up.

I can't see why not. Can anyone help here?

Version is Q1 2009

Thanks

Clive

<telerik:RadScriptManager ID="RadScriptManager1" runat="server">  
        </telerik:RadScriptManager> 
        <asp:SqlDataSource ID="SqlDataSource1" runat="server"   
            ConnectionString="<%$ ConnectionStrings:cotn_publicConnectionString %>"   
            DeleteCommand="DELETE FROM [WeeklySubs] WHERE [ID] = @ID"   
            InsertCommand="INSERT INTO [WeeklySubs] ([FirstName], [LastName], [Email], [Status], [CreateDate], [IP]) VALUES (@FirstName, @LastName, @Email, @Status, @CreateDate, @IP, @HTML, @Spare)"   
            SelectCommand="SELECT * FROM [WeeklySubs] ORDER BY [LastName]"   
            UpdateCommand="UPDATE [WeeklySubs] SET [FirstName] = @FirstName, [LastName] = @LastName, [Email] = @Email, [Status] = @Status, [CreateDate] = @CreateDate, [IP] = @IP WHERE [ID] = @ID">  
            <DeleteParameters> 
                <asp:Parameter Name="ID" Type="Int32" /> 
            </DeleteParameters> 
            <UpdateParameters> 
                <asp:Parameter Name="FirstName" Type="String" /> 
                <asp:Parameter Name="LastName" Type="String" /> 
                <asp:Parameter Name="Email" Type="String" /> 
                <asp:Parameter Name="Status" Type="String" /> 
                <asp:Parameter Name="CreateDate" Type="DateTime" /> 
                <asp:Parameter Name="IP" Type="String" /> 
                <asp:Parameter Name="HTML" Type="String" /> 
                <asp:Parameter Name="Spare" Type="String" /> 
                <asp:Parameter Name="ID" Type="Int32" /> 
            </UpdateParameters> 
            <InsertParameters> 
                <asp:Parameter Name="FirstName" Type="String" /> 
                <asp:Parameter Name="LastName" Type="String" /> 
                <asp:Parameter Name="Email" Type="String" /> 
                <asp:Parameter Name="Status" Type="String" /> 
                <asp:Parameter Name="CreateDate" Type="DateTime" /> 
                <asp:Parameter Name="IP" Type="String" /> 
                <asp:Parameter Name="HTML" Type="String" /> 
                <asp:Parameter Name="Spare" Type="String" /> 
            </InsertParameters> 
        </asp:SqlDataSource> 
        <table align="center" bgcolor="White" width="600px">  
            <tr> 
                <td> 
                    <telerik:RadGrid ID="RadGrid1" runat="server" AllowAutomaticDeletes="True"   
                        AllowAutomaticInserts="True" AllowAutomaticUpdates="True" AllowPaging="True"   
                        AllowSorting="True" AutoGenerateDeleteColumn="True"   
                        AutoGenerateEditColumn="True" DataSourceID="SqlDataSource1" GridLines="None"   
                        Skin="Forest" Width="800px" CommandItemDisplay="Top">  
<MasterTableView AutoGenerateColumns="False" DataKeyNames="ID" DataSourceID="SqlDataSource1">  
<RowIndicatorColumn> 
<HeaderStyle Width="20px"></HeaderStyle> 
</RowIndicatorColumn> 
 
<ExpandCollapseColumn> 
<HeaderStyle Width="20px"></HeaderStyle> 
</ExpandCollapseColumn> 
    <Columns> 
         
        <telerik:GridBoundColumn DataField="FirstName" HeaderText="FirstName"   
            SortExpression="FirstName" UniqueName="FirstName">  
        </telerik:GridBoundColumn> 
        <telerik:GridBoundColumn DataField="LastName" HeaderText="LastName"   
            SortExpression="LastName" UniqueName="LastName">  
        </telerik:GridBoundColumn> 
        <telerik:GridBoundColumn DataField="Email" HeaderText="Email"   
            SortExpression="Email" UniqueName="Email">  
        </telerik:GridBoundColumn> 
        <telerik:GridBoundColumn DataField="Status" HeaderText="Status"   
            SortExpression="Status" UniqueName="Status">  
        </telerik:GridBoundColumn> 
        <telerik:GridBoundColumn DataField="CreateDate" DataType="System.DateTime"   
            HeaderText="CreateDate" SortExpression="CreateDate"   
            UniqueName="CreateDate">  
        </telerik:GridBoundColumn> 
        <telerik:GridBoundColumn DataField="IP" HeaderText="IP"   
            SortExpression="IP" UniqueName="IP">  
        </telerik:GridBoundColumn> 
          
    </Columns> 
</MasterTableView> 
                    </telerik:RadGrid> 
Clive Hoggar
Top achievements
Rank 1
 answered on 22 Jun 2009
0 answers
81 views
Under the new release of the tabstrip the property to set the tab as selected no longer works.

    Dim rootTab As RadTab = New RadTab  
    rootTab.Text = "TabText" 
    rootTab.ImageUrl = "http://www.mytabimage.com/image.jpg" 
    rootTab.Value = "TabValue" 
    rootTab.Selected = True 

    RadTabStrip1.Tabs.Add(rootTab) 

    


If you create several tabs with only one being set at as selected it always selects the first tab regardless of whether the tab was selected or not when it was added.  Now, this same code worked in the previous versions of the tab control without a problem.

My current workaround is tracking what the selected index should be and setting that

 RadTabStrip1.SelectedIndex = SelectedTabIndex 

Just thought I would let you know.
Doug
Top achievements
Rank 1
 asked on 22 Jun 2009
2 answers
191 views
I have a simple ConfirmDelete javascript function that runs when the user clicks the Delete button.

I want to ajaxify the Delete button.  When I click on it, the javascript runs, but upon confirm the script and ajax function seems to stop.  How can I have the ajax continue to run after the user confirms?
Matt
Top achievements
Rank 1
 answered on 22 Jun 2009
6 answers
132 views
Hi,
I have an editor in RAD window, and i want to insert a hyperlink into it content to open another window, with video. So i made a function OpenVideo() on a page where editor resides, and inserted following hyperlink into editor content:
this is test <a href="#" onclick="return OpenVideo('Video1');">video link</a>,
But when i click it - i get error object not found. Is it possible to make such hyperlink in editor content so i can run jscipt function on editor's page?
Thanks!

Alex
Alex Dybenko
Top achievements
Rank 2
 answered on 22 Jun 2009
1 answer
61 views
Hi,

I have a RadMenu on my ASP.NET page and I have created my own skin.
I was wondering how to get, for example the home button to stay on the focus state when I'm on the home page.
The menu is on a master page and the other pages are loaded into the content place holder.

Thanks for your help

Harry
Yana
Telerik team
 answered on 22 Jun 2009
2 answers
130 views
I am exporting RadGrid using the exportToCSV() functionality. I have command fields whose headers I don't want to be exported.

At present the export is like this:
"Notes","View/Edit","First Name","Last Name","Organization","Job Title","Email","Business Phone","Delete"
"","","Abhishek","Parakh","State","Web Dev","yadayada@yahoo.com","405-xxx-xxxx",""

I want it to be like this:
"First Name","Last Name","Organization","Job Title","Email","Business Phone"
"Abhishek","Parakh","State","Web Dev","yadayada@yahoo.com","405-xxx-xxxx"

I dont want to do things manually. For example, do replace or remove characters, I just dont want the command fields to be exported from the radgrid.

Someone has posted examples such as
e.ExportOutput = e.ExportOutput.Replace("<head>", head);                      
e
.ExportOutput = e.ExportOutput.Replace("<td>", "<td class='cell'>")

However, again this is only manual replacements. In future names of my command fields may change as well as their position.

All I want is that radgrid should not export command fields but only the fields corresponding to my database table and data.
Abhishek Parakh
Top achievements
Rank 1
 answered on 22 Jun 2009
7 answers
180 views
Hi All,
             Iam using two levels of hireachy in the Grid. The main Grid is RadGrid and SubGrid is RadGrid. Inside this SubGrid I have one more RadGrid. On the ItemCommand event how to identify the Grid

Can any one pls let me know.

Its very Urgent.

Regards
asra
Daniel
Telerik team
 answered on 22 Jun 2009
2 answers
99 views
Hi

I have run into a mysterious problem - when I edit an exisiting combo box by clicking the smart tag
and using the 'Build RadComboBox' link , the edits are not saved.

eg I have a page with a combobox that has been working for some time. I wanted to add some items
to the drop down list.
When I add a new item to the RadComboBox list, use the up/down arrow etc to position it,
click OK, close the smart tag and save the page, the changes are not retained. If I switch to code
view, I can see nothing has changed. 

It happens with other pages too.

I can edit in code view and the changes are saved OK, and show up in the smart tag builder,
but this negates some of the productivity features..

How can I fix this? I am not even sure where to start looking!

Thanks for your help

Clive
.

Clive Hoggar
Top achievements
Rank 1
 answered on 22 Jun 2009
1 answer
107 views
Hi All,

I am facing problems when i used Radgrid Insert/Update/Delete
funcution with Filtering column. It does not work properly.

Please Suggest me...


Thank You,
Kailash Bokade


Pavlina
Telerik team
 answered on 22 Jun 2009
3 answers
83 views
I am using the RadPanelBar to replace the left side quick launch navigation in SharePoint. I am using the default left navigation datasource "QuickLaunchSiteMap". So when I create the links in SharePoint and select open in new window. The rad panel bar does not open in a new window. All link open in the same window regardless. Any help would be appreciated. 

below is what I have in my master page to replace the left navigation elements.

     <telerik:RadScriptManager ID="ScriptManager1" runat="server" />
     
     <telerik:RadPanelBar runat="server" ID="RadPanelBar1" DataSourceID="QuickLaunchSiteMap" Skin="Default" EnableEmbeddedSkins="false" ExpandMode="MultipleExpandedItems">
     </telerik:RadPanelBar>

thanks
-tom
Paul
Telerik team
 answered on 22 Jun 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?