Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
170 views
Hi,

Y have a problem with the rendering of radcontrol under IIS 6.0 on WS 2003.

I post 4 pictures to show you my problem.

see the image 1 =>gooddisplay_iss7_ws_seven.jpg
configuration:
  • OS: Windows Seven
  • browser :IE 8
  • ISS : ISS 7

see the image 2 =>gooddisplay_iss6_ws_2003_firefox.jpg
configuration:
  • OS: Windows Serveur 2003
  • browser :FireFox 3.5.5
  • ISS : ISS 6

see the image 3 =>baddisplay_iss6_ws_2003.jpg
configuration:
  • OS: Windows Serveur 2003
  • browser :IE 8
  • ISS : ISS 6

see the image 4 =>gooddisplay_iss7_ws_seven_firefox.jpg
configuration:
  • OS: Windows Seven
  • browser :Firefox 3.5.5
  • ISS : ISS 7

Could you explain me why I have a difference?

Thanks.

Dimo
Telerik team
 answered on 02 Dec 2009
2 answers
218 views
Hi,

First I want to give compliments about the amazing products telerik delivers. I'm using the Silverlight controls for a while and since I'm so satisfied I decided to use the radcontrols asp.net ajax as well.

At the moment I'm implementing the editor radcontrol in my website.

Everything is working fine, although I have one little question.
Is there a simple way to create some kind of text box in which I can put my image URL, instead of using the default image manager for inserting images? Something like the properties window, after right clicking an image.
If this is possible how am I able to do this, without to much trouble?

Looking forward for a reply.

With kind regards,

Dako
Dako -
Top achievements
Rank 1
 answered on 02 Dec 2009
1 answer
256 views
Hi, 
 
I am using the radgrid with MasterTableView and DetailTables,in the detailTable ,there is GridTableView. 
In the GridTableView ,i have itemtemplate(Image button) column,my requirement is i want to bind the image url for that image button but i am unable to find the image button in the radgrid item data bound event.i am attaching the code below,please help me how i can aceive this : 

