Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
80 views
I have placed a delete button in the ItemTemplate section and the AlternatingItemTemplate area.  When I try and click on the button, I get the following message

You have specified that your delete command compares all values on SqlDataSource 'dsLTDist0', but the dictionary passed in for values is empty.  Pass in a valid dictionary for delete or change your mode to OverwriteChanges



I have an update button in the same line and it seems to work correctly.  here is my datasource code....

<asp:SqlDataSource ID="dsLTDist0" runat="server"
        ConflictDetection="CompareAllValues"
        ConnectionString="<%$ ConnectionStrings:Tech-InnovationsConnectionString %>"
        DeleteCommand="DELETE FROM [Appointments] WHERE [ID] = @original_ID"
        InsertCommand="INSERT INTO [Appointments] ([Subject], [Unit], [Area], [Vehicle], [Status], [Hours], [Comments],[Start],[End],[District]) VALUES (@Subject, @Unit, @Area, @Vehicle, @Status, @Hours, @Comments,@Start,@End,@District)"
        OldValuesParameterFormatString="original_{0}"
        SelectCommand="SELECT [ID], [Subject], [Unit], [Area], [Vehicle], [Status], [Hours], [Comments] FROM [Appointments]"
         
         
         
        UpdateCommand="UPDATE [Appointments] SET [Subject] = @Subject, [Unit] = @Unit, [Area] = @Area, [Vehicle] = @Vehicle, [Status] = @Status, [Hours] = @Hours, [Comments] = @Comments WHERE [ID] = @original_ID AND [Subject] = @original_Subject AND (([Unit] = @original_Unit) OR ([Unit] IS NULL AND @original_Unit IS NULL)) AND (([Area] = @original_Area) OR ([Area] IS NULL AND @original_Area IS NULL)) AND (([Vehicle] = @original_Vehicle) OR ([Vehicle] IS NULL AND @original_Vehicle IS NULL)) AND (([Status] = @original_Status) OR ([Status] IS NULL AND @original_Status IS NULL)) AND (([Hours] = @original_Hours) OR ([Hours] IS NULL AND @original_Hours IS NULL)) AND (([Comments] = @original_Comments) OR ([Comments] IS NULL AND @original_Comments IS NULL))">
        <DeleteParameters>
            <asp:Parameter Name="original_ID" />
        </DeleteParameters>
        <InsertParameters>
            <asp:Parameter Name="Subject" Type="String" />
            <asp:Parameter Name="Unit" Type="String" />
            <asp:Parameter Name="Area" Type="String" />
            <asp:Parameter Name="Vehicle" Type="String" />
            <asp:Parameter Name="Status" Type="String" />
            <asp:Parameter Name="Hours" Type="String" />
            <asp:Parameter Name="Comments" Type="String" />
            <asp:Parameter Name="Start" Type="datetime" />
            <asp:Parameter Name="End" Type="datetime" />
            <asp:Parameter Name="District" Type="int32" />
        </InsertParameters>
        <UpdateParameters>
            <asp:Parameter Name="Subject" Type="String" />
            <asp:Parameter Name="Unit" Type="String" />
            <asp:Parameter Name="Area" Type="String" />
            <asp:Parameter Name="Vehicle" Type="String" />
            <asp:Parameter Name="Status" Type="String" />
            <asp:Parameter Name="Hours" Type="String" />
            <asp:Parameter Name="Comments" Type="String" />
            <asp:Parameter Name="original_ID" Type="Int32" />
            <asp:Parameter Name="original_Subject" Type="String" />
            <asp:Parameter Name="original_Unit" Type="String" />
            <asp:Parameter Name="original_Area" Type="String" />
            <asp:Parameter Name="original_Vehicle" Type="String" />
            <asp:Parameter Name="original_Status" Type="String" />
            <asp:Parameter Name="original_Hours" Type="String" />
            <asp:Parameter Name="original_Comments" Type="String" />
        </UpdateParameters>
    </asp:SqlDataSource>

and here is my ItemTemplate

<ItemTemplate>
    <tr class="rlvI">
        <td>
            <asp:Button ID="EditButton" runat="server" CausesValidation="False"
                CommandName="Edit" CssClass="rlvBEdit" Text=" " ToolTip="Edit" />
        </td>
        <td>
            <asp:Label ID="SubjectLabel" runat="server" width ="170" Text='<%# Eval("Subject") %>' />
        </td>
        <td>
            <asp:Label ID="UnitLabel" runat="server"  width ="70" Text='<%# Eval("Unit") %>' />
        </td>
        <td>
            <asp:Label ID="AreaLabel" runat="server"  width ="70" Text='<%# Eval("Area") %>' />
        </td>
        <td>
            <asp:Label ID="VehicleLabel" runat="server"  width ="70" Text='<%# Eval("Vehicle") %>' />
        </td>
        <td>
            <asp:Label ID="HoursLabel" runat="server"  width ="80" Text='<%# Eval("Hours") %>' />
        </td>
        <td>
            <asp:Label ID="StatusLabel" runat="server"  width ="100" Text='<%# Eval("Status") %>' />
        </td>
        <td>
            <asp:Label ID="CommentsLabel" runat="server"  width ="200" Text='<%# Eval("Comments") %>' />
        </td>
        <td>
            <asp:Button ID="btnDel" runat="server" CausesValidation="False"
                CommandName="Delete" CssClass="rlvBDel" Text=" " ToolTip="Delete this Record" />
        </td>
 
    </tr>
