Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
226 views
I am dynamically generating a bunch of controls, including a TimePicker.  Everything works fine, except the TimePicker refuses to use 24-hour format.

If I do this:
    Select time: <telerik:RadTimePicker ID="RadTimePicker1" runat="server" >
            <TimeView StartTime="9:0:0" EndTime="17:31:00" Interval="0:30:0" Columns="5" TimeFormat="HH:mm">
            </TimeView>
            <DateInput DateFormat="HH:mm"></DateInput>
        </telerik:RadTimePicker>

it works fine but if I do this:

protected override void CreateChildControls()
{
.... var timePicker = new RadTimePicker();
timePicker.ID = String.Format("DynamicControl{0}", parameterNumber);
timePicker.SelectedDate = DateTime.Now;
var timeView = new RadTimeView();
timeView.StartTime = new TimeSpan(9, 0, 0);
timeView.EndTime = new TimeSpan(17, 31, 0);
timeView.Interval = new TimeSpan(0, 30, 0);
timeView.Columns = 5;
timeView.TimeFormat = "HH:mm";
timePicker.Controls.Add(timeView);
var dateInput = new Telerik.Web.UI.RadDateInput();
dateInput.DateFormat = "HH:mm";
dateInput.DisplayDateFormat = "HH:mm";
timePicker.Controls.Add(dateInput);
...
}

It uses AM/PM format. 
What am I missing to get it to pay attention to my TimeFormat/DateFormat?

I am using Telerik.Web.UI 2009.1.402.35 on Visual Studio 9.0.30729.1 SP on Vista.
It happens on IE8 and FireFox 3.



Matthew
Top achievements
Rank 1
 answered on 26 Apr 2009
0 answers
145 views
Hello I have got problems with radupload
I disadi to rename file that i save on the server.
1 step: i control tah file with this name is present in server folder
when not i save ther wit orginal name 
when is present i save with diferent name. 
My problem is that radcontrol is saving 2 time file wit orginal name text.txt and text1.txt 
I was used code writed by Petya

------- code by Petya----------

Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
        For Each file1 As UploadedFile In RadUpload1.UploadedFiles
            If (File.Exists(Server.MapPath(Path.Combine("files", file1.GetName())))) Then
                file1.SaveAs(Server.MapPath(Path.Combine("files", file1.GetNameWithoutExtension() + "1" + file1.GetExtension())), True)
            Else
                file1.SaveAs(Server.MapPath(Path.Combine("files", file1.GetName())))
            End If
        Next

    End Sub

---------------------------------------------------

I modificated code

-----------------My code--------------------

    Dim i As Integer
        i = 0

        For Each file1 As UploadedFile In uploadFly.UploadedFiles
            If (File.Exists(Server.MapPath(Path.Combine("upload/flv", file1.GetName())))) Then
                file1.SaveAs(Server.MapPath(Path.Combine("upload/flv", file1.GetNameWithoutExtension() + "1" + file1.GetExtension())), True)
            Else
                If i = 0 Then
                    i = 1
                    file1.SaveAs(Server.MapPath(Path.Combine("upload/flv/temp", file1.GetName())))
                    i = 1
                    i = 1
                    i = 1
                    i = 1
                    lab11.Text = i.ToString

                Else
                    file1.SaveAs(Server.MapPath(Path.Combine("upload/flv", file1.GetName())))

                End If
              
            End If
            Exit For
        Next