<
rad:RadGrid ID="radGridPlans" runat="server" 
            Skin="Outlook2007" 
            AutoGenerateColumns="False" 
            Width="100%" GridLines="None" 
            AllowPaging="True" PageSize="100" 
            AllowMultiRowSelection="True" 
            EnableAjax="True" EnableAJAXLoadingTemplate="True" LoadingTemplateTransparency="80"    > 
            <MasterTableView 
                DataKeyNames="PlanMstrID" Name="PlanMasters" 
                CommandItemDisplay="Top" 
                EditMode="InPlace" Width="100%" 
                GroupsDefaultExpanded="False" 
                NoMasterRecordsText="Please select an item in the list on the left."> 
                <DetailTables  > 
                    <rad:GridTableView DataKeyNames="PlanID" Name="PlanHeaders" Width="100%" runat="server"  > 
                        <Columns> 
                            <rad:GridClientSelectColumn UniqueName="SelectColumn"> 
                                <HeaderStyle Width="16px" /> 
                            </rad:GridClientSelectColumn> 
                     
                         
                            <rad:GridTemplateColumn UniqueName="EditColumn" > 
                                <HeaderStyle Width="16px"></HeaderStyle> 
                                <ItemStyle HorizontalAlign="Center"></ItemStyle> 
                                <ItemTemplate> 
                                    <asp:ImageButton ID="btnEditPlan" runat="server" CommandName="EditPlan" ImageUrl="~/Images/Edit.gif"> 
                                    </asp:ImageButton> 
                                </ItemTemplate> 
                            </rad:GridTemplateColumn> 
                            <rad:GridButtonColumn UniqueName="DeleteColumn"    CommandName="DeletePlan" Text="Delete plan..." 
                                ConfirmText="Are you sure you want to delete this plan?" ButtonType="ImageButton" 
                                ImageUrl="~/Images/Delete.gif" 
                            > 
                                <HeaderStyle Width="16px" /> 
                                <ItemStyle HorizontalAlign="Center" Height="16px" Width="16px"    /> 
                            </rad:GridButtonColumn> 
                            <rad:GridBoundColumn UniqueName="PlanID" DataField="PlanID" HeaderText="PlanId" Visible="False"> 
                            </rad:GridBoundColumn> 
                            <rad:GridBoundColumn UniqueName="PlanVersion" DataField="PlanVersion" HeaderText="Version"> 
                            </rad:GridBoundColumn> 
                            <rad:GridBoundColumn UniqueName="PlanVersionDesc" DataField="PlanVersionDesc" HeaderText="Description"> 
                            </rad:GridBoundColumn> 
                            <rad:GridBoundColumn UniqueName="PlanStatusName" DataField="PlanStatusName" HeaderText="Status"> 
                            </rad:GridBoundColumn> 
                            <rad:GridBoundColumn UniqueName="PlanRevenueType" DataField="PlanRevenueType" HeaderText="Revenue Type" Visible="False"> 
                            </rad:GridBoundColumn> 
                             <rad:GridTemplateColumn UniqueName="RevenueType" DataField="PlanRevenueTypeID" HeaderText="Rev. Mode"> 
                                <HeaderStyle HorizontalAlign="Center" ></HeaderStyle> 
                                <ItemStyle HorizontalAlign="Center"></ItemStyle> 
                                <ItemTemplate> 
                                     <asp:Image  ID="imgRevType" runat="server" ImageUrl="" ToolTip="Room Revenue Type: Full Calendar=Monthly Revenues; Multiple Days=Daily Revenues..." /> 
                                </ItemTemplate> 
                            </rad:GridTemplateColumn> 
                             
                            <rad:GridBoundColumn UniqueName="LastEditUser" DataField="LastEditUser" HeaderText="Last Edited By"> 
                            </rad:GridBoundColumn> 
                            <rad:GridBoundColumn UniqueName="LastEditTS" DataField="LastEditTS" HeaderText="Last Edited" 
                                DataFormatString="{0:MM/dd/yyyy hh:mm tt}" 
                            > 
                            </rad:GridBoundColumn> 
                            <rad:GridBoundColumn UniqueName="PlanMstrFiscalYear" DataField="PlanMstrFiscalYear" HeaderText="PlanMstrFiscalYear" Visible="False"> 
                            </rad:GridBoundColumn> 
                        </Columns> 
                        <RowIndicatorColumn> 
                            <HeaderStyle Width="20px" /> 
                        </RowIndicatorColumn> 
                        <ExpandCollapseColumn> 
                            <HeaderStyle Width="20px" /> 
                        </ExpandCollapseColumn> 
                    </rad:GridTableView> 
                </DetailTables> 
                <CommandItemTemplate> 
                    <div style="padding:3px 3px;" > 
                        <asp:LinkButton ID="btnNewPlan" runat="server" CommandName="NewPlan"> 
                            <img style="border:0px;vertical-align:Middle;" src="~/Images/New.gif" runat="server" alt="" /> 
                            Create New Plan... 
                        </asp:LinkButton> 
                        &nbsp; 
                        <asp:LinkButton ID="btnDeletePlan" runat="server" CommandName="DeleteSelected" 
                            OnClientClick="javascript:return confirm('Delete selected plan(s)?')" > 
                            <img style="border:0px;vertical-align:Middle;" src="~/Images/Delete.gif" runat="server" alt="" /> 
                            Delete selected plan(s)... 
                        </asp:LinkButton> 
                    </div> 
                </CommandItemTemplate> 
                <Columns> 
                    <rad:GridBoundColumn UniqueName="PlanMstrId" DataField="PlanMstrId" HeaderText="PlanMstrId" Visible="False"> 
                    </rad:GridBoundColumn> 
                    <rad:GridBoundColumn UniqueName="PropName" DataField="PropName" HeaderText="Property"> 
                    </rad:GridBoundColumn> 
                    <rad:GridBoundColumn UniqueName="PlanTypeName" DataField="PlanTypeName" HeaderText="Type"> 
                    </rad:GridBoundColumn> 
                    <rad:GridBoundColumn UniqueName="PlanMstrFiscalYear" DataField="PlanMstrFiscalYear" HeaderText="Year"> 
                    </rad:GridBoundColumn> 
                    <rad:GridBoundColumn UniqueName="PlanStatusName" DataField="PlanStatusName" HeaderText="Status"> 
                    </rad:GridBoundColumn> 
                    <rad:GridBoundColumn UniqueName="PlanVersions" DataField="PlanVersions" HeaderText="Versions"> 
                    </rad:GridBoundColumn> 
                    <rad:GridBoundColumn UniqueName="PlanHeaderLastEditTS" DataField="PlanHeaderLastEditTS" HeaderText="Last Edited" 
                        DataFormatString="{0:MM/dd/yyyy}" 
                    > 
                    </rad:GridBoundColumn> 
                </Columns> 
                <RowIndicatorColumn> 
                    <HeaderStyle Width="20px" /> 
                </RowIndicatorColumn> 
                <ExpandCollapseColumn Visible="True"> 
                    <HeaderStyle Width="20px" /> 
                </ExpandCollapseColumn> 
                <PagerStyle Mode="NextPrevNumericAndAdvanced" Position="Top" /> 
            </MasterTableView> 
            <ClientSettings 
                EnableClientKeyValues="True" 
            > 
                <Selecting AllowRowSelect="True" /> 
                <Resizing AllowColumnResize="True" EnableRealTimeResize="True" /> 
                <Scrolling    UseStaticHeaders="True"/> 
            </ClientSettings> 
            <SortingSettings SortedBackColor="212, 208, 200" /> 
        </rad:RadGrid> 