</ItemTemplate>

Any ideas or Suggestions?
Zuhair
Top achievements
Rank 1
 answered on 23 Aug 2012
1 answer
72 views
Hello

I wonder if there is some way to bypass the validation filter a column of type GridDateTimeColumn therefore need to do a custom filter on it, where the User could fill the query with special characters that assist in filtering.
For example
! 08/20/2012 Different 08/20/2012
> 08/20/2012 Greater than 08/20/2012
<08/20/2012 Smaller than 08/20/2012
and besides others.


Maybe it is possible to disable these validations further naum found no way. If you can help me thank.


Fernando
Eyup
Telerik team
 answered on 23 Aug 2012
1 answer
170 views
Hi,

I am using the Vista skin for the framework to our radWindows. However my boss doesn't like the fact that you can see through the framwork of the window to the page beneath it in the z-order. I have tried overriding the css in my own file but for some reason the opacity values have been set to !important in the embedded versions css (the one that comes from WebResourse.axd) and this always seems to take priority. So I thought I would get round this by using the online sylebuilder, grab a copy of the Vista skin call it VistaSolid, Edit the opacity values for the Window.VistaSolid.css, attach the css file to calling page and set the EnableEmbbededSkins to false for the RadWindowManager. This should have resulted in the opacity being no longer see through, however it doesn't. although the new custom skin is being used and many of the attributes are collected from there the opacity values are still coming from WebResource.axd, which they shouldn't be.

So how can I set the opacity of the skin to be 100%, and why does the opacity values of the embedded skin need to be set to !important so that they cannot be overridden, surely this is a bug isn't it?

Stuart

<link rel="Stylesheet" type="text/css" href="Styles/Skins/VistaSolid/Window.VistaSolid.css" />
<telerik:RadWindowManager ID="RadWindowManager1" Skin="VistaSolid" VisibleStatusbar="false" EnableEmbeddedSkins="false"
            Behaviors="Close, Move, Resize" runat="server" OnClientPageLoad="SetWindowManagerSize" OnClientDragStart="WindowDragStart">
            <Windows>
                <telerik:RadWindow ID="PartsListWindow" runat="server" Behaviors="Close, Move, Resize" EnableEmbeddedSkins="false"
                    NavigateUrl="../Editor.aspx" Skin="VistaSolid" Height="275px" Width="350px" ShowContentDuringLoad="false" style="z-index:5001; overflow:hidden;" >
                </telerik:RadWindow>
            </Windows>
        </telerik:RadWindowManager>
Marin Bratanov
Telerik team
 answered on 23 Aug 2012
1 answer
73 views
Hello,

I think I already know the answer to this but wanted to post just in case.  I have implemented an ActiveX which scans documents and uploads them to my website.  The problem is, the upload is really hammering the system.  I was wondering if RadUpload - or another Telerik control - could possibly help out.  I am converting the image to a base64 and uploading.  But was wondering if I could somehow take the file created and use RadUpload to get the file directly to the server?  I would want to do this without user intervention, which I am guessing is not possible since RadUpload seems to be for that purpose only.  But I wanted to check anyways.  Or if there is another Telerik control that might help with the scenario I'm appreciate the input.

Thanks!
Richard
Dimitar Terziev
Telerik team
 answered on 23 Aug 2012
2 answers
647 views
Hi
I am fairly new to programming and I am using telerik radgrid to display a list of quotes for a sales application on a quote.aspx page. I have created a Hyperlink column that will redirect a user to a editquote.aspx page which will allow the user to edit specific details(product description,supplier...) of the particular quote they have chosen. The problem I am having is getting to display the chosen quote details on the editquote.aspx page in a radgrid in which they can use inline editing etc. Is there any help that I can get from the support team or anyone else on how to do this?
Louven
Top achievements
Rank 1
 answered on 23 Aug 2012
2 answers
736 views
I am binding grid using Needdatasource event.It works fine in normal case.
I have filter textbox for one of my column and I am validating the filter values in the ItemCommand event.Data is being fetched for the given filter value and could see the data in the Radgrid.DataSource.But the grid shows no records to display.Why the grid is not bind with the fetched data?

