Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 16a4fbc

Browse files
committedApr 23, 2018
initial commit
0 parents  commit 16a4fbc

37 files changed

+1723
-0
lines changed
 

‎.gitattributes

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
VB/* linguist-vendored
2+
scripts linguist-vendored
3+
*.css linguist-detectable=false
4+
*.aff linguist-detectable=false

‎.gitignore

Lines changed: 297 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,297 @@
1+
## Ignore Visual Studio temporary files, build results, and
2+
## files generated by popular Visual Studio add-ons.
3+
##
4+
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
5+
6+
# User-specific files
7+
*.suo
8+
*.user
9+
*.userosscache
10+
*.sln.docstates
11+
12+
# User-specific files (MonoDevelop/Xamarin Studio)
13+
*.userprefs
14+
15+
# Build results
16+
[Dd]ebug/
17+
[Dd]ebugPublic/
18+
[Rr]elease/
19+
[Rr]eleases/
20+
x64/
21+
x86/
22+
bld/
23+
[Oo]bj/
24+
[Ll]og/
25+
26+
# Visual Studio 2015 cache/options directory
27+
.vs/
28+
# Uncomment if you have tasks that create the project's static files in wwwroot
29+
#wwwroot/
30+
31+
# MSTest test Results
32+
[Tt]est[Rr]esult*/
33+
[Bb]uild[Ll]og.*
34+
35+
# NUNIT
36+
*.VisualState.xml
37+
TestResult.xml
38+
39+
# Build Results of an ATL Project
40+
[Dd]ebugPS/
41+
[Rr]eleasePS/
42+
dlldata.c
43+
44+
# Benchmark Results
45+
BenchmarkDotNet.Artifacts/
46+
47+
# .NET Core
48+
project.lock.json
49+
project.fragment.lock.json
50+
artifacts/
51+
**/Properties/launchSettings.json
52+
53+
*_i.c
54+
*_p.c
55+
*_i.h
56+
*.ilk
57+
*.meta
58+
*.obj
59+
*.pch
60+
*.pdb
61+
*.pgc
62+
*.pgd
63+
*.sbr
64+
*.tlb
65+
*.tli
66+
*.tlh
67+
*.tmp
68+
*.tmp_proj
69+
*.log
70+
*.vspscc
71+
*.vssscc
72+
.builds
73+
*.pidb
74+
*.svclog
75+
*.scc
76+
77+
# Chutzpah Test files
78+
_Chutzpah*
79+
80+
# Visual C++ cache files
81+
ipch/
82+
*.aps
83+
*.ncb
84+
*.opendb
85+
*.opensdf
86+
#*.sdf
87+
*.cachefile
88+
*.VC.db
89+
*.VC.VC.opendb
90+
91+
# Visual Studio profiler
92+
*.psess
93+
*.vsp
94+
*.vspx
95+
*.sap
96+
97+
# TFS 2012 Local Workspace
98+
$tf/
99+
100+
# Guidance Automation Toolkit
101+
*.gpState
102+
103+
# ReSharper is a .NET coding add-in
104+
_ReSharper*/
105+
*.[Rr]e[Ss]harper
106+
*.DotSettings.user
107+
108+
# JustCode is a .NET coding add-in
109+
.JustCode
110+
111+
# TeamCity is a build add-in
112+
_TeamCity*
113+
114+
# DotCover is a Code Coverage Tool
115+
*.dotCover
116+
117+
# AxoCover is a Code Coverage Tool
118+
.axoCover/*
119+
!.axoCover/settings.json
120+
121+
# Visual Studio code coverage results
122+
*.coverage
123+
*.coveragexml
124+
125+
# NCrunch
126+
_NCrunch_*
127+
.*crunch*.local.xml
128+
nCrunchTemp_*
129+
130+
# MightyMoose
131+
*.mm.*
132+
AutoTest.Net/
133+
134+
# Web workbench (sass)
135+
.sass-cache/
136+
137+
# Installshield output folder
138+
[Ee]xpress/
139+
140+
# DocProject is a documentation generator add-in
141+
DocProject/buildhelp/
142+
DocProject/Help/*.HxT
143+
DocProject/Help/*.HxC
144+
DocProject/Help/*.hhc
145+
DocProject/Help/*.hhk
146+
DocProject/Help/*.hhp
147+
DocProject/Help/Html2
148+
DocProject/Help/html
149+
150+
# Click-Once directory
151+
publish/
152+
153+
# Publish Web Output
154+
*.[Pp]ublish.xml
155+
*.azurePubxml
156+
# Note: Comment the next line if you want to checkin your web deploy settings,
157+
# but database connection strings (with potential passwords) will be unencrypted
158+
*.pubxml
159+
*.publishproj
160+
161+
# Microsoft Azure Web App publish settings. Comment the next line if you want to
162+
# checkin your Azure Web App publish settings, but sensitive information contained
163+
# in these scripts will be unencrypted
164+
PublishScripts/
165+
166+
# NuGet Packages
167+
*.nupkg
168+
# The packages folder can be ignored because of Package Restore
169+
**/packages/*
170+
# except build/, which is used as an MSBuild target.
171+
!**/packages/build/
172+
# Uncomment if necessary however generally it will be regenerated when needed
173+
#!**/packages/repositories.config
174+
# NuGet v3's project.json files produces more ignorable files
175+
*.nuget.props
176+
*.nuget.targets
177+
178+
# Microsoft Azure Build Output
179+
csx/
180+
*.build.csdef
181+
182+
# Microsoft Azure Emulator
183+
ecf/
184+
rcf/
185+
186+
# Windows Store app package directories and files
187+
AppPackages/
188+
BundleArtifacts/
189+
Package.StoreAssociation.xml
190+
_pkginfo.txt
191+
*.appx
192+
193+
# Visual Studio cache files
194+
# files ending in .cache can be ignored
195+
*.[Cc]ache
196+
# but keep track of directories ending in .cache
197+
!*.[Cc]ache/
198+
199+
# Others
200+
ClientBin/
201+
~$*
202+
*~
203+
*.dbmdl
204+
*.dbproj.schemaview
205+
*.jfm
206+
*.pfx
207+
*.publishsettings
208+
orleans.codegen.cs
209+
210+
# Since there are multiple workflows, uncomment next line to ignore bower_components
211+
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
212+
#bower_components/
213+
214+
# RIA/Silverlight projects
215+
Generated_Code/
216+
217+
# Backup & report files from converting an old project file
218+
# to a newer Visual Studio version. Backup files are not needed,
219+
# because we have git ;-)
220+
_UpgradeReport_Files/
221+
Backup*/
222+
UpgradeLog*.XML
223+
UpgradeLog*.htm
224+
225+
# SQL Server files
226+
#*.mdf
227+
#*.ldf
228+
#*.ndf
229+
230+
# Business Intelligence projects
231+
*.rdl.data
232+
*.bim.layout
233+
*.bim_*.settings
234+
235+
# Microsoft Fakes
236+
FakesAssemblies/
237+
238+
# GhostDoc plugin setting file
239+
*.GhostDoc.xml
240+
241+
# Node.js Tools for Visual Studio
242+
.ntvs_analysis.dat
243+
node_modules/
244+
245+
# Typescript v1 declaration files
246+
typings/
247+
248+
# Visual Studio 6 build log
249+
*.plg
250+
251+
# Visual Studio 6 workspace options file
252+
*.opt
253+
254+
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
255+
*.vbw
256+
257+
# Visual Studio LightSwitch build output
258+
**/*.HTMLClient/GeneratedArtifacts
259+
**/*.DesktopClient/GeneratedArtifacts
260+
**/*.DesktopClient/ModelManifest.xml
261+
**/*.Server/GeneratedArtifacts
262+
**/*.Server/ModelManifest.xml
263+
_Pvt_Extensions
264+
265+
# Paket dependency manager
266+
.paket/paket.exe
267+
paket-files/
268+
269+
# FAKE - F# Make
270+
.fake/
271+
272+
# JetBrains Rider
273+
.idea/
274+
*.sln.iml
275+
276+
# CodeRush
277+
.cr/
278+
279+
# Python Tools for Visual Studio (PTVS)
280+
__pycache__/
281+
*.pyc
282+
283+
# Cake - Uncomment if you are using it
284+
# tools/**
285+
# !tools/packages.config
286+
287+
# Tabs Studio
288+
*.tss
289+
290+
# Telerik's JustMock configuration file
291+
*.jmconfig
292+
293+
# BizTalk build output
294+
*.btp.cs
295+
*.btm.cs
296+
*.odx.cs
297+
*.xsd.cs

‎CS/AspDashboard_CustomExtension.sln

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
Microsoft Visual Studio Solution File, Format Version 12.00
2+
# Visual Studio 15
3+
VisualStudioVersion = 15.0.27004.2009
4+
MinimumVisualStudioVersion = 10.0.40219.1
5+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AspDashboard_CustomExtension", "AspDashboard_CustomExtension\AspDashboard_CustomExtension.csproj", "{28EA5E0E-2E2E-4106-A222-8A077959C17A}"
6+
EndProject
7+
Global
8+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
9+
Debug|Any CPU = Debug|Any CPU
10+
Release|Any CPU = Release|Any CPU
11+
EndGlobalSection
12+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
13+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
14+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Debug|Any CPU.Build.0 = Debug|Any CPU
15+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Release|Any CPU.ActiveCfg = Release|Any CPU
16+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Release|Any CPU.Build.0 = Release|Any CPU
17+
EndGlobalSection
18+
GlobalSection(SolutionProperties) = preSolution
19+
HideSolutionNode = FALSE
20+
EndGlobalSection
21+
GlobalSection(ExtensibilityGlobals) = postSolution
22+
SolutionGuid = {E1FA54A7-315F-40E5-8404-606780F81D22}
23+
EndGlobalSection
24+
EndGlobal
Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Dashboard>
3+
<Title Text="Sample Dashboard" />
4+
<DataSources>
5+
<SqlDataSource ComponentName="DataSource1">
6+
<Name>SalesPerson1_1</Name>
7+
<Connection Name="nwindConnection" FromAppConfig="true" />
8+
<Query Type="SelectQuery" Name="SalesPerson1_1">
9+
<Tables>
10+
<Table Name="SalesPerson" />
11+
</Tables>
12+
<Columns>
13+
<Column Table="SalesPerson" Name="Country" />
14+
<Column Table="SalesPerson" Name="ProductName" />
15+
<Column Table="SalesPerson" Name="CategoryName" />
16+
<Column Table="SalesPerson" Name="OrderDate" />
17+
<Column Table="SalesPerson" Name="UnitPrice" />
18+
<Column Table="SalesPerson" Name="Quantity" />
19+
<Column Table="SalesPerson" Name="Discount" />
20+
<Column Table="SalesPerson" Name="Extended Price" />
21+
<Column Table="SalesPerson" Name="Sales Person" />
22+
</Columns>
23+
</Query>
24+
<ConnectionOptions CloseConnection="true" CommandTimeout="0" />
25+
</SqlDataSource>
26+
</DataSources>
27+
<Items>
28+
<Chart ComponentName="chartDashboardItem1" Name="Price by Year" DataSource="DataSource1" DataMember="SalesPerson1_1">
29+
<DataItems>
30+
<Measure DataMember="Extended Price" DefaultId="DataItem0" />
31+
<Dimension DataMember="Sales Person" DefaultId="DataItem1" />
32+
<Dimension DataMember="OrderDate" DefaultId="DataItem2" />
33+
</DataItems>
34+
<SeriesDimensions>
35+
<SeriesDimension DefaultId="DataItem2" />
36+
</SeriesDimensions>
37+
<Arguments>
38+
<Argument DefaultId="DataItem1" />
39+
</Arguments>
40+
<Panes>
41+
<Pane Name="Pane 1">
42+
<Series>
43+
<Simple>
44+
<Value DefaultId="DataItem0" />
45+
</Simple>
46+
</Series>
47+
</Pane>
48+
</Panes>
49+
</Chart>
50+
<ListBox ComponentName="listBoxDashboardItem1" Name="Category" DataSource="DataSource1" DataMember="SalesPerson1_1" ShowAllValue="false" ListBoxType="Radio">
51+
<DataItems>
52+
<Dimension DataMember="CategoryName" DefaultId="DataItem0" />
53+
</DataItems>
54+
<FilterDimensions>
55+
<Dimension DefaultId="DataItem0" />
56+
</FilterDimensions>
57+
</ListBox>
58+
<Pie ComponentName="pieDashboardItem1" Name="Quantity by Year" DataSource="DataSource1" DataMember="SalesPerson1_1">
59+
<DataItems>
60+
<Dimension DataMember="Country" DefaultId="DataItem1" />
61+
<Dimension DataMember="OrderDate" DefaultId="DataItem2" />
62+
<Dimension DataMember="OrderDate" DefaultId="DataItem3" />
63+
<Dimension DataMember="Country" DefaultId="DataItem4" />
64+
<Measure DataMember="Quantity" DefaultId="DataItem0" />
65+
</DataItems>
66+
<SeriesDimensions>
67+
<SeriesDimension DefaultId="DataItem4" />
68+
</SeriesDimensions>
69+
<Arguments>
70+
<Argument DefaultId="DataItem3" />
71+
</Arguments>
72+
<Values>
73+
<Value DefaultId="DataItem0" />
74+
</Values>
75+
</Pie>
76+
</Items>
77+
<LayoutTree>
78+
<LayoutGroup Weight="100">
79+
<LayoutGroup Orientation="Vertical" Weight="100">
80+
<LayoutGroup Weight="100">
81+
<LayoutItem DashboardItem="listBoxDashboardItem1" Weight="65.422347436735976" />
82+
<LayoutItem DashboardItem="pieDashboardItem1" Weight="157.11123408965133" />
83+
</LayoutGroup>
84+
<LayoutGroup Weight="100">
85+
<LayoutItem DashboardItem="chartDashboardItem1" Weight="100" />
86+
</LayoutGroup>
87+
</LayoutGroup>
88+
</LayoutGroup>
89+
</LayoutTree>
90+
</Dashboard>
Binary file not shown.
Lines changed: 208 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,208 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="4.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
4+
<PropertyGroup>
5+
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
6+
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
7+
<ProductVersion></ProductVersion>
8+
<SchemaVersion>2.0</SchemaVersion>
9+
<ProjectGuid>{28EA5E0E-2E2E-4106-A222-8A077959C17A}</ProjectGuid>
10+
<ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
11+
<OutputType>Library</OutputType>
12+
<AppDesignerFolder>Properties</AppDesignerFolder>
13+
<RootNamespace>WebApplication18</RootNamespace>
14+
<AssemblyName>WebApplication18</AssemblyName>
15+
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
16+
<UseIISExpress>true</UseIISExpress>
17+
<IISExpressSSLPort />
18+
<IISExpressAnonymousAuthentication />
19+
<IISExpressWindowsAuthentication />
20+
<IISExpressUseClassicPipelineMode />
21+
</PropertyGroup>
22+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
23+
<DebugSymbols>true</DebugSymbols>
24+
<DebugType>full</DebugType>
25+
<Optimize>false</Optimize>
26+
<OutputPath>bin\</OutputPath>
27+
<DefineConstants>DEBUG;TRACE</DefineConstants>
28+
<ErrorReport>prompt</ErrorReport>
29+
<WarningLevel>4</WarningLevel>
30+
</PropertyGroup>
31+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
32+
<DebugType>pdbonly</DebugType>
33+
<Optimize>true</Optimize>
34+
<OutputPath>bin\</OutputPath>
35+
<DefineConstants>TRACE</DefineConstants>
36+
<ErrorReport>prompt</ErrorReport>
37+
<WarningLevel>4</WarningLevel>
38+
</PropertyGroup>
39+
<ItemGroup>
40+
<Reference Include="DevExpress.Charts.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
41+
<Private>True</Private>
42+
</Reference>
43+
<Reference Include="DevExpress.Pdf.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
44+
<Private>True</Private>
45+
</Reference>
46+
<Reference Include="DevExpress.TreeMap.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
47+
<Private>True</Private>
48+
</Reference>
49+
<Reference Include="DevExpress.XtraTreeMap.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
50+
<Private>True</Private>
51+
</Reference>
52+
<Reference Include="DevExpress.Dashboard.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
53+
<Private>True</Private>
54+
</Reference>
55+
<Reference Include="DevExpress.Dashboard.v17.1.Web, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
56+
<Private>True</Private>
57+
</Reference>
58+
<Reference Include="DevExpress.Data.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
59+
<Private>True</Private>
60+
</Reference>
61+
<Reference Include="DevExpress.DataAccess.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
62+
<Private>True</Private>
63+
</Reference>
64+
<Reference Include="DevExpress.Map.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
65+
<Private>True</Private>
66+
</Reference>
67+
<Reference Include="DevExpress.Office.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
68+
<Private>True</Private>
69+
</Reference>
70+
<Reference Include="DevExpress.PivotGrid.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
71+
<Private>True</Private>
72+
</Reference>
73+
<Reference Include="DevExpress.RichEdit.v17.1.Export, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
74+
<Private>True</Private>
75+
</Reference>
76+
<Reference Include="DevExpress.Printing.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
77+
<Private>True</Private>
78+
</Reference>
79+
<Reference Include="DevExpress.RichEdit.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
80+
<Private>True</Private>
81+
</Reference>
82+
<Reference Include="DevExpress.Sparkline.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
83+
<Private>True</Private>
84+
</Reference>
85+
<Reference Include="DevExpress.Utils.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
86+
<Private>True</Private>
87+
</Reference>
88+
<Reference Include="DevExpress.Web.ASPxThemes.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
89+
<Private>True</Private>
90+
</Reference>
91+
<Reference Include="DevExpress.Web.Resources.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
92+
<Private>True</Private>
93+
</Reference>
94+
<Reference Include="DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
95+
<Private>True</Private>
96+
</Reference>
97+
<Reference Include="DevExpress.Xpo.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
98+
<Private>True</Private>
99+
</Reference>
100+
<Reference Include="DevExpress.XtraCharts.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
101+
<Private>True</Private>
102+
</Reference>
103+
<Reference Include="DevExpress.XtraGauges.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
104+
<Private>True</Private>
105+
</Reference>
106+
<Reference Include="DevExpress.XtraGauges.v17.1.Presets, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
107+
<Private>True</Private>
108+
</Reference>
109+
<Reference Include="DevExpress.XtraPrinting.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
110+
<Private>True</Private>
111+
</Reference>
112+
<Reference Include="DevExpress.XtraGauges.v17.1.Win, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
113+
<Private>True</Private>
114+
</Reference>
115+
<Reference Include="DevExpress.XtraMap.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
116+
<Private>True</Private>
117+
</Reference>
118+
<Reference Include="DevExpress.CodeParser.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
119+
<Private>True</Private>
120+
</Reference>
121+
<Reference Include="DevExpress.XtraReports.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
122+
<Private>True</Private>
123+
</Reference>
124+
<Reference Include="Microsoft.CSharp" />
125+
<Reference Include="System.Web.DynamicData" />
126+
<Reference Include="System.Web.Entity" />
127+
<Reference Include="System.Web.ApplicationServices" />
128+
<Reference Include="System.ComponentModel.DataAnnotations" />
129+
<Reference Include="System" />
130+
<Reference Include="System.Data" />
131+
<Reference Include="System.Core" />
132+
<Reference Include="System.Data.DataSetExtensions" />
133+
<Reference Include="System.Web.Extensions" />
134+
<Reference Include="System.Xml.Linq" />
135+
<Reference Include="System.Drawing" />
136+
<Reference Include="System.Web" />
137+
<Reference Include="System.Xml" />
138+
<Reference Include="System.Configuration" />
139+
<Reference Include="System.Web.Services" />
140+
<Reference Include="System.EnterpriseServices" />
141+
</ItemGroup>
142+
<ItemGroup>
143+
<Content Include="App_Data\Dashboards\dashboard1.xml" />
144+
<Content Include="App_Data\nwind.mdb" />
145+
<Content Include="Default.aspx" />
146+
<Content Include="Global.asax" />
147+
<None Include="Scripts\DeleteExtension.js" />
148+
<Content Include="Scripts\SaveAsExtension.js" />
149+
<Content Include="Web.config">
150+
<SubType>Designer</SubType>
151+
</Content>
152+
</ItemGroup>
153+
<ItemGroup>
154+
<Compile Include="Default.aspx.cs">
155+
<DependentUpon>Default.aspx</DependentUpon>
156+
<SubType>ASPXCodeBehind</SubType>
157+
</Compile>
158+
<Compile Include="Default.aspx.designer.cs">
159+
<DependentUpon>Default.aspx</DependentUpon>
160+
</Compile>
161+
<Compile Include="Global.asax.cs">
162+
<DependentUpon>Global.asax</DependentUpon>
163+
</Compile>
164+
<Compile Include="CustomDashbboardStorage.cs" />
165+
<Compile Include="Properties\AssemblyInfo.cs" />
166+
</ItemGroup>
167+
<ItemGroup>
168+
<None Include="Web.Debug.config">
169+
<DependentUpon>Web.config</DependentUpon>
170+
</None>
171+
<None Include="Web.Release.config">
172+
<DependentUpon>Web.config</DependentUpon>
173+
</None>
174+
</ItemGroup>
175+
<ItemGroup />
176+
<ItemGroup />
177+
<PropertyGroup>
178+
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
179+
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
180+
</PropertyGroup>
181+
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
182+
<Import Project="$(VSToolsPath)\WebApplications\Microsoft.WebApplication.targets" Condition="'$(VSToolsPath)' != ''" />
183+
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v12.0\WebApplications\Microsoft.WebApplication.targets" Condition="false" />
184+
<ProjectExtensions>
185+
<VisualStudio>
186+
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
187+
<WebProjectProperties>
188+
<UseIIS>True</UseIIS>
189+
<AutoAssignPort>True</AutoAssignPort>
190+
<DevelopmentServerPort>62843</DevelopmentServerPort>
191+
<DevelopmentServerVPath>/</DevelopmentServerVPath>
192+
<IISUrl>http://localhost:62845/</IISUrl>
193+
<NTLMAuthentication>False</NTLMAuthentication>
194+
<UseCustomServer>False</UseCustomServer>
195+
<CustomServerUrl></CustomServerUrl>
196+
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
197+
</WebProjectProperties>
198+
</FlavorProperties>
199+
</VisualStudio>
200+
</ProjectExtensions>
201+
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
202+
Other similar extension points exist, see Microsoft.Common.targets.
203+
<Target Name="BeforeBuild">
204+
</Target>
205+
<Target Name="AfterBuild">
206+
</Target>
207+
-->
208+
</Project>
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
using DevExpress.DashboardWeb;
2+
using System.IO;
3+
4+
namespace Storages {
5+
6+
public class CustomDashboardFileStorage : DashboardFileStorage {
7+
public CustomDashboardFileStorage(string workingDirectory)
8+
: base(workingDirectory) {
9+
}
10+
11+
public void DeleteDashboard(string dashboardID) {
12+
var dashboardPath = base.ResolveFileName(dashboardID);
13+
if (File.Exists(dashboardPath))
14+
File.Delete(dashboardPath);
15+
}
16+
}
17+
}
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="AspDashboard_CustomExtension.Default" %>
2+
3+
<%@ Register Assembly="DevExpress.Dashboard.v17.1.Web, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
4+
Namespace="DevExpress.DashboardWeb" TagPrefix="dx" %>
5+
6+
<!DOCTYPE html>
7+
8+
<html xmlns="http://www.w3.org/1999/xhtml">
9+
<head runat="server">
10+
<title></title>
11+
</head>
12+
<body>
13+
14+
<script type="text/javascript" src="Scripts/SaveAsExtension.js"></script>
15+
<script type="text/javascript" src="Scripts/DeleteExtension.js"></script>
16+
17+
<!-- Defines the "Save As" extension template. -->
18+
<script type="text/html" id="dx-save-as-form">
19+
<div>Dashboard Name:</div>
20+
<div style="margin: 10px 0" data-bind="dxTextBox: { value: newName }"></div>
21+
<div data-bind="dxButton: { text: 'Save', onClick: saveAs }"></div>
22+
</script>
23+
24+
<script type="text/javascript">
25+
function onBeforeRender(sender) {
26+
var control = sender.GetDashboardControl();
27+
control.registerExtension(new SaveAsDashboardExtension(control));
28+
control.registerExtension(new DeleteDashboardExtension(sender));
29+
}
30+
</script>
31+
32+
<form id="form1" runat="server">
33+
<div style="position: absolute; top: 0; bottom: 0; left: 0; right: 0;">
34+
<dx:ASPxDashboard ID="ASPxDashboard1" ClientInstanceName="dashboard" runat="server"
35+
UseDashboardConfigurator="true"
36+
OnCustomDataCallback="ASPxDashboard1_CustomDataCallback"
37+
WorkingMode="Designer"
38+
Width="100%" Height="100%">
39+
<ClientSideEvents BeforeRender="onBeforeRender" />
40+
</dx:ASPxDashboard>
41+
</div>
42+
</form>
43+
</body>
44+
</html>
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
using Storages;
2+
using System;
3+
using System.Collections.Generic;
4+
using System.Web.Script.Serialization;
5+
6+
namespace AspDashboard_CustomExtension {
7+
public partial class Default : System.Web.UI.Page {
8+
protected void Page_Load(object sender, EventArgs e) {
9+
10+
}
11+
12+
protected void ASPxDashboard1_CustomDataCallback(object sender, DevExpress.Web.CustomDataCallbackEventArgs e) {
13+
Dictionary<string, string> parameters = new JavaScriptSerializer().Deserialize<Dictionary<string, string>>(e.Parameter);
14+
if (!parameters.ContainsKey("ExtensionName"))
15+
return;
16+
17+
CustomDashboardFileStorage newDashboardStorage = new CustomDashboardFileStorage(@"~/App_Data/Dashboards");
18+
if (parameters["ExtensionName"] == "dxdde-delete-dashboard" && parameters.ContainsKey("DashboardID"))
19+
newDashboardStorage.DeleteDashboard(parameters["DashboardID"]);
20+
}
21+
}
22+
}

‎CS/AspDashboard_CustomExtension/Default.aspx.designer.cs

Lines changed: 33 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<%@ Application Codebehind="Global.asax.cs" Inherits="AspDashboard_CustomExtension.Global" Language="C#" %>
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
using DevExpress.DashboardWeb;
2+
using Storages;
3+
using System;
4+
5+
namespace AspDashboard_CustomExtension {
6+
public class Global : System.Web.HttpApplication {
7+
8+
protected void Application_Start(object sender, EventArgs e) {
9+
CustomDashboardFileStorage newDashboardStorage = new CustomDashboardFileStorage(@"~/App_Data/Dashboards");
10+
DashboardConfigurator.Default.SetDashboardStorage(newDashboardStorage);
11+
}
12+
}
13+
}
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
using System.Reflection;
2+
using System.Runtime.CompilerServices;
3+
using System.Runtime.InteropServices;
4+
5+
// General Information about an assembly is controlled through the following
6+
// set of attributes. Change these attribute values to modify the information
7+
// associated with an assembly.
8+
[assembly: AssemblyTitle("WebApplication18")]
9+
[assembly: AssemblyDescription("")]
10+
[assembly: AssemblyConfiguration("")]
11+
[assembly: AssemblyCompany("")]
12+
[assembly: AssemblyProduct("WebApplication18")]
13+
[assembly: AssemblyCopyright("Copyright © 2016")]
14+
[assembly: AssemblyTrademark("")]
15+
[assembly: AssemblyCulture("")]
16+
17+
// Setting ComVisible to false makes the types in this assembly not visible
18+
// to COM components. If you need to access a type in this assembly from
19+
// COM, set the ComVisible attribute to true on that type.
20+
[assembly: ComVisible(false)]
21+
22+
// The following GUID is for the ID of the typelib if this project is exposed to COM
23+
[assembly: Guid("bc0f83c5-6bdb-46ed-a9ae-2c141eafeb3d")]
24+
25+
// Version information for an assembly consists of the following four values:
26+
//
27+
// Major Version
28+
// Minor Version
29+
// Build Number
30+
// Revision
31+
//
32+
// You can specify all the values or you can default the Revision and Build Numbers
33+
// by using the '*' as shown below:
34+
[assembly: AssemblyVersion("1.0.0.0")]
35+
[assembly: AssemblyFileVersion("1.0.0.0")]
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
// Creates and implements a custom DeleteDashboardExtension class.
2+
3+
function DeleteDashboardExtension(_wrapper) {
4+
var _this = this;
5+
this._wrapper = _wrapper;
6+
this._control = _wrapper.GetDashboardControl();
7+
this._toolbox = this._control.findExtension('toolbox');
8+
this.name = "dxdde-delete-dashboard";
9+
this.deleteDashboard = function () {
10+
if (_this.isExtensionAvailable()) {
11+
if (confirm("Delete this Dashboard?")) {
12+
var dashboardid = _this._control.dashboardContainer().id;
13+
var param = JSON.stringify({ DashboardID: dashboardid, ExtensionName: _this.name });
14+
_this._toolbox.menuVisible(false);
15+
_this._wrapper.PerformDataCallback(param, function () {
16+
_this._control.close();
17+
});
18+
}
19+
}
20+
}
21+
this._menuItem = {
22+
id: this.name,
23+
title: "Delete",
24+
click: this.deleteDashboard,
25+
selected: ko.observable(false),
26+
disabled: ko.computed(function () { return !_this._control.dashboard(); }),
27+
index: 113,
28+
hasSeparator: true,
29+
data: _this
30+
};
31+
}
32+
33+
DeleteDashboardExtension.prototype.isExtensionAvailable = function () {
34+
return this._toolbox !== undefined;
35+
}
36+
37+
DeleteDashboardExtension.prototype.start = function () {
38+
if (this.isExtensionAvailable())
39+
this._toolbox.menuItems.push(this._menuItem);
40+
};
41+
DeleteDashboardExtension.prototype.stop = function () {
42+
if (this.isExtensionAvailable())
43+
this._toolbox.menuItems.remove(this._menuItem);
44+
};
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
// Creates and implements a custom SaveAsDashboardExtension class.
2+
3+
function SaveAsDashboardExtension(dashboardControl) {
4+
var _this = this;
5+
this._control = dashboardControl;
6+
this._toolbox = this._control.findExtension("toolbox");
7+
this._newDashboardExtension = this._control.findExtension("create-dashboard");
8+
this._menuItem = {
9+
id: "dashboard-save-as",
10+
title: "Save As...",
11+
template: "dx-save-as-form",
12+
selected: ko.observable(true),
13+
disabled: ko.computed(function () { return !dashboardControl.dashboard(); }),
14+
index: 112,
15+
data: _this
16+
};
17+
this.saveAs = function () {
18+
if (this.isExtensionAvailable()) {
19+
this._toolbox.menuVisible(false);
20+
this._newDashboardExtension.performCreateDashboard(this.newName(), this._control.dashboard().getJSON());
21+
}
22+
};
23+
this.newName = ko.observable("New Dashboard Name");
24+
}
25+
26+
SaveAsDashboardExtension.prototype.isExtensionAvailable = function () {
27+
return this._toolbox !== undefined && this._newDashboardExtension !== undefined;
28+
}
29+
30+
SaveAsDashboardExtension.prototype.start = function () {
31+
if (this.isExtensionAvailable())
32+
this._toolbox.menuItems.push(this._menuItem);
33+
};
34+
SaveAsDashboardExtension.prototype.stop = function () {
35+
if (this.isExtensionAvailable())
36+
this._toolbox.menuItems.remove(this._menuItem);
37+
}
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
3+
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
4+
5+
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
6+
<!--
7+
In the example below, the "SetAttributes" transform will change the value of
8+
"connectionString" to use "ReleaseSQLServer" only when the "Match" locator
9+
finds an attribute "name" that has a value of "MyDB".
10+
11+
<connectionStrings>
12+
<add name="MyDB"
13+
connectionString="Data Source=ReleaseSQLServer;Initial Catalog=MyReleaseDB;Integrated Security=True"
14+
xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
15+
</connectionStrings>
16+
-->
17+
<system.web>
18+
<!--
19+
In the example below, the "Replace" transform will replace the entire
20+
<customErrors> section of your web.config file.
21+
Note that because there is only one customErrors section under the
22+
<system.web> node, there is no need to use the "xdt:Locator" attribute.
23+
24+
<customErrors defaultRedirect="GenericError.htm"
25+
mode="RemoteOnly" xdt:Transform="Replace">
26+
<error statusCode="500" redirect="InternalError.htm"/>
27+
</customErrors>
28+
-->
29+
</system.web>
30+
</configuration>
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
3+
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
4+
5+
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
6+
<!--
7+
In the example below, the "SetAttributes" transform will change the value of
8+
"connectionString" to use "ReleaseSQLServer" only when the "Match" locator
9+
finds an attribute "name" that has a value of "MyDB".
10+
11+
<connectionStrings>
12+
<add name="MyDB"
13+
connectionString="Data Source=ReleaseSQLServer;Initial Catalog=MyReleaseDB;Integrated Security=True"
14+
xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
15+
</connectionStrings>
16+
-->
17+
<system.web>
18+
<compilation xdt:Transform="RemoveAttributes(debug)" />
19+
<!--
20+
In the example below, the "Replace" transform will replace the entire
21+
<customErrors> section of your web.config file.
22+
Note that because there is only one customErrors section under the
23+
<system.web> node, there is no need to use the "xdt:Locator" attribute.
24+
25+
<customErrors defaultRedirect="GenericError.htm"
26+
mode="RemoteOnly" xdt:Transform="Replace">
27+
<error statusCode="500" redirect="InternalError.htm"/>
28+
</customErrors>
29+
-->
30+
</system.web>
31+
</configuration>
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
<?xml version="1.0"?>
2+
<!--
3+
For more information on how to configure your ASP.NET application, please visit
4+
http://go.microsoft.com/fwlink/?LinkId=169433
5+
-->
6+
<configuration>
7+
<configSections>
8+
<sectionGroup name="devExpress">
9+
<section name="themes" type="DevExpress.Web.ThemesConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
10+
<section name="compression" type="DevExpress.Web.CompressionConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
11+
<section name="settings" type="DevExpress.Web.SettingsConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
12+
<section name="errors" type="DevExpress.Web.ErrorsConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
13+
<section name="resources" type="DevExpress.Web.ResourcesConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
14+
</sectionGroup>
15+
</configSections>
16+
<connectionStrings>
17+
<add name="nwindConnection" connectionString=" XpoProvider=MSAccess; Provider=Microsoft.Jet.OLEDB.4.0; Data Source=|DataDirectory|\nwind.mdb;" />
18+
</connectionStrings>
19+
<system.web>
20+
<compilation debug="true" targetFramework="4.0">
21+
<assemblies>
22+
<add assembly="DevExpress.Dashboard.v17.1.Web, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
23+
<add assembly="DevExpress.Dashboard.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
24+
<add assembly="DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
25+
<add assembly="DevExpress.DataAccess.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
26+
<add assembly="DevExpress.Data.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
27+
<add assembly="DevExpress.Office.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
28+
<add assembly="DevExpress.Printing.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
29+
<add assembly="DevExpress.Web.Resources.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
30+
<add assembly="DevExpress.Charts.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
31+
<add assembly="DevExpress.Xpo.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
32+
<add assembly="DevExpress.RichEdit.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
33+
<add assembly="DevExpress.Web.ASPxThemes.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
34+
</assemblies>
35+
</compilation>
36+
<httpModules>
37+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" name="ASPxHttpHandlerModule" />
38+
</httpModules>
39+
<httpHandlers>
40+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" verb="GET,POST" path="DX.ashx" validate="false" />
41+
<add verb="GET,POST" path="ASPxUploadProgressHandlerPage.ashx" type="DevExpress.Web.ASPxUploadProgressHttpHandler, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" validate="false" />
42+
<add validate="false" verb="GET,POST" path="DXDD.axd" type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
43+
</httpHandlers>
44+
</system.web>
45+
<system.webServer>
46+
<modules>
47+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" name="ASPxHttpHandlerModule" />
48+
</modules>
49+
<validation validateIntegratedModeConfiguration="false" />
50+
<handlers>
51+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" verb="GET,POST" path="DX.ashx" name="ASPxHttpHandlerModule" preCondition="integratedMode" />
52+
<add name="ASPxUploadProgressHandler" preCondition="integratedMode" verb="GET,POST" path="ASPxUploadProgressHandlerPage.ashx" type="DevExpress.Web.ASPxUploadProgressHttpHandler, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
53+
<add name="WebDashboardHandler" preCondition="integratedMode" verb="GET,POST" path="DXDD.axd" type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
54+
</handlers>
55+
</system.webServer>
56+
<devExpress>
57+
<themes enableThemesAssembly="true" styleSheetTheme="" theme="" customThemeAssemblies="" baseColor="" font="" />
58+
<compression enableHtmlCompression="false" enableCallbackCompression="true" enableResourceCompression="true" enableResourceMerging="true" />
59+
<settings accessibilityCompliant="false" doctypeMode="Html5" rightToLeft="false" embedRequiredClientLibraries="true" ieCompatibilityVersion="edge" checkReferencesToExternalScripts="false" protectControlState="true" />
60+
<errors callbackErrorRedirectUrl="" />
61+
</devExpress>
62+
</configuration>

‎LICENSE

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
This code example is provided "as is" without warranty of any kind. Developer Express Inc ("DevExpress") disclaims all warranties,
2+
either express or implied, including the warranties of merchantability and fitness for a particular purpose.
3+
4+
For licensing terms and conditions of DevExpress product(s) required for, or associated with the use of this code example,
5+
please refer to the applicable End-User License Agreement at https://www.devexpress.com/Support/licensingfaq.xml

‎Readme.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Web Dashboard - How to implement Save As and Delete by creating custom extensions
2+
3+
4+
This example demonstrates how to add the "Save As" and "Delete" menu items to the Web Dashboard control.<br>This functionality is implemented by creating custom extensions with the approach from <a href="https://www.devexpress.com/Support/Center/p/T466716">T466716: Web Dashboard - How to work with extensions</a>.<br>To learn more about extensions, see <a href="https://documentation.devexpress.com/#Dashboard/CustomDocument117543">Working with Extensions</a>.<br><br><strong>See also:</strong><br><a href="https://www.devexpress.com/Support/Center/p/T504201">T504201: MVC Dashboard - How to implement the Save As and Delete functionality by creating custom extensions</a><br><a href="https://www.devexpress.com/Support/Center/p/T601084">T601084: ASP.NET Core Dashboard - How to implement the Save As and Delete functionality by creating custom extensions</a>
5+
6+
<br/>
7+
8+

‎VB/AspDashboard_CustomExtension.sln

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
Microsoft Visual Studio Solution File, Format Version 12.00
2+
# Visual Studio 15
3+
VisualStudioVersion = 15.0.27004.2009
4+
MinimumVisualStudioVersion = 10.0.40219.1
5+
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "AspDashboard_CustomExtension", "AspDashboard_CustomExtension\AspDashboard_CustomExtension.vbproj", "{28EA5E0E-2E2E-4106-A222-8A077959C17A}"
6+
EndProject
7+
Global
8+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
9+
Debug|Any CPU = Debug|Any CPU
10+
Release|Any CPU = Release|Any CPU
11+
EndGlobalSection
12+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
13+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
14+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Debug|Any CPU.Build.0 = Debug|Any CPU
15+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Release|Any CPU.ActiveCfg = Release|Any CPU
16+
{28EA5E0E-2E2E-4106-A222-8A077959C17A}.Release|Any CPU.Build.0 = Release|Any CPU
17+
EndGlobalSection
18+
GlobalSection(SolutionProperties) = preSolution
19+
HideSolutionNode = FALSE
20+
EndGlobalSection
21+
GlobalSection(ExtensibilityGlobals) = postSolution
22+
SolutionGuid = {E1FA54A7-315F-40E5-8404-606780F81D22}
23+
EndGlobalSection
24+
EndGlobal
Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Dashboard>
3+
<Title Text="Sample Dashboard" />
4+
<DataSources>
5+
<SqlDataSource ComponentName="DataSource1">
6+
<Name>SalesPerson1_1</Name>
7+
<Connection Name="nwindConnection" FromAppConfig="true" />
8+
<Query Type="SelectQuery" Name="SalesPerson1_1">
9+
<Tables>
10+
<Table Name="SalesPerson" />
11+
</Tables>
12+
<Columns>
13+
<Column Table="SalesPerson" Name="Country" />
14+
<Column Table="SalesPerson" Name="ProductName" />
15+
<Column Table="SalesPerson" Name="CategoryName" />
16+
<Column Table="SalesPerson" Name="OrderDate" />
17+
<Column Table="SalesPerson" Name="UnitPrice" />
18+
<Column Table="SalesPerson" Name="Quantity" />
19+
<Column Table="SalesPerson" Name="Discount" />
20+
<Column Table="SalesPerson" Name="Extended Price" />
21+
<Column Table="SalesPerson" Name="Sales Person" />
22+
</Columns>
23+
</Query>
24+
<ConnectionOptions CloseConnection="true" CommandTimeout="0" />
25+
</SqlDataSource>
26+
</DataSources>
27+
<Items>
28+
<Chart ComponentName="chartDashboardItem1" Name="Price by Year" DataSource="DataSource1" DataMember="SalesPerson1_1">
29+
<DataItems>
30+
<Measure DataMember="Extended Price" DefaultId="DataItem0" />
31+
<Dimension DataMember="Sales Person" DefaultId="DataItem1" />
32+
<Dimension DataMember="OrderDate" DefaultId="DataItem2" />
33+
</DataItems>
34+
<SeriesDimensions>
35+
<SeriesDimension DefaultId="DataItem2" />
36+
</SeriesDimensions>
37+
<Arguments>
38+
<Argument DefaultId="DataItem1" />
39+
</Arguments>
40+
<Panes>
41+
<Pane Name="Pane 1">
42+
<Series>
43+
<Simple>
44+
<Value DefaultId="DataItem0" />
45+
</Simple>
46+
</Series>
47+
</Pane>
48+
</Panes>
49+
</Chart>
50+
<ListBox ComponentName="listBoxDashboardItem1" Name="Category" DataSource="DataSource1" DataMember="SalesPerson1_1" ShowAllValue="false" ListBoxType="Radio">
51+
<DataItems>
52+
<Dimension DataMember="CategoryName" DefaultId="DataItem0" />
53+
</DataItems>
54+
<FilterDimensions>
55+
<Dimension DefaultId="DataItem0" />
56+
</FilterDimensions>
57+
</ListBox>
58+
<Pie ComponentName="pieDashboardItem1" Name="Quantity by Year" DataSource="DataSource1" DataMember="SalesPerson1_1">
59+
<DataItems>
60+
<Dimension DataMember="Country" DefaultId="DataItem1" />
61+
<Dimension DataMember="OrderDate" DefaultId="DataItem2" />
62+
<Dimension DataMember="OrderDate" DefaultId="DataItem3" />
63+
<Dimension DataMember="Country" DefaultId="DataItem4" />
64+
<Measure DataMember="Quantity" DefaultId="DataItem0" />
65+
</DataItems>
66+
<SeriesDimensions>
67+
<SeriesDimension DefaultId="DataItem4" />
68+
</SeriesDimensions>
69+
<Arguments>
70+
<Argument DefaultId="DataItem3" />
71+
</Arguments>
72+
<Values>
73+
<Value DefaultId="DataItem0" />
74+
</Values>
75+
</Pie>
76+
</Items>
77+
<LayoutTree>
78+
<LayoutGroup Weight="100">
79+
<LayoutGroup Orientation="Vertical" Weight="100">
80+
<LayoutGroup Weight="100">
81+
<LayoutItem DashboardItem="listBoxDashboardItem1" Weight="65.422347436735976" />
82+
<LayoutItem DashboardItem="pieDashboardItem1" Weight="157.11123408965133" />
83+
</LayoutGroup>
84+
<LayoutGroup Weight="100">
85+
<LayoutItem DashboardItem="chartDashboardItem1" Weight="100" />
86+
</LayoutGroup>
87+
</LayoutGroup>
88+
</LayoutGroup>
89+
</LayoutTree>
90+
</Dashboard>
Binary file not shown.
Lines changed: 223 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,223 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="4.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
4+
<PropertyGroup>
5+
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
6+
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
7+
<ProductVersion></ProductVersion>
8+
<SchemaVersion>2.0</SchemaVersion>
9+
<ProjectGuid>{28EA5E0E-2E2E-4106-A222-8A077959C17A}</ProjectGuid>
10+
<ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{F184B08F-C81C-45F6-A57F-5ABD9991F28F}</ProjectTypeGuids>
11+
<OutputType>Library</OutputType>
12+
<RootNamespace></RootNamespace>
13+
<AssemblyName>WebApplication18</AssemblyName>
14+
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
15+
<UseIISExpress>true</UseIISExpress>
16+
<IISExpressSSLPort />
17+
<IISExpressAnonymousAuthentication />
18+
<IISExpressWindowsAuthentication />
19+
<IISExpressUseClassicPipelineMode />
20+
<OptionExplicit>On</OptionExplicit>
21+
<OptionCompare>Binary</OptionCompare>
22+
<OptionStrict>Off</OptionStrict>
23+
<OptionInfer>On</OptionInfer>
24+
</PropertyGroup>
25+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
26+
<DebugSymbols>true</DebugSymbols>
27+
<DebugType>full</DebugType>
28+
<Optimize>false</Optimize>
29+
<OutputPath>bin\</OutputPath>
30+
<DefineDebug>true</DefineDebug>
31+
<DefineTrace>true</DefineTrace>
32+
<ErrorReport>prompt</ErrorReport>
33+
</PropertyGroup>
34+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
35+
<DebugType>pdbonly</DebugType>
36+
<Optimize>true</Optimize>
37+
<OutputPath>bin\</OutputPath>
38+
<DefineDebug>false</DefineDebug>
39+
<DefineTrace>true</DefineTrace>
40+
<ErrorReport>prompt</ErrorReport>
41+
</PropertyGroup>
42+
<ItemGroup>
43+
<Import Include="Microsoft.VisualBasic" />
44+
<Import Include="System.Collections.Generic" />
45+
<Import Include="System.Collections" />
46+
<Import Include="System.Diagnostics" />
47+
<Import Include="System.Linq" />
48+
<Import Include="System.Xml.Linq" />
49+
<Import Include="System.Data" />
50+
<Import Include="System.Drawing" />
51+
<Import Include="System.Web" />
52+
<Import Include="System" />
53+
</ItemGroup>
54+
<ItemGroup>
55+
<Reference Include="DevExpress.Charts.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
56+
<Private>True</Private>
57+
</Reference>
58+
<Reference Include="DevExpress.Pdf.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
59+
<Private>True</Private>
60+
</Reference>
61+
<Reference Include="DevExpress.TreeMap.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
62+
<Private>True</Private>
63+
</Reference>
64+
<Reference Include="DevExpress.XtraTreeMap.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
65+
<Private>True</Private>
66+
</Reference>
67+
<Reference Include="DevExpress.Dashboard.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
68+
<Private>True</Private>
69+
</Reference>
70+
<Reference Include="DevExpress.Dashboard.v17.1.Web, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
71+
<Private>True</Private>
72+
</Reference>
73+
<Reference Include="DevExpress.Data.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
74+
<Private>True</Private>
75+
</Reference>
76+
<Reference Include="DevExpress.DataAccess.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
77+
<Private>True</Private>
78+
</Reference>
79+
<Reference Include="DevExpress.Map.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
80+
<Private>True</Private>
81+
</Reference>
82+
<Reference Include="DevExpress.Office.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
83+
<Private>True</Private>
84+
</Reference>
85+
<Reference Include="DevExpress.PivotGrid.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
86+
<Private>True</Private>
87+
</Reference>
88+
<Reference Include="DevExpress.RichEdit.v17.1.Export, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
89+
<Private>True</Private>
90+
</Reference>
91+
<Reference Include="DevExpress.Printing.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
92+
<Private>True</Private>
93+
</Reference>
94+
<Reference Include="DevExpress.RichEdit.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
95+
<Private>True</Private>
96+
</Reference>
97+
<Reference Include="DevExpress.Sparkline.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
98+
<Private>True</Private>
99+
</Reference>
100+
<Reference Include="DevExpress.Utils.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
101+
<Private>True</Private>
102+
</Reference>
103+
<Reference Include="DevExpress.Web.ASPxThemes.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
104+
<Private>True</Private>
105+
</Reference>
106+
<Reference Include="DevExpress.Web.Resources.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
107+
<Private>True</Private>
108+
</Reference>
109+
<Reference Include="DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
110+
<Private>True</Private>
111+
</Reference>
112+
<Reference Include="DevExpress.Xpo.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
113+
<Private>True</Private>
114+
</Reference>
115+
<Reference Include="DevExpress.XtraCharts.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
116+
<Private>True</Private>
117+
</Reference>
118+
<Reference Include="DevExpress.XtraGauges.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
119+
<Private>True</Private>
120+
</Reference>
121+
<Reference Include="DevExpress.XtraGauges.v17.1.Presets, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
122+
<Private>True</Private>
123+
</Reference>
124+
<Reference Include="DevExpress.XtraPrinting.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
125+
<Private>True</Private>
126+
</Reference>
127+
<Reference Include="DevExpress.XtraGauges.v17.1.Win, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
128+
<Private>True</Private>
129+
</Reference>
130+
<Reference Include="DevExpress.XtraMap.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
131+
<Private>True</Private>
132+
</Reference>
133+
<Reference Include="DevExpress.CodeParser.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
134+
<Private>True</Private>
135+
</Reference>
136+
<Reference Include="DevExpress.XtraReports.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL">
137+
<Private>True</Private>
138+
</Reference>
139+
<Reference Include="Microsoft.CSharp" />
140+
<Reference Include="System.Web.DynamicData" />
141+
<Reference Include="System.Web.Entity" />
142+
<Reference Include="System.Web.ApplicationServices" />
143+
<Reference Include="System.ComponentModel.DataAnnotations" />
144+
<Reference Include="System" />
145+
<Reference Include="System.Data" />
146+
<Reference Include="System.Core" />
147+
<Reference Include="System.Data.DataSetExtensions" />
148+
<Reference Include="System.Web.Extensions" />
149+
<Reference Include="System.Xml.Linq" />
150+
<Reference Include="System.Drawing" />
151+
<Reference Include="System.Web" />
152+
<Reference Include="System.Xml" />
153+
<Reference Include="System.Configuration" />
154+
<Reference Include="System.Web.Services" />
155+
<Reference Include="System.EnterpriseServices" />
156+
</ItemGroup>
157+
<ItemGroup>
158+
<Content Include="App_Data\Dashboards\dashboard1.xml" />
159+
<Content Include="App_Data\nwind.mdb" />
160+
<Content Include="Default.aspx" />
161+
<Content Include="Global.asax" />
162+
<None Include="Scripts\DeleteExtension.js" />
163+
<Content Include="Scripts\SaveAsExtension.js" />
164+
<Content Include="Web.config">
165+
<SubType>Designer</SubType>
166+
</Content>
167+
</ItemGroup>
168+
<ItemGroup>
169+
<Compile Include="Default.aspx.vb">
170+
<DependentUpon>Default.aspx</DependentUpon>
171+
<SubType>ASPXCodeBehind</SubType>
172+
</Compile>
173+
<Compile Include="Default.aspx.designer.vb">
174+
<DependentUpon>Default.aspx</DependentUpon>
175+
</Compile>
176+
<Compile Include="Global.asax.vb">
177+
<DependentUpon>Global.asax</DependentUpon>
178+
</Compile>
179+
<Compile Include="CustomDashbboardStorage.vb" />
180+
<Compile Include="My Project\AssemblyInfo.vb" />
181+
</ItemGroup>
182+
<ItemGroup>
183+
<None Include="Web.Debug.config">
184+
<DependentUpon>Web.config</DependentUpon>
185+
</None>
186+
<None Include="Web.Release.config">
187+
<DependentUpon>Web.config</DependentUpon>
188+
</None>
189+
</ItemGroup>
190+
<ItemGroup />
191+
<ItemGroup />
192+
<PropertyGroup>
193+
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
194+
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
195+
</PropertyGroup>
196+
<Import Project="$(MSBuildBinPath)\Microsoft.VisualBasic.targets" />
197+
<Import Project="$(VSToolsPath)\WebApplications\Microsoft.WebApplication.targets" Condition="'$(VSToolsPath)' != ''" />
198+
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v12.0\WebApplications\Microsoft.WebApplication.targets" Condition="false" />
199+
<ProjectExtensions>
200+
<VisualStudio>
201+
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
202+
<WebProjectProperties>
203+
<UseIIS>True</UseIIS>
204+
<AutoAssignPort>True</AutoAssignPort>
205+
<DevelopmentServerPort>62843</DevelopmentServerPort>
206+
<DevelopmentServerVPath>/</DevelopmentServerVPath>
207+
<IISUrl>http://localhost:62845/</IISUrl>
208+
<NTLMAuthentication>False</NTLMAuthentication>
209+
<UseCustomServer>False</UseCustomServer>
210+
<CustomServerUrl></CustomServerUrl>
211+
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
212+
</WebProjectProperties>
213+
</FlavorProperties>
214+
</VisualStudio>
215+
</ProjectExtensions>
216+
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
217+
Other similar extension points exist, see Microsoft.Common.targets.
218+
<Target Name="BeforeBuild">
219+
</Target>
220+
<Target Name="AfterBuild">
221+
</Target>
222+
-->
223+
</Project>
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
Imports DevExpress.DashboardWeb
2+
Imports System.IO
3+
4+
Namespace Storages
5+
6+
Public Class CustomDashboardFileStorage
7+
Inherits DashboardFileStorage
8+
9+
Public Sub New(ByVal workingDirectory As String)
10+
MyBase.New(workingDirectory)
11+
End Sub
12+
13+
Public Sub DeleteDashboard(ByVal dashboardID As String)
14+
Dim dashboardPath = MyBase.ResolveFileName(dashboardID)
15+
If File.Exists(dashboardPath) Then
16+
File.Delete(dashboardPath)
17+
End If
18+
End Sub
19+
End Class
20+
End Namespace
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
<%@ Page Language="vb" AutoEventWireup="true" CodeBehind="Default.aspx.vb" Inherits="AspDashboard_CustomExtension.Default" %>
2+
3+
<%@ Register Assembly="DevExpress.Dashboard.v17.1.Web, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
4+
Namespace="DevExpress.DashboardWeb" TagPrefix="dx" %>
5+
6+
<!DOCTYPE html>
7+
8+
<html xmlns="http://www.w3.org/1999/xhtml">
9+
<head runat="server">
10+
<title></title>
11+
</head>
12+
<body>
13+
14+
<script type="text/javascript" src="Scripts/SaveAsExtension.js"></script>
15+
<script type="text/javascript" src="Scripts/DeleteExtension.js"></script>
16+
17+
<!-- Defines the "Save As" extension template. -->
18+
<script type="text/html" id="dx-save-as-form">
19+
<div>Dashboard Name:</div>
20+
<div style="margin: 10px 0" data-bind="dxTextBox: { value: newName }"></div>
21+
<div data-bind="dxButton: { text: 'Save', onClick: saveAs }"></div>
22+
</script>
23+
24+
<script type="text/javascript">
25+
function onBeforeRender(sender) {
26+
var control = sender.GetDashboardControl();
27+
control.registerExtension(new SaveAsDashboardExtension(control));
28+
control.registerExtension(new DeleteDashboardExtension(sender));
29+
}
30+
</script>
31+
32+
<form id="form1" runat="server">
33+
<div style="position: absolute; top: 0; bottom: 0; left: 0; right: 0;">
34+
<dx:ASPxDashboard ID="ASPxDashboard1" ClientInstanceName="dashboard" runat="server"
35+
UseDashboardConfigurator="true"
36+
OnCustomDataCallback="ASPxDashboard1_CustomDataCallback"
37+
WorkingMode="Designer"
38+
Width="100%" Height="100%">
39+
<ClientSideEvents BeforeRender="onBeforeRender" />
40+
</dx:ASPxDashboard>
41+
</div>
42+
</form>
43+
</body>
44+
</html>

‎VB/AspDashboard_CustomExtension/Default.aspx.designer.vb

Lines changed: 33 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
Imports Storages
2+
Imports System
3+
Imports System.Collections.Generic
4+
Imports System.Web.Script.Serialization
5+
6+
Namespace AspDashboard_CustomExtension
7+
Partial Public Class [Default]
8+
Inherits System.Web.UI.Page
9+
10+
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
11+
12+
End Sub
13+
14+
Protected Sub ASPxDashboard1_CustomDataCallback(ByVal sender As Object, ByVal e As DevExpress.Web.CustomDataCallbackEventArgs)
15+
Dim parameters As Dictionary(Of String, String) = (New JavaScriptSerializer()).Deserialize(Of Dictionary(Of String, String))(e.Parameter)
16+
If Not parameters.ContainsKey("ExtensionName") Then
17+
Return
18+
End If
19+
20+
Dim newDashboardStorage As New CustomDashboardFileStorage("~/App_Data/Dashboards")
21+
If parameters("ExtensionName") = "dxdde-delete-dashboard" AndAlso parameters.ContainsKey("DashboardID") Then
22+
newDashboardStorage.DeleteDashboard(parameters("DashboardID"))
23+
End If
24+
End Sub
25+
End Class
26+
End Namespace
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<%@ Application Codebehind="Global.asax.vb" Inherits="AspDashboard_CustomExtension.Global" Language="vb" %>
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
Imports DevExpress.DashboardWeb
2+
Imports Storages
3+
Imports System
4+
5+
Namespace AspDashboard_CustomExtension
6+
Public Class [Global]
7+
Inherits System.Web.HttpApplication
8+
9+
Protected Sub Application_Start(ByVal sender As Object, ByVal e As EventArgs)
10+
Dim newDashboardStorage As New CustomDashboardFileStorage("~/App_Data/Dashboards")
11+
DashboardConfigurator.Default.SetDashboardStorage(newDashboardStorage)
12+
End Sub
13+
End Class
14+
End Namespace
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
Imports System.Reflection
2+
Imports System.Runtime.CompilerServices
3+
Imports System.Runtime.InteropServices
4+
5+
' General Information about an assembly is controlled through the following
6+
' set of attributes. Change these attribute values to modify the information
7+
' associated with an assembly.
8+
<Assembly: AssemblyTitle("WebApplication18")>
9+
<Assembly: AssemblyDescription("")>
10+
<Assembly: AssemblyConfiguration("")>
11+
<Assembly: AssemblyCompany("")>
12+
<Assembly: AssemblyProduct("WebApplication18")>
13+
<Assembly: AssemblyCopyright("Copyright © 2016")>
14+
<Assembly: AssemblyTrademark("")>
15+
<Assembly: AssemblyCulture("")>
16+
17+
' Setting ComVisible to false makes the types in this assembly not visible
18+
' to COM components. If you need to access a type in this assembly from
19+
' COM, set the ComVisible attribute to true on that type.
20+
<Assembly: ComVisible(False)>
21+
22+
' The following GUID is for the ID of the typelib if this project is exposed to COM
23+
<Assembly: Guid("bc0f83c5-6bdb-46ed-a9ae-2c141eafeb3d")>
24+
25+
' Version information for an assembly consists of the following four values:
26+
'
27+
' Major Version
28+
' Minor Version
29+
' Build Number
30+
' Revision
31+
'
32+
' You can specify all the values or you can default the Revision and Build Numbers
33+
' by using the '*' as shown below:
34+
<Assembly: AssemblyVersion("1.0.0.0")>
35+
<Assembly: AssemblyFileVersion("1.0.0.0")>
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
// Creates and implements a custom DeleteDashboardExtension class.
2+
3+
function DeleteDashboardExtension(_wrapper) {
4+
var _this = this;
5+
this._wrapper = _wrapper;
6+
this._control = _wrapper.GetDashboardControl();
7+
this._toolbox = this._control.findExtension('toolbox');
8+
this.name = "dxdde-delete-dashboard";
9+
this.deleteDashboard = function () {
10+
if (_this.isExtensionAvailable()) {
11+
if (confirm("Delete this Dashboard?")) {
12+
var dashboardid = _this._control.dashboardContainer().id;
13+
var param = JSON.stringify({ DashboardID: dashboardid, ExtensionName: _this.name });
14+
_this._toolbox.menuVisible(false);
15+
_this._wrapper.PerformDataCallback(param, function () {
16+
_this._control.close();
17+
});
18+
}
19+
}
20+
}
21+
this._menuItem = {
22+
id: this.name,
23+
title: "Delete",
24+
click: this.deleteDashboard,
25+
selected: ko.observable(false),
26+
disabled: ko.computed(function () { return !_this._control.dashboard(); }),
27+
index: 113,
28+
hasSeparator: true,
29+
data: _this
30+
};
31+
}
32+
33+
DeleteDashboardExtension.prototype.isExtensionAvailable = function () {
34+
return this._toolbox !== undefined;
35+
}
36+
37+
DeleteDashboardExtension.prototype.start = function () {
38+
if (this.isExtensionAvailable())
39+
this._toolbox.menuItems.push(this._menuItem);
40+
};
41+
DeleteDashboardExtension.prototype.stop = function () {
42+
if (this.isExtensionAvailable())
43+
this._toolbox.menuItems.remove(this._menuItem);
44+
};
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
// Creates and implements a custom SaveAsDashboardExtension class.
2+
3+
function SaveAsDashboardExtension(dashboardControl) {
4+
var _this = this;
5+
this._control = dashboardControl;
6+
this._toolbox = this._control.findExtension("toolbox");
7+
this._newDashboardExtension = this._control.findExtension("create-dashboard");
8+
this._menuItem = {
9+
id: "dashboard-save-as",
10+
title: "Save As...",
11+
template: "dx-save-as-form",
12+
selected: ko.observable(true),
13+
disabled: ko.computed(function () { return !dashboardControl.dashboard(); }),
14+
index: 112,
15+
data: _this
16+
};
17+
this.saveAs = function () {
18+
if (this.isExtensionAvailable()) {
19+
this._toolbox.menuVisible(false);
20+
this._newDashboardExtension.performCreateDashboard(this.newName(), this._control.dashboard().getJSON());
21+
}
22+
};
23+
this.newName = ko.observable("New Dashboard Name");
24+
}
25+
26+
SaveAsDashboardExtension.prototype.isExtensionAvailable = function () {
27+
return this._toolbox !== undefined && this._newDashboardExtension !== undefined;
28+
}
29+
30+
SaveAsDashboardExtension.prototype.start = function () {
31+
if (this.isExtensionAvailable())
32+
this._toolbox.menuItems.push(this._menuItem);
33+
};
34+
SaveAsDashboardExtension.prototype.stop = function () {
35+
if (this.isExtensionAvailable())
36+
this._toolbox.menuItems.remove(this._menuItem);
37+
}
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
3+
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
4+
5+
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
6+
<!--
7+
In the example below, the "SetAttributes" transform will change the value of
8+
"connectionString" to use "ReleaseSQLServer" only when the "Match" locator
9+
finds an attribute "name" that has a value of "MyDB".
10+
11+
<connectionStrings>
12+
<add name="MyDB"
13+
connectionString="Data Source=ReleaseSQLServer;Initial Catalog=MyReleaseDB;Integrated Security=True"
14+
xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
15+
</connectionStrings>
16+
-->
17+
<system.web>
18+
<!--
19+
In the example below, the "Replace" transform will replace the entire
20+
<customErrors> section of your web.config file.
21+
Note that because there is only one customErrors section under the
22+
<system.web> node, there is no need to use the "xdt:Locator" attribute.
23+
24+
<customErrors defaultRedirect="GenericError.htm"
25+
mode="RemoteOnly" xdt:Transform="Replace">
26+
<error statusCode="500" redirect="InternalError.htm"/>
27+
</customErrors>
28+
-->
29+
</system.web>
30+
</configuration>
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
3+
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
4+
5+
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
6+
<!--
7+
In the example below, the "SetAttributes" transform will change the value of
8+
"connectionString" to use "ReleaseSQLServer" only when the "Match" locator
9+
finds an attribute "name" that has a value of "MyDB".
10+
11+
<connectionStrings>
12+
<add name="MyDB"
13+
connectionString="Data Source=ReleaseSQLServer;Initial Catalog=MyReleaseDB;Integrated Security=True"
14+
xdt:Transform="SetAttributes" xdt:Locator="Match(name)"/>
15+
</connectionStrings>
16+
-->
17+
<system.web>
18+
<compilation xdt:Transform="RemoveAttributes(debug)" />
19+
<!--
20+
In the example below, the "Replace" transform will replace the entire
21+
<customErrors> section of your web.config file.
22+
Note that because there is only one customErrors section under the
23+
<system.web> node, there is no need to use the "xdt:Locator" attribute.
24+
25+
<customErrors defaultRedirect="GenericError.htm"
26+
mode="RemoteOnly" xdt:Transform="Replace">
27+
<error statusCode="500" redirect="InternalError.htm"/>
28+
</customErrors>
29+
-->
30+
</system.web>
31+
</configuration>
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
<?xml version="1.0"?>
2+
<!--
3+
For more information on how to configure your ASP.NET application, please visit
4+
http://go.microsoft.com/fwlink/?LinkId=169433
5+
-->
6+
<configuration>
7+
<configSections>
8+
<sectionGroup name="devExpress">
9+
<section name="themes" type="DevExpress.Web.ThemesConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
10+
<section name="compression" type="DevExpress.Web.CompressionConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
11+
<section name="settings" type="DevExpress.Web.SettingsConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
12+
<section name="errors" type="DevExpress.Web.ErrorsConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
13+
<section name="resources" type="DevExpress.Web.ResourcesConfigurationSection, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" requirePermission="false" />
14+
</sectionGroup>
15+
</configSections>
16+
<connectionStrings>
17+
<add name="nwindConnection" connectionString=" XpoProvider=MSAccess; Provider=Microsoft.Jet.OLEDB.4.0; Data Source=|DataDirectory|\nwind.mdb;" />
18+
</connectionStrings>
19+
<system.web>
20+
<compilation debug="true" targetFramework="4.0">
21+
<assemblies>
22+
<add assembly="DevExpress.Dashboard.v17.1.Web, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
23+
<add assembly="DevExpress.Dashboard.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
24+
<add assembly="DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
25+
<add assembly="DevExpress.DataAccess.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
26+
<add assembly="DevExpress.Data.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
27+
<add assembly="DevExpress.Office.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
28+
<add assembly="DevExpress.Printing.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
29+
<add assembly="DevExpress.Web.Resources.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
30+
<add assembly="DevExpress.Charts.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
31+
<add assembly="DevExpress.Xpo.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
32+
<add assembly="DevExpress.RichEdit.v17.1.Core, Version=17.1.8.0, Culture=neutral, PublicKeyToken=B88D1754D700E49A" />
33+
<add assembly="DevExpress.Web.ASPxThemes.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
34+
</assemblies>
35+
</compilation>
36+
<httpModules>
37+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" name="ASPxHttpHandlerModule" />
38+
</httpModules>
39+
<httpHandlers>
40+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" verb="GET,POST" path="DX.ashx" validate="false" />
41+
<add verb="GET,POST" path="ASPxUploadProgressHandlerPage.ashx" type="DevExpress.Web.ASPxUploadProgressHttpHandler, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" validate="false" />
42+
<add validate="false" verb="GET,POST" path="DXDD.axd" type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
43+
</httpHandlers>
44+
</system.web>
45+
<system.webServer>
46+
<modules>
47+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" name="ASPxHttpHandlerModule" />
48+
</modules>
49+
<validation validateIntegratedModeConfiguration="false" />
50+
<handlers>
51+
<add type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" verb="GET,POST" path="DX.ashx" name="ASPxHttpHandlerModule" preCondition="integratedMode" />
52+
<add name="ASPxUploadProgressHandler" preCondition="integratedMode" verb="GET,POST" path="ASPxUploadProgressHandlerPage.ashx" type="DevExpress.Web.ASPxUploadProgressHttpHandler, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
53+
<add name="WebDashboardHandler" preCondition="integratedMode" verb="GET,POST" path="DXDD.axd" type="DevExpress.Web.ASPxHttpHandlerModule, DevExpress.Web.v17.1, Version=17.1.8.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
54+
</handlers>
55+
</system.webServer>
56+
<devExpress>
57+
<themes enableThemesAssembly="true" styleSheetTheme="" theme="" customThemeAssemblies="" baseColor="" font="" />
58+
<compression enableHtmlCompression="false" enableCallbackCompression="true" enableResourceCompression="true" enableResourceMerging="true" />
59+
<settings accessibilityCompliant="false" doctypeMode="Html5" rightToLeft="false" embedRequiredClientLibraries="true" ieCompatibilityVersion="edge" checkReferencesToExternalScripts="false" protectControlState="true" />
60+
<errors callbackErrorRedirectUrl="" />
61+
</devExpress>
62+
</configuration>

‎config.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"runOnWeb": false,
3+
"autoGenerateVb": true
4+
}

0 commit comments

Comments
 (0)
Please sign in to comment.