======================================================================================================================
i want to find image button "btnEditPlan" from the above source and bind the Image URL for that in the item data bound.
 
 
Princy
Top achievements
Rank 2
 answered on 02 Dec 2009
3 answers
151 views
Hello,

I am looking for an input allowing to enter units values for all css admitted units, like 10px,50%,5em etc.

Could we do this with Telerik, I found nothing in library ?
Seems the only way is to create a composite control with a RadMaskedTextBox and a radCombobox ?


Thanks for ideas.
CS
Dimo
Telerik team
 answered on 02 Dec 2009
3 answers
445 views
Hi,
I need to provide a drag drop mapping between elements of two lists or even two trees by dragging.
Does telerik provide anything like what is asked in this post: http://forums.asp.net/p/1169599/2157868.aspx#2157868
Any resources or pointers also can help. At this point all I can think of is intercepting the drag events of telerik trees and draw an arrow using open source javascript drawing libraries.

Thank you for your time,
Veselin Vasilev
Telerik team
 answered on 02 Dec 2009
3 answers
171 views
I am using Q3 2009 ASP.Net AJAX controls. I am trying to mimic sample with Grid, client site binding and Order/Details navigation.
I have created my own WCF Service based on GridMasterDetailService.cs from samples.

My Model is inside namespace like: AAA.BBB.CCC.Model and has been generated as MyDBNameDataContext class.
The service uses slightly different namespace: AAA.BBB.CCC.MyService. Inside it I am making call like:

RadGrid.GetBindingData("AAA.BBB.CCC.Model.MyDBNameDataContext", ....)
 
However any time I call it it errors out with "Could not find the type specified in the ContextTypeName property of LinqDataSource ''."

- I have tried all combinations of naming the data context by cutting out all sub-names from the full namespace
- I have compiled and run the sevice with "new MyDBNameDataContext()" just before the GetBindingData call - it works.

Does anybody know what I am missing? Is there any special keyword that GetBindingData requires?

On more thing: my WCF service is not hosted inside IIS. I have noticed that the inner exception comes from System.Web library. So additional question is: can the RadGrid.GetBindingData be hosted outside IIS?

Thanks.
Veli
Telerik team
 answered on 02 Dec 2009