Please find below my code.
<telerik:RadGrid ID="gvPhoneInq" runat="server" CellSpacing="0" GridLines="None"
        AllowSorting="True" AllowFilteringByColumn="True" AllowPaging = "True"
        AutoGenerateColumns="False"  OnNeedDataSource="gvPhoneInq_NeedDataSource"
        OnItemCommand="gvPhoneInq_ItemCommand" OnSelectedIndexChanged="gvPhoneInq_SelectedIndexChanged" >      
        <PagerStyle Mode="NextPrevAndNumeric"/>
        <GroupingSettings CaseSensitive="false" />
        <ClientSettings EnablePostBackOnRowClick="true">         
            <Selecting AllowRowSelect="true" />
        </ClientSettings>
 
        <MasterTableView CommandItemDisplay="Top" NoMasterRecordsText="No Phone enquiry records exist!"  CommandItemStyle-BackColor="lightblue" CommandItemStyle-Font-Bold="true" GridLines="None" DataKeyNames="Ph_EnqID"
              >
 <Columns>
<telerik:GridBoundColumn HeaderText="Mobile No" UniqueName="Ph_PhNo" DataField="Ph_PhNo"   >
                    <FilterTemplate>
                        <telerik:RadTextBox ID="RTMob" runat="server" Width="200px" ClientEvents-OnValueChanged="ValueChanged1" ></telerik:RadTextBox>
                        <telerik:RadScriptBlock ID="RBMob" runat="server">
 
                                <script type="text/javascript">
                                    function ValueChanged1(sender, args) {
                                        var tableView = $find("<%# ((GridItem)Container).OwnerTableView.ClientID %>");
                                        var Name = $find('<%# ((GridItem)Container).FindControl("RTMob").ClientID %>');
 
                                        tableView.filter("Ph_PhNo", Name, "EqualTo");
                                    }                                  
                                </script>
 
                            </telerik:RadScriptBlock>
                    </FilterTemplate>
                </telerik:GridBoundColumn>
</Columns>
<EditFormSettings >
            <EditColumn UniqueName="EditCo

mmandColumn1"
></EditColumn>           
            </EditFormSettings>           
 
            <CommandItemStyle BackColor="LightBlue" Font-Bold="True"></CommandItemStyle>
        </MasterTableView>       
    </telerik:RadGrid>

aspx.cs

protected void gvPhoneInq_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
        {
  
            _phoneEnqServices = new PhoneEnqServices();
  
            gvPhoneInq.DataSource = _phoneEnqServices.GetAllPatients(search);
        }    
  
         
        protected void gvPhoneInq_ItemCommand(object sender, GridCommandEventArgs e)
        {
              
            if (e.CommandName == RadGrid.FilterCommandName)
            {
                Pair filterPair = (Pair)e.CommandArgument;
                switch (filterPair.Second.ToString())
                {
                      
                    case ("Ph_PhNo"):
                        {
                            flagD = 0;
                            RadTextBox searchMob = (e.Item as GridFilteringItem)[filterPair.Second.ToString()].FindControl("RTMob") as RadTextBox;
                            search = " where Ph_PhNo ='" + searchMob.Text + "'";
                            break;
                        }
                }
            }          
              
        }


Please let me know if the above code has anu issues.without filter the grid binds properly.
Thanks,
Soumya
Preetham
Top achievements
Rank 2
 answered on 23 Aug 2012
2 answers
116 views
Hi,

I want to change the mode to preview mode instead of design mode in the run time.

How can i do this. What is the property to change this mode.


Thanks,
Sandy
Sandy
Top achievements
Rank 1
 answered on 23 Aug 2012
4 answers
148 views
Hello,

In some months as August 2012, 6 weeks are shown but the last row contains only days of September.
In this case, is it possible to suppress the last row?

Regards,

Erwan
Erwan
Top achievements
Rank 1
 answered on 23 Aug 2012
1 answer
52 views
Hello all,

I have an issue where I have a RadGrid nested within a repeater.  All functionality works fine, except when it comes to filtering.  When I attempt to display the filter menu for a specific column, nothing happens.  No menu displays, no javascript error, nothing.  I searched the forums expecting that at least another individual would have come across this by now, but no such luck.

(Also, I should mention that the radgrid is actually embedded within a user control, that is embedded within the repeater.)

If I place the radgrid outside of the repeater everything works fine.

Any ideas on what I can do to address this?

Thank you.
Martin
Telerik team
 answered on 23 Aug 2012
2 answers
54 views
Hello,

How can I set the css file needed to display different table layouts in table creator in RadEditor for Sharepoint 2010. In "normal" RadEditor setting value:
<telerik:RadEditor TableLayoutCssFile = "/_layouts/1045/STYLES/tableStyles.css" ... />

works well and all table layouts are properly displayed in Table Creator dialog. Doing the same in Rad Editor for Sharepoint by setting the same value in ConfigFile.xml located in: 
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\wpresources\RadEditorSharePoint\6.3.0.0__1f131a624888eeed\Resources\ConfigFile.xml like this:

<configuration>
  <property name="TableLayoutCssFile">/_layouts/1045/STYLES/tableStyles.css</property>
</configuration>

does not work. 

Should it be done in another way?

Thank you in advance.
Stanimir
Telerik team
 answered on 23 Aug 2012
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?