
Dim ai As New AppointmentInfo("Test", "02/05/2009 12:00:00 PM", "02/05/2009 2:00:00 PM", Telerik.Web.UI.RecurrenceState.Occurrence)
ai.ProviderId = 1
Dim al As New List(Of AppointmentInfo)
al.Add(ai)
Dim rtProviders As New ResourceType("Providers")
Dim dtProviders As New Data.DataTable("Providers")
dtProviders.Columns.Add(
"ProviderId")
dtProviders.Columns.Add(
"ProviderName")
dtProviders.Rows.Add(
"1", "Edward McLaughlin")
dtProviders.Rows.Add(
"2", "Tom McDonald")
rtProviders.DataSource = dtProviders
rtProviders.ForeignKeyField =
"ProviderId"
rtProviders.KeyField =
"ProviderId"
rtProviders.TextField =
"ProviderName"
RadScheduler1.ResourceTypes.Add(rtProviders)
Dim rtRooms As New ResourceType("Rooms")
rtRooms.AllowMultipleValues =
False
Dim dt As New Data.DataTable("Rooms")
dt.Columns.Add(
"RoomId")
dt.Columns.Add(
"Name")
dt.Rows.Add(
"1", "Exam Room A")
rtRooms.DataSource = dt
rtRooms.KeyField =
"RoomId"
rtRooms.TextField =
"Name"
rtRooms.ForeignKeyField =
"RoomId"
RadScheduler1.ResourceTypes.Add(rtRooms)
RadScheduler1.TimelineView.GroupBy =
"Providers"
RadScheduler1.TimelineView.GroupingDirection = Telerik.Web.UI.GroupingDirection.Vertical
RadScheduler1.HoursPanelTimeFormat =
"hh:mm tt"
RadScheduler1.DataSource = al
RadScheduler1.DataBind()
Thanks!
Hi,
I have a RadGrid which exports data successfully in both Excel and .CSV file. The odd behaviour I am noticing is that when the page is run in intranet, IE prompts to either open/save the exported file. If I click on open, Excel application automatically opens it.
The same application when deployed in internet behaves differently. Exported data from grid is not opened automatically by excel instead prompts "OPEN WITH" different list of applications to choose from. File type is not recognized and original file name should be "PO_Media_Report_Excel.xls" rather it shows PO_Media_Report [1] or something like that.... :(
Could you please let me know why is it happening?
Codesnippet as below:
gridPOMedia.ExportSettings.ExportOnlyData =
True
gridPOMedia.ExportSettings.IgnorePaging = True
gridPOMedia.ExportSettings.OpenInNewWindow = True
gridPOMedia.ExportSettings.FileName = "PO_Media_Report_Excel" + Now.Date
gridPOMedia.MasterTableView.ExportToExcel()
On the same note, why the .pdf export looks so horrible. If you have say around 10-15 columns in the grid, column data are overlapping.
Many thanks for suggestion.
Milan G
| Protected Sub RG2_ItemCreated(ByVal sender As Object, ByVal e As GridItemEventArgs) Handles RG2.ItemCreated |
| If TypeOf e.Item Is GridDataItem Then |
| AddHandler e.Item.PreRender, AddressOf RG2_ItemPreRender |
| End If |
| End Sub |
| Protected Sub RG2_ItemPreRender(ByVal sender As Object, ByVal e As EventArgs) |
| CType(CType(sender, GridDataItem)("CheckBoxTemplateColumn").FindControl("chkbxFacility"), CheckBox).Checked = CType(sender, GridDataItem).Selected |
| End Sub |
| For Each ID As String In facilityID |
| IDList += ID & "," |
| Next |
| IDList.Remove(IDList.LastIndexOf(","), 1) |
| 'Track the checks |
| Dim facilityID As New List(Of String) |
| For Each dataItem As GridDataItem In RG3.MasterTableView.Items |
| If CType(dataItem.FindControl("chkbxFacility"), CheckBox).Checked = True Then |
| facilityID.Add(dataItem.OwnerTableView.DataKeyValues(dataItem.ItemIndex)("FacilityID").ToString()) |
| End If |
| Next |
| Return facilityID |
| 'function for any changes or additions |
| If (CType(sender, CheckBox)).Checked Then |
| For Each dataItem As GridDataItem In RG2.MasterTableView.Items |
| CType(dataItem.FindControl("chkbxFacility"), CheckBox).Checked = True |
| dataItem.Selected = True |
| Next |
| Else |
| For Each dataItem As GridDataItem In RG2.MasterTableView.Items |
| CType(dataItem.FindControl("chkbxFacility"), CheckBox).Checked = False |
| dataItem.Selected = False |
| Next |
| End If |
| 'Make alternate call to FillDepartment to recognize any changes to the facility check box list |
| FillDepartment(RG2_GetFacilityIDs) |
<
telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" EnableAJAX="true" DefaultLoadingPanelID="LoadingPanel1" UpdatePanelsRenderMode="Inline">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="pnlVesselParams">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="pnlVessel" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="pnlInspections" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="pnlDocuments" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="pnlVesselDetails" />
<telerik:AjaxUpdatedControl ControlID="pnlVesselImage" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="rgVessel">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="pnlVessel" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="pnlInspections" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="pnlDocuments" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
<telerik:AjaxUpdatedControl ControlID="pnlVesselDetails" />
<telerik:AjaxUpdatedControl ControlID="pnlVesselImage" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="rgInspections">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="pnlInspections" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="rgDocuments">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="pnlDocuments" LoadingPanelID="LoadingPanel1"></telerik:AjaxUpdatedControl>
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
<telerik:RadAjaxLoadingPanel Transparency="50" Style="background-color: #E4E2DA;" runat="Server"
ID="LoadingPanel1" >
<asp:Image ID="Image2" ImageUrl="/RadControls/Ajax/Skins/Default/loading.gif" AlternateText="Loading"
BorderWidth="0px" runat="server"></asp:Image>
</telerik:RadAjaxLoadingPanel>
.RadMenu_IntegraTire
{
padding:10 10px;
width:100%;
}
.RadMenu_IntegraTire .link
{
background:#DCDCDB;
text-decoration:none;
text-align:left;
font-family:Lucida,Arial,sans-serif;
line-height:20px;
color:#6C6C6C;
letter-spacing:-0.05em;
border-bottom:solid 2px #ffffff;
}
I tried give .RadMenu_IntegraTire width 200px but it doesn't work. The website address is http://www.integratire.com.ds498.alentus.com/ for your reference.
Any idea about it? Thanks so much for your response.
Sally