2 answers
115 views
Hi,
I have just upgraded my code to Q3 2009 from Q2 2008.
Within my scheduler i hade made appointments different colours depending on the resource.
Here is my code...
Protected Sub RadScheduler1_AppointmentCreated(ByVal sender As Object, ByVal e As Telerik.Web.UI.AppointmentCreatedEventArgs) Handles RadScheduler1.AppointmentCreated  
        If Not e.Appointment.Attributes("ResourceBackColor") = Nothing Then 
            Dim rsWrap As WebControl = e.Container.Parent.Parent.Parent.Parent.Parent  
            Dim rsApt As WebControl = e.Container.Parent.Parent.Parent.Parent  
            Dim rsAptWrap As WebControl = e.Container.Parent.Parent.Parent  
            Dim rsAptInner As WebControl = e.Container.Parent.Parent  
            rsAptInner.Style("background-color") = e.Appointment.Attributes("ResourceBackColor")  
        Else 
            Dim rsWrap As WebControl = e.Container.Parent.Parent.Parent.Parent.Parent  
            Dim rsApt As WebControl = e.Container.Parent.Parent.Parent.Parent  
            Dim rsAptWrap As WebControl = e.Container.Parent.Parent.Parent  
            Dim rsAptInner As WebControl = e.Container.Parent.Parent  
            rsAptInner.Style("background-color") = "Khaki" 'STD COLOUR  
        End If 
End Sub 
This does not seem to change the backcolor anymore.
Any ideas please ?

Many Thanks
Mark
Mark
Top achievements
Rank 1
 answered on 02 Dec 2009
3 answers
327 views
Hi forum Members

Here we are in a thought of having some new features (say Filtering, sorting & paging) to existing "Gridview" which was implemented across our application, which contains more than 200 pages where we used all sort of asp.net "Gridview" events.

 

Replacing of GridView with RadGrid results in lot of code change across the application which stops us to move forward.we are looking for a solution whether telerik can provide a control(RadGrid) which supports the above mentioned features & existing Gridview events.

 

 

Thanks
Sebastian
Telerik team
 answered on 02 Dec 2009
2 answers
135 views
Hi,
I am using Panelbar control as my left navigation menu. I need to show the panelbar as expanded and show all the submenu items when the page loading. what property i shod use for enabling this. I used  ExpandMode="MultipleExpandedItems"  . but doesnt work

Thanks,
Jeevitha
jeevitha
Top achievements
Rank 1
 answered on 02 Dec 2009
1 answer
118 views
hi

my insert delete and update events are not firing..

i need help here is my code
aspx that contain radgrid:
<%@ Page Language="vb"MasterPageFile="Main.Master" AutoEventWireup="false" CodeBehind="UTEPagine.aspx.vb" Inherits="WebBIODemo.UTEPagine" %> 
  
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %> 
 