----------------------------------------------------------------
Always radupload do fro me 2 coy of file :( 

Using breadpoin i view that in any case loop "For each" is doing twice for this reasons i was insered "If i=0" when i=1 i change the directory but after first loop in memory i view always 0. Can you control this problem ??


-------------------------------------------Radupload on my page--------------------------
<br />
<telerik:RadUpload ID="uploadFly" Runat="server" Skin="Hay" MaxFileInputsCount="1"  OverwriteExistingFiles="false">
</telerik:RadUpload>
<br />

-------------------------------------------------------------------------------------------------------

Sorry for my english and thanks for help
Krzysztof
Top achievements
Rank 1
 asked on 25 Apr 2009
7 answers
701 views
I like the features of the numeric textbox but was wondering if I could implement it so that a user entered a decimal and it was shown as a percentage (ie enter 0.01 and see 1%).  I'm hoping to not have to use the masked textbox since it seems there that you are predefining the size of the text.
ManniAT
Top achievements
Rank 2
 answered on 25 Apr 2009
0 answers
90 views
Hi,
I`m trying to use the rad uploader but I dont know what exactly I have to add to web.config

I tried many times but it failed, I read the help many times but it was usless to me (or I didn`t understand it well).
so please I want a small example about how to upload File(s) using RadUploader with a progress bar area

or tell me step by step what I have to do to use it successfully

Regards
Mando
Top achievements
Rank 1
 asked on 25 Apr 2009
0 answers
118 views
Here, We can take multiple xml file as contextmenu..

 foreach (RadTreeNode node in RadTreeView1.GetAllNodes())
        {         
            if (node.Level == 0)
            {
                RadTreeViewContextMenu cn = new RadTreeViewContextMenu();
                cn.LoadContentFile("ContextMenu.xml");
                node.TreeView.ContextMenus.Add(cn);
                node.ContextMenuID = cn.ID;
            }
            else if (node.Level == 1)
            {
                RadTreeViewContextMenu cn = new RadTreeViewContextMenu();
                cn.LoadContentFile("ContextMenu1.xml");
                node.TreeView.ContextMenus.Add(cn);
                node.ContextMenuID = cn.ID;
            }
            else
            {
                RadTreeViewContextMenu cn = new RadTreeViewContextMenu();
                cn.LoadContentFile("ContextMenu2.xml");
                node.TreeView.ContextMenus.Add(cn);
                node.ContextMenuID = cn.ID;
            }

        }
Minesh
Top achievements
Rank 1
 asked on 25 Apr 2009
1 answer
130 views
Sometimes I need to setup a CommandItemTemplate and need to setup my own "Add new" and "Refresh" buttons (<asp:ImageButton runat="server" ID="refreshGrid" ImageUrl="~/Images/refresh.gif" CommandArgument="Refresh" />).
When I skin other grids in the same project, I'd like custom CommandItemTemplates to look the same.

How do I get/download/reference the icons from specific Telerik standard skins?
Princy
Top achievements
Rank 2
 answered on 25 Apr 2009
1 answer
108 views
Hi

Issue :1
      I used the drop down with in treeview(with check box) Control.  Here with When i have selected the node. The node showing the drod dwon selected text like India, USA,.... When the Postback the page that time the selected text is disapper. Let me know how can i handle this problem.

Issue: 2
    The Above concepts similar I am trying that  to (http://www.luxuryretreats.com/)  Drop down Logic.  When i Click the First dropdown the Ajax is Properly Working.. When i was Clicking the Second Dropdwon that time the page is Postback. I had used the simlar Logic in First Down.. Let me know how can i solve this problem.
Princy
Top achievements
Rank 2
 answered on 25 Apr 2009
7 answers
824 views
Hi,

What happen with the skin previews for all controls?
have they been taken out from the new site on purpose or is it an oversight?

Thanks,
Sasha
Steve Newbery
Top achievements
Rank 1
 answered on 25 Apr 2009
1 answer
144 views
Hello,

Is there a way to only allow Wednesdays to be picked from the datepicker and gray out the rest of the dates ?

Thanks
Gina
Shinu
Top achievements
Rank 2
 answered on 25 Apr 2009
1 answer
80 views
I want all the items in a grid (including child grids) to look the same. I have this working in one grid but forgot how I turned off alternating styles. Now I'm trying to get another grid setup the same way and no matter what I setup the rows look different and I can remember where the setting for turning off alternatingitemstyles is. Any help??????

Thanks,

Joe B
ManniAT
Top achievements
Rank 2
 answered on 24 Apr 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?