<asp:Content ID="Content1" ContentPlaceHolderID="cphMain" Runat="Server">  
  <div style="height:500px">  
      <telerik:RadScriptManager ID="RadScriptManager1" runat="server">  
      </telerik:RadScriptManager>  
 
    <!-- content start --> 
     
    <div> 
       <telerik:RadCodeBlock ID="RadCodeBlock1" runat="server"> 
            <script type="text/javascript"> 
            function ShowEditForm(id, rowIndex) 
            { 
                var grid = $find("<%= grdUTEPagine.ClientID %>"); 
                 
                var rowControl = grid.get_masterTableView().get_dataItems()[rowIndex].get_element(); 
                grid.get_masterTableView().selectItem(rowControl, true); 
                         
                window.radopen("EditUTEPagineDemo.aspx?Id=" + id, "rwdUTEPagine"); 
                return false; 
            } 
            function ShowInsertForm() 
            { 
               window.radopen("EditUTEPagineDemo.aspx", "rwdUTEPagine"); 
               return false; 
            } 
            function refreshGrid(arg) 
            { 
             if(!arg) 
             { 
             $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("Rebind");             
                } 
                else 
                { 
             $find("<%= RadAjaxManager1.ClientID %>").ajaxRequest("RebindAndNavigate");             
                } 
            } 
            function RowDblClick(sender, eventArgs) 
            { 
             var param = eventArgs.getDataKeyValue("CODICELINGUA") + "|" + eventArgs.getDataKeyValue("CODICEFORM"); 
             window.radopen("EditUTEPagineDemo.aspx?Id=" + param , "rwdUTEPagine"); 
            } 
            </script> 
        </telerik:RadCodeBlock> 
         
            <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" OnAjaxRequest="RadAjaxManager1_AjaxRequest"> 
                <AjaxSettings> 
                    <telerik:AjaxSetting AjaxControlID="RadAjaxManager1"> 
                        <UpdatedControls> 
                            <telerik:AjaxUpdatedControl ControlID="grdUTEPagine" /> 
                        </UpdatedControls> 
                    </telerik:AjaxSetting> 
                    <telerik:AjaxSetting AjaxControlID="grdUTEPagine"> 
                        <UpdatedControls> 
                            <telerik:AjaxUpdatedControl ControlID="grdUTEPagine" /> 
                        </UpdatedControls> 
                    </telerik:AjaxSetting> 
                </AjaxSettings> 
            </telerik:RadAjaxManager> 
            <telerik:RadGrid 
                OnItemCreated="grdUTEPagine_ItemCreated" 
                ID="grdUTEPagine" 
                runat="server" 
                AllowPaging="True" 
                AllowCustomPaging="True" 
                AutoGenerateColumns="False"  
                AllowSorting="True" 
                PageSize="35" 
                AllowFilteringByColumn="True"                  
                Width="97%" 
                DataSourceID="objDS"> 
                <PagerStyle Mode="NumericPages" /> 
                <MasterTableView 
                    AutoGenerateColumns="False" 
                    DataKeyNames="CODICELINGUA,CODICEFORM" 
                    ClientDataKeyNames="CODICELINGUA,CODICEFORM" 
                    Width="100%" 
                    CommandItemDisplay="Top" 
                    PageSize="15"> 
                    <Columns> 
                        <telerik:GridTemplateColumn UniqueName="EditRecord" AllowFiltering="False" Resizable="False">                            
                            <ItemTemplate> 
                                <asp:HyperLink ID="EditLink" runat="server" Text="Edit"></asp:HyperLink> 
                            </ItemTemplate> 
                            <HeaderStyle Width="24px" /> 
                        </telerik:GridTemplateColumn> 
 
                           <telerik:GridBoundColumn DataField="CODICELINGUA" HeaderText="Codice Lingua" SortExpression="CODICELINGUA"  
                                UniqueName="colCODICELINGUA" FilterImageToolTip="Filtro per Codice Lingua" Resizable="true">                                 
                            </telerik:GridBoundColumn>  
 
                           <telerik:GridBoundColumn DataField="DESCRIZIONE" HeaderText="Descrizione" SortExpression="DESCRIZIONE"  
                                UniqueName="colDESCRIZIONE" FilterImageToolTip="Filtro per descrizione" Resizable="true">  
                                <HeaderStyle Width="310px" />  
                            </telerik:GridBoundColumn>        
                                      
                            <telerik:GridBoundColumn DataField="DESCRIZIONEAIUTO" HeaderText="Descrizione AIUTO" SortExpression="DESCRIZIONEAIUTO"  
                                UniqueName="colDESCRIZIONEAIUTO" FilterImageToolTip="Filtro per descrizione inglese" Resizable="true">  
                                <HeaderStyle Width="310px" />  
                            </telerik:GridBoundColumn>                    
  
                            <telerik:GridBoundColumn DataField="ANNOTAZIONI" HeaderText="ANNOTAZIONI" SortExpression="ANNOTAZIONI"  
                                UniqueName="colANNOTAZIONI" FilterImageToolTip="Filtro per descrizione inglese" Resizable="true">  
                                <HeaderStyle Width="310px" />  
                            </telerik:GridBoundColumn>    
                                                     
                        <telerik:GridButtonColumn ConfirmText="Eliminare Utente Pagina?" ButtonType="ImageButton" ImageUrl="_img/Delete.gif" CommandName="Delete" Text="Elimina" UniqueName="colDelete"> 
                            <HeaderStyle Width="20px" /> 
                        </telerik:GridButtonColumn>  
 
                    </Columns> 
                    <CommandItemTemplate> 
                        <a href="#" onclick="return ShowInsertForm();">Add New Record</a> 
                    </CommandItemTemplate> 
                </MasterTableView> 
                <ClientSettings> 
                    <Selecting AllowRowSelect="true" /> 
                    <ClientEvents OnRowDblClick="RowDblClick" /> 
                </ClientSettings> 
            </telerik:RadGrid> 
             
            <telerik:RadWindowManager ID="RadWindowManager1" runat="server"> 
                <Windows> 
                    <telerik:RadWindow ID="rwdUTEPagine" runat="server" Title="Editing record" Height="400px" 
                        Width="500px" Left="150px" ReloadOnShow="true" ShowContentDuringLoad="false" Modal="true" /> 
                    <telerik:RadWindow runat="server" Title="WebBIO Zoom" Behaviors="none" Animation="FlyIn" DestroyOnClose="true"   
                Left="" ID="rdwCodiceLingue"  NavigateUrl="Zoom.aspx" /> 
                </Windows> 
            </telerik:RadWindowManager> 
    <asp:ObjectDataSource   
        ID="objDS"   
        runat="server"   
        SelectMethod="selectUTEPagine"       
        DeleteMethod="deleteUTEPagine"        
        SortParameterName="orderBy"  
        TypeName="GestioneLingue"  
        ConflictDetection="CompareAllValues"  
        OldValuesParameterFormatString="orig_{0}">  
        <SelectParameters>  
            <asp:ControlParameter ControlID="grdUTEPagine" Name="filterBy" PropertyName="MasterTableView.FilterExpression" Type="String" />  
        </SelectParameters>  
          
        <DeleteParameters>  
            <asp:Parameter Name="orig_CODICELINGUA" Type="String" />  
            <asp:Parameter Name="orig_CODICEFORM" Type="Int32" />  
        </DeleteParameters>  
          
    </asp:ObjectDataSource>         
      </div>  
  </div>  
</asp:Content>  

edit form:
<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="EditUTEPagineDemo.aspx.vb" Inherits="WebBIODemo.EditUTEPagineDemo" %> 
 
<%@ 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 id="Head1" runat="server"> 
    <title>WebBIO Demo</title> 
    <link href="../_styles/main.css" type="text/css" rel="stylesheet" /> 
</head> 
 
<body style="margin:0px;height:100%;overflow:hidden" scroll="yes"> 
    <form id="EditUTEPagine" runat="server"  style="height:100%;margin:0px;" method="post"> 
   <script type="text/javascript"> 
        function CloseAndRebind(args) 
        { 
            GetRadWindow().Close(); 
            GetRadWindow().BrowserWindow.refreshGrid(args); 
        } 
         
        function GetRadWindow() 
        { 
            var oWindow = null; 
            if (window.radWindow) oWindow = window.radWindow; //Will work in Moz in all cases, including clasic dialog 
            else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;//IE (and Moz as well) 
                 
            return oWindow; 
        } 
 
        function CancelEdit() 
        { 
            GetRadWindow().Close();      
        } 
 
 
         function OpenWin(cod) 
            { 
                var parentPage = GetRadWindow().BrowserWindow; 
                var parentRadWindowManager = parentPage.GetRadWindowManager(); 
                var oWnd2 = parentRadWindowManager.open("Zoom.aspx?KA=" + cod, "rdwCodiceLingue");   
                window.setTimeout(function() 
                { 
                    oWnd2.setActive(true);  
                },0);                                               
            } 
         function getZoomValue(args) { 
                alert(args); 
                var arg = args.split("|") 
                var QualeControllo;  
                if (args[0] != null) {  
                    if (arg[0] == "CL"){ 
                        QualeControllo = document.getElementById("<%= txtCODICELINGUA.ClientID %>"); 
                    } 
                    else{ 
                        QualeControllo = document.getElementById("<%= txtCODICEFORM.ClientID %>"); 
                    } 
                    QualeControllo.value = arg[1];  
                }  
            } 
    </script>      
    <div> 
      <asp:Label runat="server" ID="injectScript" Visible="true" Text="" ></asp:Label> 
      <asp:HiddenField runat="server" ID="lblIDtabella" Value="" /> 
      <telerik:RadScriptManager ID="RadScriptManager1" runat="server" /> 
      <telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" /> 
      
 
      <table cellspacing="5" cellpadding="5" border="0" width="500px"> 
        <tr> 
            <th colspan="2"><asp:label ID="lblTitle" runat="server" /></th> 
        </tr> 
        <tr> 
            <td> 
                <asp:Label ID="lblCODICELINGUA" Text="Codice Lingua:  " runat="server" /> 
 
                <asp:ImageButton ID="cmdZOOMcodL" OnClientClick="OpenWin('CL'); return false;" runat="server"  ImageUrl="_img/lens.gif" /> 
                <asp:textbox ID="txtCODICELINGUA"  runat="server" Enabled="false" MaxLength="4" /> 
            </td> 
            <td> 
                <asp:label ID="lblCODICEFORM" Text="Codice Form:  " runat="server" /> 
 
                <asp:ImageButton ID="cmdZOOMcodF" OnClientClick="OpenWin('CF'); return false;" runat="server" ImageUrl="_img/lens.gif" /> 
                <asp:textbox ID="txtCODICEFORM" runat="server" Enabled="false" /> 
            </td>             
        </tr> 
        <tr> 
            <td> 
                <asp:Label ID="lblDESCRIZIONE" Text="Descrizione: " runat="server" /> 
            </td> 
            <td> 
                <asp:Label ID="lblDESCRIZIONEAIUTO" Text="Descrizione aiuto: " runat="server" /> 
            </td> 
            <td> 
                <asp:Label ID="Label1" Text="Descrizione aiuto: " runat="server" /> 
            </td> 
        </tr> 
        <tr> 
            <td> 
                <telerik:RadTextBox ID="rdtDESCRIZIONE" runat="server" TextMode="MultiLine" Width="220px" Height="90px" /> 
            </td>         
            <td> 
                <telerik:RadTextBox ID="rdtDESCRIZIONEAIUTO" runat="server" TextMode="MultiLine" Width="220px" Height="90px" /> 
            </td> 
 
            <td> 
                <telerik:RadTextBox ID="rdtANNOTAZIONI" runat="server" TextMode="MultiLine" Width="220px" Height="90px" /> 
            </td> 
        </tr> 
            <tr><td colspan="2" style="height:10px"></td></tr>                           
            <tr> 
                <td> 
                    <asp:ValidationSummary ID="vsSummary" runat="server" Enabled="true" DisplayMode="BulletList" ShowSummary="false" ShowMessageBox="true" EnableClientScript="true" HeaderText="I seguenti campi devono essere valorizzati correttamente :"/> 
                </td> 
            </tr> 
            <tr> 
                <td colspan="2" style="text-align:right;"> 
                    <table cellpadding="0" cellspacing="10px" width="100%"> 
                        <tr> 
                            <td width="95%"></td> 
                            <td><asp:Button runat="server" id="btnSave" Text="Salva" OnClick="btnSave_Click" Width="80px"/></td> 
                            <td><button id="btnCancel" runat="server" onclick="closeRadWindow()" style="width:80px">Annulla</button></td> 
                        </tr> 
                    </table>                     
                </td> 
            </tr> 
            <tr> 
                <td colspan="2"><asp:Label runat="server" ID="lblErrorMsg" Text=""></asp:Label></td> 
            </tr>         
      </table> 
 
    </div> 
</form> 
</body> 
</html> 

code behind of edit
 
Partial Public Class EditUTEPagineDemo 
    Inherits System.Web.UI.Page 
    Private m_wnd As Main 
 
    Dim id() As String 
    Dim param() As String 
    Dim paramVal() As String 
    Private clFunz As New WebBIODemo.Funzioni() 
 
    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load 
        m_wnd = TryCast(Master, Main) 
        If Not IsPostBack Then 
            Dim idparam() As String 
            ReDim idparam(0 To 1) 
            idparam(0) = "CODICELINGUA" 
            idparam(1) = "CODICEFORM" 
            ' Determines if inserting or editing an existing prodotto 
            If Request.QueryString("ID") = Nothing Then 
                ' New prodotto 
                lblIDtabella.Value = "" 
                lblTitle.Text = "Nuovo UTEPagine" 
            Else 
                ' Determines if user is is valid 
                cmdZOOMcodF.Visible = False 
                cmdZOOMcodL.Visible = False 
                Try 
                    lblIDtabella.Value = Request.QueryString("ID") 
                    id = Split(lblIDtabella.Value, "|") 
                    lblTitle.Text = "Modifica UTEPagine" 
 
                    ApriConnessioni() 
                    Call EseguiStored("UTEPagine_SelectInfoUP", idparam, id, kDataReader) 
                    With DR 
                        If .Read = True Then 
                            txtCODICELINGUA.Text = Nz(.GetValue(.GetOrdinal("CODICELINGUA")), "") 
                            txtCODICEFORM.Text = Nz(.GetValue(.GetOrdinal("CODICEFORM")), 0) 
                            rdtDESCRIZIONE.Text = Nz(.GetValue(.GetOrdinal("DESCRIZIONE")), "") 
                            rdtDESCRIZIONEAIUTO.Text = Nz(.GetValue(.GetOrdinal("DESCRIZIONEAIUTO")), "") 
                            rdtANNOTAZIONI.Text = (Nz(.GetValue(.GetOrdinal("ANNOTAZIONI")), "")) 
                        End If 
                        .Close() 
                    End With 
                    ChiudiConnessioni() 
 
                Catch _err As Exception 
                    ' Bad format for prodotto id 
                    ' Assumes inserting a new prodotto 
                    lblIDtabella.Value = "" 
                    lblTitle.Text = "Nuovo UTEPagine" 
                End Try 
            End If 
        End If 
    End Sub 
 
    Protected Sub btnSave_Click(ByVal sender As Object, ByVal e As EventArgs) 
        ' Checks if user entered necessary data 
        If IsValid = True Then 
            If lblIDtabella.Value = "" Then 
                ' Do insert 
 
                Try 
                    'mettere l'esecuzione sp 
                    ApriConnessioni() 
                    ReDim param(0 To 6) 
                    ReDim paramVal(0 To 6) 
                    param(0) = "IDWS" 
                    paramVal(0) = IDWSname() 
                    param(1) = "NOTAMOD" 
                    paramVal(1) = "" 
                    param(2) = "CODICELINGUA" 
                    paramVal(2) = txtCODICELINGUA.Text 
                    param(3) = "CODICEFORM" 
                    paramVal(3) = txtCODICEFORM.Text 
                    param(4) = "DESCRIZIONE" 
                    paramVal(4) = rdtDESCRIZIONE.Text 
                    param(5) = "DESCRIZIONEAIUTO" 
                    paramVal(5) = rdtDESCRIZIONEAIUTO.Text 
                    param(6) = "ANNOTAZIONI" 
                    paramVal(6) = rdtANNOTAZIONI.Text 
 
                    EseguiStored("UTEPagine_Insert", param, paramVal, kAggiornaDati) 
 
                    ChiudiConnessioni() 
 
                    injectScript.Text = "<script type='text/javascript'>CloseAndRebind('insert')</script>" 
                Catch _err As Exception 
                    ' Error during insertion 
                    ' TODO : Show Error Message 
                    lblErrorMsg.Text = "Errore durante ins. dati - " + _err.Source + "->" + _err.Message 
                End Try 
            Else 
                ' Do update 
 
                Try 
                    'execution stored 
                    ApriConnessioni() 
 
                    ReDim param(0 To 6) 
                    ReDim paramVal(0 To 6) 
 
                    param(0) = "IDWS" 
                    paramVal(0) = IDWSname() 
                    param(1) = "NOTAMOD" 
                    paramVal(1) = "" 
                    param(2) = "CODICELINGUA" 
                    paramVal(2) = txtCODICELINGUA.Text 
                    param(3) = "CODICEFORM" 
                    paramVal(3) = txtCODICEFORM.Text 
                    param(4) = "DESCRIZIONE" 
                    paramVal(4) = rdtDESCRIZIONE.Text 
                    param(5) = "DESCRIZIONEAIUTO" 
                    paramVal(5) = rdtDESCRIZIONEAIUTO.Text 
                    param(6) = "ANNOTAZIONI" 
                    paramVal(6) = rdtANNOTAZIONI.Text 
 
                    EseguiStored("UTEPagine_Insert", param, paramVal, kAggiornaDati) 
 
                    ChiudiConnessioni() 
 
                    injectScript.Text = "<script type='text/javascript'>CloseAndRebind('update');</script>" 
 
                Catch _err As Exception 
                    ' Error in updating  
                    ' TODO : Show Error Message 
                    lblErrorMsg.Text = "Errore durante agg. dati - " + _err.Source + "->" + _err.Message 
                End Try 
            End If 
        End If 
    End Sub 
 
End Class 



Princy
Top achievements
Rank 2
 answered on 02 Dec 2009
Narrow your results
Selected tags
Tags
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?