├── .gitattributes
├── .github
└── workflows
│ └── vale.yml
├── .gitignore
├── CODEOWNERS
├── CS
├── AddingDataEditorsAtRuntime
│ ├── AddingDataEditorsAtRuntime.csproj
│ ├── AddingDataEditorsAtRuntime.sln
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── AppShell.xaml
│ ├── AppShell.xaml.cs
│ ├── MainPage.xaml
│ ├── MainPage.xaml.cs
│ ├── MauiProgram.cs
│ ├── Platforms
│ │ ├── Android
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── MainActivity.cs
│ │ │ ├── MainApplication.cs
│ │ │ └── Resources
│ │ │ │ └── values
│ │ │ │ └── colors.xml
│ │ └── iOS
│ │ │ ├── AppDelegate.cs
│ │ │ ├── Info.plist
│ │ │ └── Program.cs
│ ├── Readme.md
│ └── Resources
│ │ ├── AppIcon
│ │ ├── appicon.svg
│ │ └── appiconfg.svg
│ │ ├── Fonts
│ │ ├── OpenSans-Regular.ttf
│ │ └── OpenSans-Semibold.ttf
│ │ ├── Images
│ │ └── dotnet_bot.svg
│ │ ├── Raw
│ │ └── AboutAssets.txt
│ │ ├── Splash
│ │ └── splash.svg
│ │ └── Styles
│ │ ├── Colors.xaml
│ │ └── Styles.xaml
├── ComboBoxEditor
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── AppShell.xaml
│ ├── AppShell.xaml.cs
│ ├── ComboBoxEditor.csproj
│ ├── ComboBoxEditor.sln
│ ├── MainPage.xaml
│ ├── MainPage.xaml.cs
│ ├── MauiProgram.cs
│ ├── Platforms
│ │ ├── Android
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── MainActivity.cs
│ │ │ ├── MainApplication.cs
│ │ │ └── Resources
│ │ │ │ └── values
│ │ │ │ └── colors.xml
│ │ └── iOS
│ │ │ ├── AppDelegate.cs
│ │ │ ├── Info.plist
│ │ │ └── Program.cs
│ ├── Readme.md
│ └── Resources
│ │ ├── AppIcon
│ │ ├── appicon.svg
│ │ └── appiconfg.svg
│ │ ├── Fonts
│ │ ├── OpenSans-Regular.ttf
│ │ └── OpenSans-Semibold.ttf
│ │ ├── Images
│ │ └── dotnet_bot.svg
│ │ ├── Raw
│ │ └── AboutAssets.txt
│ │ ├── Splash
│ │ └── splash.svg
│ │ └── Styles
│ │ ├── Colors.xaml
│ │ └── Styles.xaml
├── CustomAppearance
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── AppShell.xaml
│ ├── AppShell.xaml.cs
│ ├── CustomAppearance.csproj
│ ├── CustomAppearance.sln
│ ├── EmployeeInfo.cs
│ ├── EmployeeRepository.cs
│ ├── MainPage.xaml
│ ├── MainPage.xaml.cs
│ ├── MauiProgram.cs
│ ├── Platforms
│ │ ├── Android
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── MainActivity.cs
│ │ │ ├── MainApplication.cs
│ │ │ └── Resources
│ │ │ │ └── values
│ │ │ │ └── colors.xml
│ │ └── iOS
│ │ │ ├── AppDelegate.cs
│ │ │ ├── Info.plist
│ │ │ └── Program.cs
│ ├── Readme.md
│ └── Resources
│ │ ├── AppIcon
│ │ ├── appicon.svg
│ │ └── appiconfg.svg
│ │ ├── Fonts
│ │ ├── OpenSans-Regular.ttf
│ │ └── OpenSans-Semibold.ttf
│ │ ├── Images
│ │ ├── dotnet_bot.svg
│ │ └── steven_buchanan.jpg
│ │ ├── Raw
│ │ └── AboutAssets.txt
│ │ ├── Splash
│ │ └── splash.svg
│ │ └── Styles
│ │ ├── Colors.xaml
│ │ └── Styles.xaml
├── DataFormGetStarted
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── DataFormGetStarted.csproj
│ ├── DataFormGetStarted.sln
│ ├── GettingStarted.txt
│ ├── MainPage.xaml
│ ├── MainPage.xaml.cs
│ ├── MauiProgram.cs
│ ├── PersonalInfo.cs
│ ├── Platforms
│ │ ├── Android
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── MainActivity.cs
│ │ │ ├── MainApplication.cs
│ │ │ └── Resources
│ │ │ │ └── values
│ │ │ │ ├── colors.xml
│ │ │ │ └── styles.xml
│ │ └── iOS
│ │ │ ├── AppDelegate.cs
│ │ │ ├── Info.plist
│ │ │ ├── Program.cs
│ │ │ └── Resources
│ │ │ └── LaunchScreen.xib
│ ├── Readme.md
│ └── Resources
│ │ ├── Fonts
│ │ ├── OpenSans-Regular.ttf
│ │ ├── roboto-bold.ttf
│ │ ├── roboto-regular.ttf
│ │ └── univia-pro-regular.ttf
│ │ ├── Images
│ │ ├── background.svg
│ │ ├── dotnet_bot.svg
│ │ ├── name.png
│ │ ├── person_outline.svg
│ │ └── xamarin_logo.svg
│ │ ├── appicon.svg
│ │ └── splashscreen.svg
├── EditFormExample
│ ├── App.xaml
│ ├── App.xaml.cs
│ ├── AppShell.xaml
│ ├── AppShell.xaml.cs
│ ├── Customer.cs
│ ├── EditFormExample.csproj
│ ├── EditFormExample.sln
│ ├── GettingStarted.txt
│ ├── ImageEditView.xaml
│ ├── ImageEditView.xaml.cs
│ ├── MainPage.xaml
│ ├── MainPage.xaml.cs
│ ├── MainViewModel.cs
│ ├── MauiProgram.cs
│ ├── Platforms
│ │ ├── Android
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── MainActivity.cs
│ │ │ ├── MainApplication.cs
│ │ │ └── Resources
│ │ │ │ └── values
│ │ │ │ ├── colors.xml
│ │ │ │ └── styles.xml
│ │ └── iOS
│ │ │ ├── AppDelegate.cs
│ │ │ ├── Info.plist
│ │ │ ├── Program.cs
│ │ │ └── Resources
│ │ │ └── LaunchScreen.xib
│ ├── Readme.md
│ └── Resources
│ │ ├── AppIcon
│ │ ├── appicon.svg
│ │ └── appiconfg.svg
│ │ ├── DevExpressMaui.de.resx
│ │ ├── DevExpressMaui.es.resx
│ │ ├── DevExpressMaui.fr.resx
│ │ ├── DevExpressMaui.resx
│ │ ├── DevExpressMaui.ru.resx
│ │ ├── Fonts
│ │ ├── OpenSans-Regular.ttf
│ │ ├── roboto-bold.ttf
│ │ ├── roboto-regular.ttf
│ │ └── univia-pro-regular.ttf
│ │ ├── Images
│ │ ├── background.svg
│ │ ├── check.svg
│ │ ├── delete.svg
│ │ ├── dotnet_bot.svg
│ │ ├── editorscalendar.svg
│ │ ├── editorscompany.svg
│ │ ├── editorsemail.svg
│ │ ├── editorslocation.svg
│ │ ├── editorsname.svg
│ │ ├── editorsphone.svg
│ │ ├── gallery.svg
│ │ ├── ic_arrow_back.svg
│ │ ├── ic_check.svg
│ │ ├── ic_frame_circle.svg
│ │ ├── ic_frame_rect.svg
│ │ ├── ic_mirror_h.svg
│ │ ├── ic_mirror_v.svg
│ │ ├── ic_rotate_left.svg
│ │ ├── ic_rotate_right.svg
│ │ ├── jennie_photo.png
│ │ ├── pencil.svg
│ │ ├── savechanges.svg
│ │ └── take_photo.svg
│ │ └── Splash
│ │ └── splash.svg
└── GettingStarted.sln
├── Images
├── data-form-combobox-android.png
├── data-form-combobox-iphone.png
├── data-form-custom-appearance-android.png
├── data-form-custom-appearance-iphone.png
├── data-form-example-iphone.png
├── data-form-example-pixel.png
├── data-form-runtime-android.png
├── data-form-runtime-iphone.png
├── data-form-with-image-edit-bs.png
├── data-form-with-image-edit-upload.png
└── maui.png
├── LICENSE
├── README.md
└── config.json
/.gitattributes:
--------------------------------------------------------------------------------
1 | VB/* linguist-vendored
2 | scripts linguist-vendored
3 | *.css linguist-detectable=false
4 | *.aff linguist-detectable=false
5 |
--------------------------------------------------------------------------------
/.github/workflows/vale.yml:
--------------------------------------------------------------------------------
1 | name: vale-validation
2 | on:
3 | pull_request:
4 | paths:
5 | - README.md
6 | - readme.md
7 | - Readme.md
8 |
9 | jobs:
10 | vale:
11 | name: runner / vale
12 | runs-on: ubuntu-latest
13 | steps:
14 | - name: clone repo
15 | uses: actions/checkout@v4
16 | - name: clone vale-styles repo
17 | uses: actions/checkout@v4
18 | with:
19 | repository: DevExpress/vale-styles
20 | path: vale-styles
21 | ssh-key: ${{ secrets.VALE_STYLES_ACCESS_KEY }}
22 | - name: copy vale rules to the root repo
23 | run: shopt -s dotglob && cp -r ./vale-styles/vale/* .
24 | - name: vale linter check
25 | uses: DevExpress/vale-action@reviewdog
26 | with:
27 | files: '["README.md", "readme.md", "Readme.md"]'
28 | fail_on_error: true
29 | filter_mode: nofilter
30 | reporter: github-check
31 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
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 | [Bb]in/
24 | [Oo]bj/
25 | [Ll]og/
26 |
27 | # Visual Studio 2015 cache/options directory
28 | .vs/
29 | # Uncomment if you have tasks that create the project's static files in wwwroot
30 | #wwwroot/
31 |
32 | # MSTest test Results
33 | [Tt]est[Rr]esult*/
34 | [Bb]uild[Ll]og.*
35 |
36 | # NUNIT
37 | *.VisualState.xml
38 | TestResult.xml
39 |
40 | # Build Results of an ATL Project
41 | [Dd]ebugPS/
42 | [Rr]eleasePS/
43 | dlldata.c
44 |
45 | # Benchmark Results
46 | BenchmarkDotNet.Artifacts/
47 |
48 | # .NET Core
49 | project.lock.json
50 | project.fragment.lock.json
51 | artifacts/
52 | **/Properties/launchSettings.json
53 |
54 | *_i.c
55 | *_p.c
56 | *_i.h
57 | *.ilk
58 | *.meta
59 | *.obj
60 | *.pch
61 | *.pdb
62 | *.pgc
63 | *.pgd
64 | *.rsp
65 | *.sbr
66 | *.tlb
67 | *.tli
68 | *.tlh
69 | *.tmp
70 | *.tmp_proj
71 | *.log
72 | *.vspscc
73 | *.vssscc
74 | .builds
75 | *.pidb
76 | *.svclog
77 | *.scc
78 |
79 | # Chutzpah Test files
80 | _Chutzpah*
81 |
82 | # Visual C++ cache files
83 | ipch/
84 | *.aps
85 | *.ncb
86 | *.opendb
87 | *.opensdf
88 | *.sdf
89 | *.cachefile
90 | *.VC.db
91 | *.VC.VC.opendb
92 |
93 | # Visual Studio profiler
94 | *.psess
95 | *.vsp
96 | *.vspx
97 | *.sap
98 |
99 | # TFS 2012 Local Workspace
100 | $tf/
101 |
102 | # Guidance Automation Toolkit
103 | *.gpState
104 |
105 | # ReSharper is a .NET coding add-in
106 | _ReSharper*/
107 | *.[Rr]e[Ss]harper
108 | *.DotSettings.user
109 |
110 | # JustCode is a .NET coding add-in
111 | .JustCode
112 |
113 | # TeamCity is a build add-in
114 | _TeamCity*
115 |
116 | # DotCover is a Code Coverage Tool
117 | *.dotCover
118 |
119 | # AxoCover is a Code Coverage Tool
120 | .axoCover/*
121 | !.axoCover/settings.json
122 |
123 | # Visual Studio code coverage results
124 | *.coverage
125 | *.coveragexml
126 |
127 | # NCrunch
128 | _NCrunch_*
129 | .*crunch*.local.xml
130 | nCrunchTemp_*
131 |
132 | # MightyMoose
133 | *.mm.*
134 | AutoTest.Net/
135 |
136 | # Web workbench (sass)
137 | .sass-cache/
138 |
139 | # Installshield output folder
140 | [Ee]xpress/
141 |
142 | # DocProject is a documentation generator add-in
143 | DocProject/buildhelp/
144 | DocProject/Help/*.HxT
145 | DocProject/Help/*.HxC
146 | DocProject/Help/*.hhc
147 | DocProject/Help/*.hhk
148 | DocProject/Help/*.hhp
149 | DocProject/Help/Html2
150 | DocProject/Help/html
151 |
152 | # Click-Once directory
153 | publish/
154 |
155 | # Publish Web Output
156 | *.[Pp]ublish.xml
157 | *.azurePubxml
158 | # Note: Comment the next line if you want to checkin your web deploy settings,
159 | # but database connection strings (with potential passwords) will be unencrypted
160 | *.pubxml
161 | *.publishproj
162 |
163 | # Microsoft Azure Web App publish settings. Comment the next line if you want to
164 | # checkin your Azure Web App publish settings, but sensitive information contained
165 | # in these scripts will be unencrypted
166 | PublishScripts/
167 |
168 | # NuGet Packages
169 | *.nupkg
170 | # The packages folder can be ignored because of Package Restore
171 | **/packages/*
172 | # except build/, which is used as an MSBuild target.
173 | !**/packages/build/
174 | # Uncomment if necessary however generally it will be regenerated when needed
175 | #!**/packages/repositories.config
176 | # NuGet v3's project.json files produces more ignorable files
177 | *.nuget.props
178 | *.nuget.targets
179 |
180 | # Microsoft Azure Build Output
181 | csx/
182 | *.build.csdef
183 |
184 | # Microsoft Azure Emulator
185 | ecf/
186 | rcf/
187 |
188 | # Windows Store app package directories and files
189 | AppPackages/
190 | BundleArtifacts/
191 | Package.StoreAssociation.xml
192 | _pkginfo.txt
193 | *.appx
194 |
195 | # Visual Studio cache files
196 | # files ending in .cache can be ignored
197 | *.[Cc]ache
198 | # but keep track of directories ending in .cache
199 | !*.[Cc]ache/
200 |
201 | # Others
202 | ClientBin/
203 | ~$*
204 | *~
205 | *.dbmdl
206 | *.dbproj.schemaview
207 | *.jfm
208 | *.pfx
209 | *.publishsettings
210 | orleans.codegen.cs
211 |
212 | # Since there are multiple workflows, uncomment next line to ignore bower_components
213 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
214 | #bower_components/
215 |
216 | # RIA/Silverlight projects
217 | Generated_Code/
218 |
219 | # Backup & report files from converting an old project file
220 | # to a newer Visual Studio version. Backup files are not needed,
221 | # because we have git ;-)
222 | _UpgradeReport_Files/
223 | Backup*/
224 | UpgradeLog*.XML
225 | UpgradeLog*.htm
226 |
227 | # SQL Server files
228 | *.mdf
229 | *.ldf
230 | *.ndf
231 |
232 | # Business Intelligence projects
233 | *.rdl.data
234 | *.bim.layout
235 | *.bim_*.settings
236 |
237 | # Microsoft Fakes
238 | FakesAssemblies/
239 |
240 | # GhostDoc plugin setting file
241 | *.GhostDoc.xml
242 |
243 | # Node.js Tools for Visual Studio
244 | .ntvs_analysis.dat
245 | node_modules/
246 |
247 | # Typescript v1 declaration files
248 | typings/
249 |
250 | # Visual Studio 6 build log
251 | *.plg
252 |
253 | # Visual Studio 6 workspace options file
254 | *.opt
255 |
256 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
257 | *.vbw
258 |
259 | # Visual Studio LightSwitch build output
260 | **/*.HTMLClient/GeneratedArtifacts
261 | **/*.DesktopClient/GeneratedArtifacts
262 | **/*.DesktopClient/ModelManifest.xml
263 | **/*.Server/GeneratedArtifacts
264 | **/*.Server/ModelManifest.xml
265 | _Pvt_Extensions
266 |
267 | # Paket dependency manager
268 | .paket/paket.exe
269 | paket-files/
270 |
271 | # FAKE - F# Make
272 | .fake/
273 |
274 | # JetBrains Rider
275 | .idea/
276 | *.sln.iml
277 |
278 | # CodeRush
279 | .cr/
280 |
281 | # Python Tools for Visual Studio (PTVS)
282 | __pycache__/
283 | *.pyc
284 |
285 | # Cake - Uncomment if you are using it
286 | # tools/**
287 | # !tools/packages.config
288 |
289 | # Tabs Studio
290 | *.tss
291 |
292 | # Telerik's JustMock configuration file
293 | *.jmconfig
294 |
295 | # BizTalk build output
296 | *.btp.cs
297 | *.btm.cs
298 | *.odx.cs
299 | *.xsd.cs
300 |
301 | #ExampleRangeTester artifacts
302 | TesterMetadata.xml
303 |
304 | # Backup files
305 | *.bak
306 |
307 | # Local server for npm packages
308 | .npmrc
309 |
--------------------------------------------------------------------------------
/CODEOWNERS:
--------------------------------------------------------------------------------
1 | * @DevExpressExampleBot
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/AddingDataEditorsAtRuntime.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | net9.0-android;net9.0-ios
4 | Exe
5 | AddingDataEditorsAtRuntime
6 | true
7 | true
8 | enable
9 |
10 | AddingDataEditorsAtRuntime
11 |
12 | com.companyname.addingdataeditorsatruntime
13 | FF5BEBAA-BEA1-4555-9D56-C3F8C83E73AF
14 |
15 | 1.0
16 | 1
17 | 14.2
18 | 21.0
19 | 9.0.10
20 |
21 |
22 | false
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/AddingDataEditorsAtRuntime.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 25.0.1705.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AddingDataEditorsAtRuntime", "AddingDataEditorsAtRuntime.csproj", "{225658EB-E704-48FD-8743-95387AC021EA}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {225658EB-E704-48FD-8743-95387AC021EA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {225658EB-E704-48FD-8743-95387AC021EA}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {225658EB-E704-48FD-8743-95387AC021EA}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
17 | {225658EB-E704-48FD-8743-95387AC021EA}.Release|Any CPU.ActiveCfg = Release|Any CPU
18 | {225658EB-E704-48FD-8743-95387AC021EA}.Release|Any CPU.Build.0 = Release|Any CPU
19 | {225658EB-E704-48FD-8743-95387AC021EA}.Release|Any CPU.Deploy.0 = Release|Any CPU
20 | EndGlobalSection
21 | GlobalSection(SolutionProperties) = preSolution
22 | HideSolutionNode = FALSE
23 | EndGlobalSection
24 | GlobalSection(ExtensibilityGlobals) = postSolution
25 | SolutionGuid = {EACC01AA-7BA9-4E8A-BABA-907F08FA3A47}
26 | EndGlobalSection
27 | EndGlobal
28 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/App.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/App.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace AddingDataEditorsAtRuntime {
2 | public partial class App : Application {
3 | public App() {
4 | InitializeComponent();
5 |
6 | MainPage = new AppShell();
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/AppShell.xaml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/AppShell.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace AddingDataEditorsAtRuntime {
2 | public partial class AppShell : Shell {
3 | public AppShell() {
4 | InitializeComponent();
5 | }
6 | }
7 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/MainPage.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/MainPage.xaml.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using DevExpress.Maui.DataForm;
3 |
4 | namespace AddingDataEditorsAtRuntime {
5 | public partial class MainPage : ContentPage {
6 | Dictionary dataModel = new Dictionary();
7 | public MainPage() {
8 | InitializeComponent();
9 | dataForm.IsAutoGenerationEnabled = false;
10 | dataForm.CommitMode = CommitMode.PropertyChanged;
11 | dataForm.DataObject = dataModel;
12 | }
13 |
14 | public static string[] Emails = { "ameliah@dx-email.com",
15 | "anthonys@dx-email.com",
16 | "arnolds@dx-email.com",
17 | "arthurm@dx-email.com" };
18 |
19 | private void Add_Editor(object sender, EventArgs e) {
20 | string editorName = $"Email {dataModel.Count}";
21 | Random random = new Random();
22 |
23 | int mailindex = random.Next(1, Emails.Length);
24 | object editorValue = Emails[mailindex];
25 |
26 | var dataformItem = new DataFormTextItem { FieldName = editorName };
27 |
28 | dataModel.Add(dataformItem.FieldName, editorValue);
29 | dataForm.Items.Add(dataformItem);
30 | }
31 |
32 | private void Remove_Editor(object sender, EventArgs e) {
33 | if (dataForm.Items.Count > 0) {
34 | dataModel.Remove(dataModel.Last().Key);
35 | dataForm.Items.RemoveAt(dataForm.Items.Count - 1);
36 | }
37 | }
38 | }
39 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/MauiProgram.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui;
2 |
3 | namespace AddingDataEditorsAtRuntime {
4 | public static class MauiProgram {
5 | public static MauiApp CreateMauiApp() {
6 | var builder = MauiApp.CreateBuilder();
7 | builder
8 | .UseMauiApp()
9 | .UseDevExpress()
10 | .UseDevExpressCollectionView()
11 | .UseDevExpressControls()
12 | .UseDevExpressEditors()
13 | .ConfigureFonts(fonts => {
14 | fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
15 | fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
16 | });
17 |
18 | return builder.Build();
19 | }
20 | }
21 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Platforms/Android/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Platforms/Android/MainActivity.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Content.PM;
3 | using Android.OS;
4 |
5 | namespace AddingDataEditorsAtRuntime {
6 | [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
7 | public class MainActivity : MauiAppCompatActivity {
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Platforms/Android/MainApplication.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Runtime;
3 |
4 | namespace AddingDataEditorsAtRuntime {
5 | [Application]
6 | public class MainApplication : MauiApplication {
7 | public MainApplication(IntPtr handle, JniHandleOwnership ownership)
8 | : base(handle, ownership) {
9 | }
10 |
11 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Platforms/Android/Resources/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #512BD4
4 | #2B0B98
5 | #2B0B98
6 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Platforms/iOS/AppDelegate.cs:
--------------------------------------------------------------------------------
1 | using Foundation;
2 |
3 | namespace AddingDataEditorsAtRuntime {
4 | [Register("AppDelegate")]
5 | public class AppDelegate : MauiUIApplicationDelegate {
6 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
7 | }
8 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Platforms/iOS/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | LSRequiresIPhoneOS
6 |
7 | UIDeviceFamily
8 |
9 | 1
10 | 2
11 |
12 | UIRequiredDeviceCapabilities
13 |
14 | arm64
15 |
16 | UISupportedInterfaceOrientations
17 |
18 | UIInterfaceOrientationPortrait
19 | UIInterfaceOrientationLandscapeLeft
20 | UIInterfaceOrientationLandscapeRight
21 |
22 | UISupportedInterfaceOrientations~ipad
23 |
24 | UIInterfaceOrientationPortrait
25 | UIInterfaceOrientationPortraitUpsideDown
26 | UIInterfaceOrientationLandscapeLeft
27 | UIInterfaceOrientationLandscapeRight
28 |
29 | XSAppIconAssets
30 | Assets.xcassets/appicon.appiconset
31 |
32 |
33 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Platforms/iOS/Program.cs:
--------------------------------------------------------------------------------
1 | using ObjCRuntime;
2 | using UIKit;
3 |
4 | namespace AddingDataEditorsAtRuntime {
5 | public class Program {
6 | // This is the main entry point of the application.
7 | static void Main(string[] args) {
8 | // if you want to use a different Application Delegate class from "AppDelegate"
9 | // you can specify it here.
10 | UIApplication.Main(args, null, typeof(AppDelegate));
11 | }
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Readme.md:
--------------------------------------------------------------------------------
1 | # DataForm for .NET MAUI - Add/Remove Data Editors at Runtime
2 |
3 | This example demonstrates how to add editors to a data form at runtime. It adds a [DataFormTextItem](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormTextItem) object to the data form's [Items](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormView.Items) collection when a user taps the **Add Editor** button. To remove the last item from the collection, click the **Remove Editor** button.
4 |
5 |
6 |
7 |
8 | ## Files to Review
9 |
10 | * [MainPage.xaml](MainPage.xaml)
11 | * [MainPage.xaml.cs](MainPage.xaml.cs)
12 |
13 | ## Documentation
14 |
15 | [DataFormView.Items](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormView.Items)
16 |
17 | ## More Examples
18 |
19 | * [Get Started with the DataForm](../DataFormGetStarted)
20 | * [Customize a DataFrom Appearance](../CustomAppearance)
21 | * [Display a ComboBoxEdit in the DataForm](../ComboBoxEditor)
22 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Resources/AppIcon/appicon.svg:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Resources/AppIcon/appiconfg.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Resources/Fonts/OpenSans-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/AddingDataEditorsAtRuntime/Resources/Fonts/OpenSans-Regular.ttf
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Resources/Fonts/OpenSans-Semibold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/AddingDataEditorsAtRuntime/Resources/Fonts/OpenSans-Semibold.ttf
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Resources/Raw/AboutAssets.txt:
--------------------------------------------------------------------------------
1 | Any raw assets you want to be deployed with your application can be placed in
2 | this directory (and child directories). Deployment of the asset to your application
3 | is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
4 |
5 |
6 |
7 | These files will be deployed with you package and will be accessible using Essentials:
8 |
9 | async Task LoadMauiAsset()
10 | {
11 | using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
12 | using var reader = new StreamReader(stream);
13 |
14 | var contents = reader.ReadToEnd();
15 | }
16 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Resources/Splash/splash.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/CS/AddingDataEditorsAtRuntime/Resources/Styles/Colors.xaml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | #512BD4
7 | #DFD8F7
8 | #2B0B98
9 | White
10 | Black
11 | #E1E1E1
12 | #C8C8C8
13 | #ACACAC
14 | #919191
15 | #6E6E6E
16 | #404040
17 | #212121
18 | #141414
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 | #F7B548
34 | #FFD590
35 | #FFE5B9
36 | #28C2D1
37 | #7BDDEF
38 | #C3F2F4
39 | #3E8EED
40 | #72ACF1
41 | #A7CBF6
42 |
43 |
44 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/App.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/App.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace ComboBoxEditor {
2 | public partial class App : Application {
3 | public App() {
4 | InitializeComponent();
5 |
6 | MainPage = new AppShell();
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/AppShell.xaml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/AppShell.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace ComboBoxEditor {
2 | public partial class AppShell : Shell {
3 | public AppShell() {
4 | InitializeComponent();
5 | }
6 | }
7 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/ComboBoxEditor.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | net9.0-android;net9.0-ios
4 | Exe
5 | ComboBoxEditor
6 | true
7 | true
8 | enable
9 |
10 | ComboBoxEditor
11 |
12 | com.companyname.comboboxeditor
13 | 5E4C25B2-5E55-4189-8F58-358398DC69BB
14 |
15 | 1.0
16 | 1
17 | 14.2
18 | 21.0
19 | 9.0.10
20 |
21 |
22 | false
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/ComboBoxEditor.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 25.0.1705.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ComboBoxEditor", "ComboBoxEditor.csproj", "{816A1273-D3E4-43B3-94CD-5FDCED7EB8A8}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {816A1273-D3E4-43B3-94CD-5FDCED7EB8A8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {816A1273-D3E4-43B3-94CD-5FDCED7EB8A8}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {816A1273-D3E4-43B3-94CD-5FDCED7EB8A8}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
17 | {816A1273-D3E4-43B3-94CD-5FDCED7EB8A8}.Release|Any CPU.ActiveCfg = Release|Any CPU
18 | {816A1273-D3E4-43B3-94CD-5FDCED7EB8A8}.Release|Any CPU.Build.0 = Release|Any CPU
19 | {816A1273-D3E4-43B3-94CD-5FDCED7EB8A8}.Release|Any CPU.Deploy.0 = Release|Any CPU
20 | EndGlobalSection
21 | GlobalSection(SolutionProperties) = preSolution
22 | HideSolutionNode = FALSE
23 | EndGlobalSection
24 | GlobalSection(ExtensibilityGlobals) = postSolution
25 | SolutionGuid = {F54B7E77-609E-47B1-97FE-FB989F24C324}
26 | EndGlobalSection
27 | EndGlobal
28 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/MainPage.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/MainPage.xaml.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui.DataForm;
2 | using System.Collections;
3 |
4 | namespace ComboBoxEditor {
5 | public class DepartmentInfo {
6 | public int DepartmentCode { get; set; }
7 | public string DepartmentName { get; set; }
8 |
9 | public DepartmentInfo(int code, string name) {
10 | DepartmentCode = code;
11 | DepartmentName = name;
12 | }
13 | }
14 |
15 | public class EmployeeInfo {
16 | public string FirstName { get; set; }
17 | public string LastName { get; set; }
18 |
19 | [DataFormComboBoxEditor(ValueMember = "DepartmentCode", DisplayMember = "DepartmentName")]
20 | public int Department { get; set; }
21 |
22 | [DataFormComboBoxEditor]
23 | public string Status { get; set; }
24 | }
25 |
26 | public class ComboBoxDataProvider : IPickerSourceProvider {
27 | public IEnumerable GetSource(string propertyName) {
28 | if (propertyName == "Department") {
29 | return new List() {
30 | new DepartmentInfo(0, "Sales"),
31 | new DepartmentInfo(1, "Support"),
32 | new DepartmentInfo(2, "Shipping"),
33 | new DepartmentInfo(3, "Engineering"),
34 | new DepartmentInfo(4, "Human Resources"),
35 | new DepartmentInfo(5, "Management"),
36 | new DepartmentInfo(6, "IT")
37 | };
38 | }
39 | if (propertyName == "Status") {
40 | return new List() {
41 | "Salaried",
42 | "Commission",
43 | "Terminated",
44 | "On Leave"
45 | };
46 | }
47 | return null;
48 | }
49 | }
50 | public partial class MainPage : ContentPage {
51 |
52 | public MainPage() {
53 | InitializeComponent();
54 | dataForm.DataObject = new EmployeeInfo();
55 | dataForm.PickerSourceProvider = new ComboBoxDataProvider();
56 | }
57 | }
58 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/MauiProgram.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui;
2 |
3 | namespace ComboBoxEditor {
4 | public static class MauiProgram {
5 | public static MauiApp CreateMauiApp() {
6 | var builder = MauiApp.CreateBuilder();
7 | builder
8 | .UseMauiApp()
9 | .UseDevExpress()
10 | .UseDevExpressCollectionView()
11 | .UseDevExpressControls()
12 | .UseDevExpressEditors()
13 | .ConfigureFonts(fonts => {
14 | fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
15 | fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
16 | });
17 |
18 | return builder.Build();
19 | }
20 | }
21 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Platforms/Android/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Platforms/Android/MainActivity.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Content.PM;
3 | using Android.OS;
4 |
5 | namespace ComboBoxEditor {
6 | [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
7 | public class MainActivity : MauiAppCompatActivity {
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Platforms/Android/MainApplication.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Runtime;
3 |
4 | namespace ComboBoxEditor {
5 | [Application]
6 | public class MainApplication : MauiApplication {
7 | public MainApplication(IntPtr handle, JniHandleOwnership ownership)
8 | : base(handle, ownership) {
9 | }
10 |
11 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Platforms/Android/Resources/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #512BD4
4 | #2B0B98
5 | #2B0B98
6 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Platforms/iOS/AppDelegate.cs:
--------------------------------------------------------------------------------
1 | using Foundation;
2 |
3 | namespace ComboBoxEditor {
4 | [Register("AppDelegate")]
5 | public class AppDelegate : MauiUIApplicationDelegate {
6 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
7 | }
8 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Platforms/iOS/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | LSRequiresIPhoneOS
6 |
7 | UIDeviceFamily
8 |
9 | 1
10 | 2
11 |
12 | UIRequiredDeviceCapabilities
13 |
14 | arm64
15 |
16 | UISupportedInterfaceOrientations
17 |
18 | UIInterfaceOrientationPortrait
19 | UIInterfaceOrientationLandscapeLeft
20 | UIInterfaceOrientationLandscapeRight
21 |
22 | UISupportedInterfaceOrientations~ipad
23 |
24 | UIInterfaceOrientationPortrait
25 | UIInterfaceOrientationPortraitUpsideDown
26 | UIInterfaceOrientationLandscapeLeft
27 | UIInterfaceOrientationLandscapeRight
28 |
29 | XSAppIconAssets
30 | Assets.xcassets/appicon.appiconset
31 |
32 |
33 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Platforms/iOS/Program.cs:
--------------------------------------------------------------------------------
1 | using ObjCRuntime;
2 | using UIKit;
3 |
4 | namespace ComboBoxEditor {
5 | public class Program {
6 | // This is the main entry point of the application.
7 | static void Main(string[] args) {
8 | // if you want to use a different Application Delegate class from "AppDelegate"
9 | // you can specify it here.
10 | UIApplication.Main(args, null, typeof(AppDelegate));
11 | }
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Readme.md:
--------------------------------------------------------------------------------
1 | # DevExpress Data Form for .NET MAUI - Add a ComboBoxEdit
2 |
3 | This example shows how to display a [ComboBoxEdit](https://docs.devexpress.com/Maui/DevExpress.Maui.Editors.ComboBoxEdit) in the [DataFormView](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.DataFormView) control.
4 |
5 | The [DataFormView](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.DataFormView) generates [ComboBoxEdit](https://docs.devexpress.com/Maui/DevExpress.Maui.Editors.ComboBoxEdit) editors for the underlying data object's properties of the *enum* type. You can also bind a combo box editor to a collection that stores objects of any type - for example, primitive types (strings, integers, etc.) or custom objects.
6 |
7 |
8 |
9 |
10 | To specify an item source for the data form's combo box editor, follow the steps below:
11 |
12 | 1. Create a class that implements the [](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.IPickerSourceProvider) interface. An instance of this class (*ComboBoxDataProvider*, in this example) serves as the data source for all combo box editors within the data form.
13 | 2. Override the [GetSource](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.IPickerSourceProvider.GetSource(System.String)) method so that it returns an item source for a combo box based on the data object property to which the editor is bound.
14 | 3. Set the [DataFormView.PickerSourceProvider](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.DataFormView.PickerSourceProvider) property to a *ComboBoxDataProvider* class instance.
15 | 4. Use the [](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.DataFormComboBoxEditorAttribute) attribute to assign a combo box editor to the data object's property.
16 | In this example, the data form is bound to the *EmployeeInfo* object and uses combo box editors for the following properties of this object:
17 | - *Department*
18 | The data provider's `GetSource` method returns a list of `DepartmentInfo` objects that serve as the data source for the drop-down item list of the **Department** combo box. Use the [ValueMember](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.DataFormComboBoxEditorAttribute.ValueMember) and [](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.DataFormComboBoxEditorAttribute.DisplayMember) parameters to specify data source field names that supply item values (integer values that define department codes) and display strings (department names), respectively.
19 | - *Status*
20 | The data provider's `GetSource` method returns a list of strings that are displayed as items within the **Status** combo box and used to set the data object's *Status* property value.
21 |
22 | ## Files to Review
23 |
24 | * [MainPage.xaml](MainPage.xaml)
25 | * [MainPage.xaml.cs](MainPage.xaml.cs)
26 |
27 | ## Documentation
28 |
29 | * [Customize .NET MAUI Control Appearance](https://docs.devexpress.com/MAUI/404147/customize-appearance)
30 | * [Customize Layout and Appearance in DevExpress Data Form for .NET MAUI](https://docs.devexpress.com/MAUI/403649/data-form/layout-and-appearance)
31 |
32 | ## More Examples
33 |
34 | * [Get Started with the DataForm](../DataFormGetStarted)
35 | * [Customize a DataFrom Appearance](../CustomAppearance)
36 | * [Add/Remove Data Editors at Runtime](../AddingDataEditorsAtRuntime)
37 |
38 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/AppIcon/appicon.svg:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/AppIcon/appiconfg.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/Fonts/OpenSans-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/ComboBoxEditor/Resources/Fonts/OpenSans-Regular.ttf
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/Fonts/OpenSans-Semibold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/ComboBoxEditor/Resources/Fonts/OpenSans-Semibold.ttf
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/Images/dotnet_bot.svg:
--------------------------------------------------------------------------------
1 |
94 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/Raw/AboutAssets.txt:
--------------------------------------------------------------------------------
1 | Any raw assets you want to be deployed with your application can be placed in
2 | this directory (and child directories). Deployment of the asset to your application
3 | is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
4 |
5 |
6 |
7 | These files will be deployed with you package and will be accessible using Essentials:
8 |
9 | async Task LoadMauiAsset()
10 | {
11 | using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
12 | using var reader = new StreamReader(stream);
13 |
14 | var contents = reader.ReadToEnd();
15 | }
16 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/Splash/splash.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/CS/ComboBoxEditor/Resources/Styles/Colors.xaml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | #512BD4
7 | #DFD8F7
8 | #2B0B98
9 | White
10 | Black
11 | #E1E1E1
12 | #C8C8C8
13 | #ACACAC
14 | #919191
15 | #6E6E6E
16 | #404040
17 | #212121
18 | #141414
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 | #F7B548
34 | #FFD590
35 | #FFE5B9
36 | #28C2D1
37 | #7BDDEF
38 | #C3F2F4
39 | #3E8EED
40 | #72ACF1
41 | #A7CBF6
42 |
43 |
44 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/App.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/App.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace CustomAppearance {
2 | public partial class App : Application {
3 | public App() {
4 | InitializeComponent();
5 |
6 | MainPage = new AppShell();
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/AppShell.xaml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/AppShell.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace CustomAppearance {
2 | public partial class AppShell : Shell {
3 | public AppShell() {
4 | InitializeComponent();
5 | }
6 | }
7 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/CustomAppearance.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | net9.0-android;net9.0-ios
4 | Exe
5 | CustomAppearance
6 | true
7 | true
8 | enable
9 |
10 | CustomAppearance
11 |
12 | com.companyname.customappearance
13 | 7D2BB93C-5B45-4519-BC3C-1045CEFA6896
14 |
15 | 1.0
16 | 1
17 | 14.2
18 | 21.0
19 | 9.0.10
20 |
21 |
22 | false
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/CustomAppearance.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 25.0.1705.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CustomAppearance", "CustomAppearance.csproj", "{9053BB09-9C58-44F8-9391-33789A8B7B41}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {9053BB09-9C58-44F8-9391-33789A8B7B41}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {9053BB09-9C58-44F8-9391-33789A8B7B41}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {9053BB09-9C58-44F8-9391-33789A8B7B41}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
17 | {9053BB09-9C58-44F8-9391-33789A8B7B41}.Release|Any CPU.ActiveCfg = Release|Any CPU
18 | {9053BB09-9C58-44F8-9391-33789A8B7B41}.Release|Any CPU.Build.0 = Release|Any CPU
19 | {9053BB09-9C58-44F8-9391-33789A8B7B41}.Release|Any CPU.Deploy.0 = Release|Any CPU
20 | EndGlobalSection
21 | GlobalSection(SolutionProperties) = preSolution
22 | HideSolutionNode = FALSE
23 | EndGlobalSection
24 | GlobalSection(ExtensibilityGlobals) = postSolution
25 | SolutionGuid = {DB22A332-32BD-45AE-9F42-497B72BFC19E}
26 | EndGlobalSection
27 | EndGlobal
28 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/EmployeeInfo.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui.DataForm;
2 | using System;
3 | using System.Collections.Generic;
4 | using System.Linq;
5 | using System.Text;
6 | using System.Threading.Tasks;
7 |
8 | namespace CustomAppearance {
9 | public class EmployeeInfo {
10 | public string PhotoPath { get; set; }
11 |
12 | [DataFormTextEditor(Placeholder = "First Name")]
13 | [DataFormDisplayOptions(GroupName = "Name")]
14 | public string FirstName { get; set; }
15 |
16 | [DataFormTextEditor(Placeholder = "Last Name")]
17 | [DataFormDisplayOptions(GroupName = "Name")]
18 | public string LastName { get; set; }
19 |
20 | [DataFormTextEditor(Placeholder = "Email")]
21 | [DataFormDisplayOptions(GroupName = "Email & Phone")]
22 | public string Email { get; set; }
23 |
24 | [DataFormMaskedEditor(Mask = "+1 (000) 000-0000", Keyboard = "Telephone", Placeholder = "Phone")]
25 | [DataFormDisplayOptions(GroupName = "Email & Phone")]
26 | public string Phone { get; set; }
27 |
28 | [DataFormTextEditor(Placeholder = "Address")]
29 | [DataFormDisplayOptions(GroupName = "Address")]
30 | public string Address { get; set; }
31 |
32 | [DataFormTextEditor(Placeholder = "City")]
33 | [DataFormDisplayOptions(GroupName = "Address")]
34 | public string City { get; set; }
35 |
36 | [DataFormTextEditor(Placeholder = "State")]
37 | [DataFormDisplayOptions(GroupName = "Address")]
38 | public string State { get; set; }
39 |
40 | [DataFormMaskedEditor(Mask = "00000", Keyboard = "Numeric", Placeholder = "Zip")]
41 | [DataFormDisplayOptions(GroupName = "Address")]
42 | public string Zip { get; set; }
43 |
44 | [DataFormComboBoxEditor(Placeholder = "Department", IsFilterEnabled = true)]
45 | [DataFormDisplayOptions(GroupName = "Employment Data")]
46 | public DepartmentType Department { get; set; } = DepartmentType.Sales;
47 |
48 | [DataFormTextEditor(Placeholder = "Position")]
49 | [DataFormDisplayOptions(GroupName = "Employment Data")]
50 | public string Position { get; set; }
51 |
52 | [DataFormDateEditor]
53 | [DataFormDisplayOptions(GroupName = "Employment Data")]
54 | public DateTime HiredAt { get; set; } = DateTime.Now;
55 |
56 | [DataFormMultilineEditor(Placeholder = "Notes")]
57 | [DataFormDisplayOptions(GroupName = "Employment Data")]
58 | public string Notes { get; set; }
59 | }
60 |
61 | public enum DepartmentType {
62 | Sales,
63 | Support,
64 | Shipping,
65 | Engineering,
66 | Management,
67 | IT
68 | }
69 | }
70 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/EmployeeRepository.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 |
7 | namespace CustomAppearance {
8 | class EmployeeRepository {
9 | public EmployeeInfo Get(int id) {
10 | return new EmployeeInfo {
11 | FirstName = "Steven",
12 | LastName = "Buchanan",
13 | PhotoPath = "steven_buchanan",
14 | Email = "steven.buchanan@dxdemo.com",
15 | Phone = "5556070691",
16 | Address = "351 S Hill St.",
17 | City = "Los Angeles",
18 | State = "CA",
19 | Zip = "90013",
20 | Department = DepartmentType.Engineering,
21 | Position = "Engineer",
22 | HiredAt = new DateTime(2017, 6, 2)
23 | };
24 | }
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/MainPage.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
10 |
11 |
12 |
22 |
23 |
24 |
31 |
34 |
35 |
36 |
37 |
38 |
39 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/MainPage.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace CustomAppearance {
2 | public partial class MainPage : ContentPage {
3 | EmployeeRepository repository = new EmployeeRepository();
4 | public MainPage() {
5 | InitializeComponent();
6 | dataForm.DataObject = repository.Get(0);
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/MauiProgram.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui;
2 |
3 | namespace CustomAppearance {
4 | public static class MauiProgram {
5 | public static MauiApp CreateMauiApp() {
6 | var builder = MauiApp.CreateBuilder();
7 | builder
8 | .UseMauiApp()
9 | .UseDevExpress()
10 | .UseDevExpressCollectionView()
11 | .UseDevExpressControls()
12 | .UseDevExpressEditors()
13 | .ConfigureFonts(fonts => {
14 | fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
15 | fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
16 | });
17 |
18 | return builder.Build();
19 | }
20 | }
21 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/Platforms/Android/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Platforms/Android/MainActivity.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Content.PM;
3 | using Android.OS;
4 |
5 | namespace CustomAppearance {
6 | [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
7 | public class MainActivity : MauiAppCompatActivity {
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/Platforms/Android/MainApplication.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Runtime;
3 |
4 | namespace CustomAppearance {
5 | [Application]
6 | public class MainApplication : MauiApplication {
7 | public MainApplication(IntPtr handle, JniHandleOwnership ownership)
8 | : base(handle, ownership) {
9 | }
10 |
11 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/Platforms/Android/Resources/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #512BD4
4 | #2B0B98
5 | #2B0B98
6 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Platforms/iOS/AppDelegate.cs:
--------------------------------------------------------------------------------
1 | using Foundation;
2 |
3 | namespace CustomAppearance {
4 | [Register("AppDelegate")]
5 | public class AppDelegate : MauiUIApplicationDelegate {
6 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
7 | }
8 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/Platforms/iOS/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | LSRequiresIPhoneOS
6 |
7 | UIDeviceFamily
8 |
9 | 1
10 | 2
11 |
12 | UIRequiredDeviceCapabilities
13 |
14 | arm64
15 |
16 | UISupportedInterfaceOrientations
17 |
18 | UIInterfaceOrientationPortrait
19 | UIInterfaceOrientationLandscapeLeft
20 | UIInterfaceOrientationLandscapeRight
21 |
22 | UISupportedInterfaceOrientations~ipad
23 |
24 | UIInterfaceOrientationPortrait
25 | UIInterfaceOrientationPortraitUpsideDown
26 | UIInterfaceOrientationLandscapeLeft
27 | UIInterfaceOrientationLandscapeRight
28 |
29 | XSAppIconAssets
30 | Assets.xcassets/appicon.appiconset
31 |
32 |
33 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Platforms/iOS/Program.cs:
--------------------------------------------------------------------------------
1 | using ObjCRuntime;
2 | using UIKit;
3 |
4 | namespace CustomAppearance {
5 | public class Program {
6 | // This is the main entry point of the application.
7 | static void Main(string[] args) {
8 | // if you want to use a different Application Delegate class from "AppDelegate"
9 | // you can specify it here.
10 | UIApplication.Main(args, null, typeof(AppDelegate));
11 | }
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/CustomAppearance/Readme.md:
--------------------------------------------------------------------------------
1 | # DevExpress Data Form for .NET MAUI - Customize Appearance
2 |
3 | This example describes how to customze the appearance of the Data Form and its items.
4 |
5 | You can customize the data form's appearance in the following ways:
6 | - Use [implicit styles](https://docs.devexpress.com/MAUI/404147/customize-appearance#use-implicit-styles-for-centralized-style-management) to modify the appearance of all data form and editor instances that use these resources.
7 | - Use [DataFormView](https://docs.devexpress.com/Maui/DevExpress.Maui.DataForm.DataFormView) object properties to customize a specific data form instance.
8 |
9 |
10 |
11 |
12 | ## Files to Review
13 |
14 | * [MainPage.xaml](MainPage.xaml)
15 | * [MainPage.xaml.cs](MainPage.xaml.cs)
16 | * [EmployeeInfo.cs](EmployeeInfo.cs)
17 |
18 | ## More Examples
19 |
20 | * [Get Started with the DataForm](../DataFormGetStarted)
21 | * [Display a ComboBoxEdit in the DataForm](../ComboBoxEditor)
22 | * [Add/Remove Data Editors at Runtime](../AddingDataEditorsAtRuntime)
23 |
24 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/AppIcon/appicon.svg:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/AppIcon/appiconfg.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/Fonts/OpenSans-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/CustomAppearance/Resources/Fonts/OpenSans-Regular.ttf
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/Fonts/OpenSans-Semibold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/CustomAppearance/Resources/Fonts/OpenSans-Semibold.ttf
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/Images/steven_buchanan.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/CustomAppearance/Resources/Images/steven_buchanan.jpg
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/Raw/AboutAssets.txt:
--------------------------------------------------------------------------------
1 | Any raw assets you want to be deployed with your application can be placed in
2 | this directory (and child directories). Deployment of the asset to your application
3 | is automatically handled by the following `MauiAsset` Build Action within your `.csproj`.
4 |
5 |
6 |
7 | These files will be deployed with you package and will be accessible using Essentials:
8 |
9 | async Task LoadMauiAsset()
10 | {
11 | using var stream = await FileSystem.OpenAppPackageFileAsync("AboutAssets.txt");
12 | using var reader = new StreamReader(stream);
13 |
14 | var contents = reader.ReadToEnd();
15 | }
16 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/Splash/splash.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/CS/CustomAppearance/Resources/Styles/Colors.xaml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 | #512BD4
7 | #DFD8F7
8 | #2B0B98
9 | White
10 | Black
11 | #E1E1E1
12 | #C8C8C8
13 | #ACACAC
14 | #919191
15 | #6E6E6E
16 | #404040
17 | #212121
18 | #141414
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 | #F7B548
34 | #FFD590
35 | #FFE5B9
36 | #28C2D1
37 | #7BDDEF
38 | #C3F2F4
39 | #3E8EED
40 | #72ACF1
41 | #A7CBF6
42 |
43 |
44 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/App.xaml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
9 |
10 | #512bdf
11 | White
12 |
13 |
17 |
18 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/App.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace DataFormGetStarted
2 | {
3 | public partial class App : Application
4 | {
5 | public App()
6 | {
7 | InitializeComponent();
8 |
9 | MainPage = new MainPage();
10 | }
11 | }
12 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/DataFormGetStarted.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | net9.0-android;net9.0-ios
4 | Exe
5 | true
6 | enable
7 | true
8 | DataFormGetStarted
9 |
10 | DataFormGetStarted
11 |
12 | com.companyname.DataFormGetStarted
13 | 6B8AB780-F9B7-41AC-9123-9FA501528C67
14 |
15 | 1.0
16 | 1
17 | 14.2
18 | 21.0
19 | 9.0.10
20 |
21 |
22 | false
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/DataFormGetStarted.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 16
4 | VisualStudioVersion = 25.0.1705.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DataFormGetStarted", "DataFormGetStarted.csproj", "{3879768A-8623-4793-B936-4483CB722511}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {3879768A-8623-4793-B936-4483CB722511}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15 | {3879768A-8623-4793-B936-4483CB722511}.Debug|Any CPU.Build.0 = Debug|Any CPU
16 | {3879768A-8623-4793-B936-4483CB722511}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
17 | {3879768A-8623-4793-B936-4483CB722511}.Release|Any CPU.ActiveCfg = Release|Any CPU
18 | {3879768A-8623-4793-B936-4483CB722511}.Release|Any CPU.Build.0 = Release|Any CPU
19 | {3879768A-8623-4793-B936-4483CB722511}.Release|Any CPU.Deploy.0 = Release|Any CPU
20 | EndGlobalSection
21 | GlobalSection(SolutionProperties) = preSolution
22 | HideSolutionNode = FALSE
23 | EndGlobalSection
24 | GlobalSection(ExtensibilityGlobals) = postSolution
25 | SolutionGuid = {5558800E-2B13-4581-B3D2-1CE0443BFBAD}
26 | EndGlobalSection
27 | EndGlobal
28 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/GettingStarted.txt:
--------------------------------------------------------------------------------
1 | Welcome to DevExpress Components for .NET MAUI! Here are a few tips to help you get started with your new application.
2 |
3 | DevExpress NuGet Feed
4 | ---------------------
5 |
6 | DevExpress Components for .NET MAUI are free-of-charge. To learn more about our free offer and reserve your free copy,
7 | please visit the following webpage: https://www.devexpress.com/xamarin-free/
8 |
9 | IMPORTANT: You MUST register your personal NuGet package source for the solution to build correctly.
10 | After you reserved your free copy, you can use the following page to obtain a NuGet Feed URL: https://nuget.devexpress.com/
11 |
12 | If you are unfamiliar with NuGet packages, please review the following
13 | help topic (Install DevExpress Controls Using NuGet Packages): https://docs.devexpress.com/GeneralInformation/115912/
14 |
15 | QuickStart Guide
16 | ----------------
17 |
18 | See the following topic to learn more about DevExpress Components for .NET MAUI: https://docs.devexpress.com/MAUI
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/MainPage.xaml:
--------------------------------------------------------------------------------
1 |
8 |
9 |
10 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/MainPage.xaml.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui.DataForm;
2 |
3 | namespace DataFormGetStarted
4 | {
5 | public partial class MainPage : ContentPage
6 | {
7 | public MainPage()
8 | {
9 | InitializeComponent();
10 | dataform.DataObject = new PersonalInfo();
11 | }
12 |
13 | }
14 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/MauiProgram.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui;
2 | using Microsoft.Maui;
3 | using Microsoft.Maui.Controls.Compatibility;
4 | using Microsoft.Maui.Controls.Compatibility.Hosting;
5 | using Microsoft.Maui.Controls.Hosting;
6 | using Microsoft.Maui.Hosting;
7 |
8 | namespace DataFormGetStarted
9 | {
10 | public static class MauiProgram
11 | {
12 | public static MauiApp CreateMauiApp()
13 | {
14 | var builder = MauiApp.CreateBuilder();
15 | builder
16 | .UseMauiApp()
17 | .UseDevExpress()
18 | .UseDevExpressCollectionView()
19 | .UseDevExpressControls()
20 | .UseDevExpressEditors()
21 | .ConfigureFonts(fonts =>
22 | {
23 | fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
24 | fonts.AddFont("univia-pro-regular.ttf", "Univia-Pro");
25 | fonts.AddFont("roboto-bold.ttf", "Roboto-Bold");
26 | fonts.AddFont("roboto-regular.ttf", "Roboto");
27 | })
28 | .UseMauiCompatibility();
29 |
30 | return builder.Build();
31 | }
32 | }
33 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/PersonalInfo.cs:
--------------------------------------------------------------------------------
1 | using DevExpress.Maui.DataForm;
2 | using System;
3 | using System.Collections.Generic;
4 | using System.ComponentModel.DataAnnotations;
5 | using System.Linq;
6 | using System.Text;
7 | using System.Threading.Tasks;
8 |
9 | namespace DataFormGetStarted
10 | {
11 | public class PersonalInfo
12 | {
13 | [DataFormItemPosition(RowOrder = 1, ItemOrderInRow = 1)]
14 | [DataFormTextEditor(InplaceLabelText = "First Name")]
15 | [DataFormDisplayOptions(LabelIcon = "person_outline", GroupName = "Profile")]
16 | public string FirstName { get; set; }
17 |
18 | [DataFormItemPosition(RowOrder = 1, ItemOrderInRow = 2)]
19 | [DataFormTextEditor(InplaceLabelText = "Last Name")]
20 | [DataFormDisplayOptions(IsLabelVisible = false, GroupName = "Profile")]
21 | public string LastName { get; set; }
22 |
23 | [DataFormDisplayOptions(GroupName = "Profile")]
24 | public DateTime? BirthDate { get; set; }
25 |
26 | [DataFormDisplayOptions(GroupName = "Profile")]
27 | public virtual Gender Gender { get; set; }
28 |
29 | [DataFormPasswordEditor]
30 | [DataFormDisplayOptions(GroupName = "Profile")]
31 | [StringLength(64, MinimumLength = 8,
32 | ErrorMessage = "The password should contain at least 8 characters.")]
33 | [Required(ErrorMessage = "Required")]
34 | public string Password { get; set; }
35 |
36 | [DataFormDisplayOptions(GroupName = "Contact Info")]
37 | public string Email { get; set; }
38 |
39 | [DataFormMaskedEditor(Mask = "+0 (000) 000-0000", Keyboard = "Telephone")]
40 | [DataFormDisplayOptions(GroupName = "Contact Info")]
41 | [DataFormItemPosition(RowOrder = 1)]
42 | public string Phone { get; set; }
43 |
44 | [DataFormDisplayOptions(LabelText = "Subscribe to Newsletters", LabelMinWidth = 200, GroupName = "Contact Info")]
45 | public bool Newsletters { get; set; }
46 | }
47 | public enum Gender { Female, Male, RatherNotSay }
48 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/Android/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/Android/MainActivity.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Content.PM;
3 | using Android.OS;
4 |
5 | namespace DataFormGetStarted
6 | {
7 | [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize)]
8 | public class MainActivity : MauiAppCompatActivity
9 | {
10 | protected override void OnCreate(Bundle savedInstanceState)
11 | {
12 | base.OnCreate(savedInstanceState);
13 | Platform.Init(this, savedInstanceState);
14 | }
15 |
16 | protected override void OnResume()
17 | {
18 | base.OnResume();
19 |
20 | Platform.OnResume(this);
21 | }
22 |
23 | protected override void OnNewIntent(Android.Content.Intent intent)
24 | {
25 | base.OnNewIntent(intent);
26 |
27 | Platform.OnNewIntent(intent);
28 | }
29 |
30 | public override void OnRequestPermissionsResult(int requestCode, string[] permissions, Permission[] grantResults)
31 | {
32 | Platform.OnRequestPermissionsResult(requestCode, permissions, grantResults);
33 |
34 | base.OnRequestPermissionsResult(requestCode, permissions, grantResults);
35 | }
36 | }
37 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/Android/MainApplication.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Runtime;
3 |
4 | namespace DataFormGetStarted
5 | {
6 | [Application]
7 | public class MainApplication : MauiApplication
8 | {
9 | public MainApplication(IntPtr handle, JniHandleOwnership ownership)
10 | : base(handle, ownership)
11 | {
12 | }
13 |
14 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
15 | }
16 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/Android/Resources/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #512BD4
4 | #2B0B98
5 | #2B0B98
6 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/Android/Resources/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/iOS/AppDelegate.cs:
--------------------------------------------------------------------------------
1 | using Foundation;
2 |
3 | namespace DataFormGetStarted
4 | {
5 | [Register("AppDelegate")]
6 | public class AppDelegate : MauiUIApplicationDelegate
7 | {
8 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
9 | }
10 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/iOS/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | LSRequiresIPhoneOS
6 |
7 | UIDeviceFamily
8 |
9 | 1
10 | 2
11 |
12 | UIRequiredDeviceCapabilities
13 |
14 | arm64
15 |
16 | UISupportedInterfaceOrientations
17 |
18 | UIInterfaceOrientationPortrait
19 | UIInterfaceOrientationLandscapeLeft
20 | UIInterfaceOrientationLandscapeRight
21 |
22 | UISupportedInterfaceOrientations~ipad
23 |
24 | UIInterfaceOrientationPortrait
25 | UIInterfaceOrientationPortraitUpsideDown
26 | UIInterfaceOrientationLandscapeLeft
27 | UIInterfaceOrientationLandscapeRight
28 |
29 | XSAppIconAssets
30 | Assets.xcassets/appicon.appiconset
31 |
32 |
33 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/iOS/Program.cs:
--------------------------------------------------------------------------------
1 | using ObjCRuntime;
2 | using UIKit;
3 |
4 | namespace DataFormGetStarted
5 | {
6 | public class Program
7 | {
8 | // This is the main entry point of the application.
9 | static void Main(string[] args)
10 | {
11 | // if you want to use a different Application Delegate class from "AppDelegate"
12 | // you can specify it here.
13 | UIApplication.Main(args, null, typeof(AppDelegate));
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Platforms/iOS/Resources/LaunchScreen.xib:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
21 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Readme.md:
--------------------------------------------------------------------------------
1 | # DevExpress Data Form for .NET MAUI - Get Started
2 |
3 | This example shows how to get started with the DataForm Control for .NET MAUI.
4 |
5 |
6 |
7 | You can also refer to the following YouTube video for instructions on how to get started with the Data Form Control: [Adding a Data Form to Your .NET MAUI App](https://www.youtube.com/watch?v=imUCmru5Lwc&ab_channel=DevExpress).
8 |
9 | ## Files to Review
10 |
11 | * [MainPage.xaml](MainPage.xaml)
12 | * [MainPage.xaml.cs](MainPage.xaml.cs)
13 |
14 | ## Documentation
15 |
16 | * [Get Started with DevExpress Data Form for .NET MAUI](https://docs.devexpress.com/MAUI/403647/data-form/get-started)
17 | * [DataForm.DataFormView](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormView)
18 |
19 | ## More Examples
20 |
21 | * [Display a ComboBoxEdit in the DataForm](../ComboBoxEditor)
22 | * [Customize a DataFrom Appearance](../CustomAppearance)
23 | * [Add/Remove Data Editors at Runtime](../AddingDataEditorsAtRuntime)
24 |
25 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Fonts/OpenSans-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/DataFormGetStarted/Resources/Fonts/OpenSans-Regular.ttf
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Fonts/roboto-bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/DataFormGetStarted/Resources/Fonts/roboto-bold.ttf
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Fonts/roboto-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/DataFormGetStarted/Resources/Fonts/roboto-regular.ttf
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Fonts/univia-pro-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/DataFormGetStarted/Resources/Fonts/univia-pro-regular.ttf
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Images/background.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
118 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Images/name.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/DataFormGetStarted/Resources/Images/name.png
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Images/person_outline.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/Images/xamarin_logo.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
15 |
--------------------------------------------------------------------------------
/CS/DataFormGetStarted/Resources/appicon.svg:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/CS/EditFormExample/App.xaml:
--------------------------------------------------------------------------------
1 |
7 |
8 | #6750A4
9 | #D0BCFF
10 | #DFD8F7
11 | #2B0B98
12 | White
13 | Black
14 | #0D1B32
15 | #0D1B32
16 | #F2F2F7
17 | #E1E1E1
18 | #C8C8C8
19 | #ACACAC
20 | #919191
21 | #6E6E6E
22 | #404040
23 | #212121
24 | #141414
25 | #1D192B
26 | #1C1B1F
27 |
28 |
31 |
36 |
37 |
38 |
--------------------------------------------------------------------------------
/CS/EditFormExample/App.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace EditFormExample {
2 | public partial class App : Application {
3 | public App() {
4 | InitializeComponent();
5 |
6 | MainPage = new AppShell();
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/AppShell.xaml:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/CS/EditFormExample/AppShell.xaml.cs:
--------------------------------------------------------------------------------
1 | namespace EditFormExample;
2 |
3 | public partial class AppShell : Shell {
4 | public AppShell()
5 | {
6 | InitializeComponent();
7 | }
8 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/Customer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.ComponentModel.DataAnnotations.Schema;
4 | using System.ComponentModel.DataAnnotations;
5 | using System.Diagnostics.CodeAnalysis;
6 | using System.Linq;
7 | using System.Text;
8 | using System.Threading.Tasks;
9 | using System.ComponentModel;
10 | using System.Runtime.CompilerServices;
11 |
12 | namespace EditFormExample {
13 | [Table("Customers")]
14 | public class Customer : BindableBase {
15 | int? id;
16 | string firstName;
17 | string lastName;
18 | string company;
19 | string address;
20 | string city;
21 | string state;
22 | string email;
23 | int zipcode;
24 | string phone;
25 | string photoPath;
26 |
27 |
28 | public int? ID {
29 | get {
30 | return id;
31 | }
32 | set {
33 | id = value;
34 | RaisePropertyChanged();
35 | }
36 | }
37 |
38 | [Required(ErrorMessage = "First Name cannot be empty")]
39 | public string FirstName {
40 | get {
41 | return firstName;
42 | }
43 | set {
44 | firstName = value;
45 | RaisePropertyChanged();
46 | }
47 | }
48 | [Required(ErrorMessage = "Last Name cannot be empty")]
49 | public string LastName {
50 | get {
51 | return lastName;
52 | }
53 | set {
54 | lastName = value;
55 | RaisePropertyChanged();
56 | }
57 | }
58 | public string Company {
59 | get {
60 | return company;
61 | }
62 | set {
63 | company = value;
64 | RaisePropertyChanged();
65 | }
66 | }
67 | public string Address {
68 | get {
69 | return address;
70 | }
71 | set {
72 | address = value;
73 | RaisePropertyChanged();
74 | }
75 | }
76 | public string City {
77 | get {
78 | return city;
79 | }
80 | set {
81 | city = value;
82 | RaisePropertyChanged();
83 | }
84 | }
85 | public string State {
86 | get {
87 | return state;
88 | }
89 | set {
90 | state = value;
91 | RaisePropertyChanged();
92 | }
93 | }
94 | public int ZipCode {
95 | get {
96 | return zipcode;
97 | }
98 | set {
99 | zipcode = value;
100 | RaisePropertyChanged();
101 | }
102 | }
103 | public string Phone {
104 | get {
105 | return phone;
106 | }
107 | set {
108 | phone = value;
109 | RaisePropertyChanged();
110 | }
111 | }
112 |
113 | public string Email {
114 | get {
115 | return email;
116 | }
117 | set {
118 | email = value;
119 | RaisePropertyChanged();
120 | }
121 | }
122 |
123 | public string PhotoPath {
124 | get {
125 | return photoPath;
126 | }
127 | set {
128 | photoPath = value;
129 | RaisePropertyChanged();
130 | }
131 | }
132 | }
133 | public class BindableBase : INotifyPropertyChanged {
134 | public event PropertyChangedEventHandler PropertyChanged;
135 | public void RaisePropertyChanged([CallerMemberName] string propertyName = "") {
136 | PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
137 | }
138 | }
139 | }
140 |
--------------------------------------------------------------------------------
/CS/EditFormExample/EditFormExample.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | net9.0-ios;net9.0-android
4 | Exe
5 | true
6 | enable
7 | true
8 | EditFormExample
9 |
10 | Edit Form
11 |
12 | com.companyname.EditForm
13 | 0312D68B-8F21-46C8-B693-AF54F1BC8E18
14 |
15 | 1.0
16 | 1
17 | 14.2
18 | 21.0
19 | True
20 | 9.0.10
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 | MSBuild:Compile
43 |
44 |
45 |
--------------------------------------------------------------------------------
/CS/EditFormExample/EditFormExample.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 17
4 | VisualStudioVersion = 17.0.31903.59
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EditFormExample", "EditFormExample.csproj", "{8E699DB8-1EB6-45D2-8590-FF529BFD13FC}"
7 | EndProject
8 | Global
9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
10 | Debug|Any CPU = Debug|Any CPU
11 | Release|Any CPU = Release|Any CPU
12 | EndGlobalSection
13 | GlobalSection(SolutionProperties) = preSolution
14 | HideSolutionNode = FALSE
15 | EndGlobalSection
16 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
17 | {8E699DB8-1EB6-45D2-8590-FF529BFD13FC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
18 | {8E699DB8-1EB6-45D2-8590-FF529BFD13FC}.Debug|Any CPU.Build.0 = Debug|Any CPU
19 | {8E699DB8-1EB6-45D2-8590-FF529BFD13FC}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
20 | {8E699DB8-1EB6-45D2-8590-FF529BFD13FC}.Release|Any CPU.ActiveCfg = Release|Any CPU
21 | {8E699DB8-1EB6-45D2-8590-FF529BFD13FC}.Release|Any CPU.Build.0 = Release|Any CPU
22 | {8E699DB8-1EB6-45D2-8590-FF529BFD13FC}.Release|Any CPU.Deploy.0 = Release|Any CPU
23 | EndGlobalSection
24 | EndGlobal
25 |
--------------------------------------------------------------------------------
/CS/EditFormExample/GettingStarted.txt:
--------------------------------------------------------------------------------
1 | Welcome to DevExpress Components for .NET MAUI! Here are a few tips to help you get started with your new application.
2 |
3 | DevExpress NuGet Feed
4 | ---------------------
5 |
6 | DevExpress Components for .NET MAUI are free-of-charge. To learn more about our free offer and reserve your free copy,
7 | please visit the following webpage: https://www.devexpress.com/mobile-xamarin-maui-free/
8 |
9 | IMPORTANT: You MUST register your personal NuGet package source for the solution to build correctly.
10 | After you reserved your free copy, you can use the following page to obtain a NuGet Feed URL: https://nuget.devexpress.com/
11 |
12 | If you are unfamiliar with NuGet packages, please review the following
13 | help topic (Install DevExpress Controls Using NuGet Packages): https://docs.devexpress.com/GeneralInformation/115912/
14 |
15 | QuickStart Guide
16 | ----------------
17 |
18 | See the following topic to learn more about DevExpress Components for .NET MAUI: https://docs.devexpress.com/MAUI
--------------------------------------------------------------------------------
/CS/EditFormExample/ImageEditView.xaml:
--------------------------------------------------------------------------------
1 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
21 |
22 |
25 |
26 |
27 |
28 |
29 |
30 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
--------------------------------------------------------------------------------
/CS/EditFormExample/ImageEditView.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Globalization;
3 | using System.Threading.Tasks;
4 | using DevExpress.Maui.Editors;
5 | using Microsoft.Maui.Controls;
6 |
7 | namespace EditFormExample;
8 |
9 | public partial class ImageEditView : ContentPage {
10 | private TaskCompletionSource pageResultCompletionSource;
11 |
12 | public ImageEditView() {
13 | InitializeComponent();
14 | }
15 |
16 | public ImageEditView(ImageSource imageSource) {
17 | InitializeComponent();
18 | pageResultCompletionSource = new TaskCompletionSource();
19 | editor.Source = imageSource;
20 | }
21 |
22 | public Task WaitForResultAsync() {
23 | return pageResultCompletionSource.Task;
24 | }
25 |
26 | private async void BackPressed(object sender, EventArgs e) {
27 | pageResultCompletionSource.SetResult(null);
28 | await Navigation.PopAsync();
29 | }
30 |
31 | private async void CropPressed(object sender, EventArgs e) {
32 | pageResultCompletionSource.SetResult(editor.SaveAsImageSource(DevExpress.Maui.Editors.ImageFormat.Jpeg));
33 | await Navigation.PopAsync();
34 | }
35 | }
36 |
37 | public class FrameTypeToImageStringConverter : IValueConverter {
38 | public object Convert(object value, Type targetType, object parameter, CultureInfo culture) {
39 | return (CropAreaShape)value == CropAreaShape.Ellipse ? "ic_frame_rect" : "ic_frame_circle";
40 | }
41 |
42 | public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) {
43 | throw new NotImplementedException();
44 | }
45 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/MainPage.xaml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
--------------------------------------------------------------------------------
/CS/EditFormExample/MainPage.xaml.cs:
--------------------------------------------------------------------------------
1 | using System.Net.Mail;
2 | using System.Runtime.CompilerServices;
3 | using DevExpress.Maui.Controls;
4 |
5 | namespace EditFormExample
6 | {
7 | public partial class MainPage : ContentPage
8 | {
9 | public MainPage()
10 | {
11 | InitializeComponent();
12 | }
13 | private void ValidateCustomerProperties(object sender, DevExpress.Maui.DataForm.DataFormPropertyValidationEventArgs e)
14 | {
15 | if (e.PropertyName == "Email" && e.NewValue != null)
16 | {
17 | MailAddress res;
18 | if (!MailAddress.TryCreate((string)e.NewValue, out res))
19 | {
20 | e.HasError = true;
21 | e.ErrorText = "Invalid email";
22 | }
23 | }
24 | }
25 |
26 | private void ToolbarItem_Clicked(object sender, EventArgs e)
27 | {
28 | dataForm.Commit();
29 | }
30 |
31 | private void ImageTapped(object sender, EventArgs e)
32 | {
33 | bottomSheet.State = BottomSheetState.HalfExpanded;
34 | }
35 |
36 | private async void DeletePhotoClicked(object sender, EventArgs args)
37 | {
38 | await Dispatcher.DispatchAsync(() => {
39 | bottomSheet.State = BottomSheetState.Hidden;
40 | editControl.IsVisible = false;
41 | preview.Source = null;
42 | });
43 | }
44 |
45 | private async void SelectPhotoClicked(object sender, EventArgs args)
46 | {
47 | var photo = await MediaPicker.PickPhotoAsync();
48 | await ProcessResult(photo);
49 | editControl.IsVisible = true;
50 | }
51 |
52 | private async void TakePhotoClicked(object sender, EventArgs args)
53 | {
54 | if (!MediaPicker.Default.IsCaptureSupported)
55 | return;
56 |
57 | var photo = await MediaPicker.Default.CapturePhotoAsync();
58 | await ProcessResult(photo);
59 | editControl.IsVisible = true;
60 | }
61 |
62 | private async Task ProcessResult(FileResult result)
63 | {
64 | await Dispatcher.DispatchAsync(() => {
65 | bottomSheet.State = BottomSheetState.Hidden;
66 | });
67 |
68 |
69 | if (result == null)
70 | return;
71 |
72 | ImageSource imageSource = null;
73 | if (System.IO.Path.IsPathRooted(result.FullPath))
74 | imageSource = ImageSource.FromFile(result.FullPath);
75 | else
76 | {
77 | var stream = await result.OpenReadAsync();
78 | imageSource = ImageSource.FromStream(() => stream);
79 | }
80 | var editorPage = new ImageEditView(imageSource);
81 | await Navigation.PushAsync(editorPage);
82 |
83 | var cropResult = await editorPage.WaitForResultAsync();
84 | if (cropResult != null)
85 | preview.Source = cropResult;
86 |
87 | editorPage.Handler.DisconnectHandler();
88 | }
89 | }
90 | }
91 |
--------------------------------------------------------------------------------
/CS/EditFormExample/MainViewModel.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using System.Windows.Input;
7 |
8 | namespace EditFormExample {
9 | public class MainViewModel : BindableBase {
10 | Customer editedItem;
11 | public Customer EditedItem {
12 | get { return editedItem; }
13 | set {
14 | editedItem = value;
15 | RaisePropertyChanged();
16 | }
17 | }
18 | public MainViewModel() {
19 | EditedItem = new Customer() { FirstName = "Jennie", LastName= "Valentine", Company= "Valentine Hearts", City= "Johnsonville", State= "NY", Address= "9333 Holmes Dr.", ZipCode= 12121, Email= "jennie.valentine@valetinehearts.com", Phone= "(898)745-1511", PhotoPath= "jennie_photo" };
20 | }
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/CS/EditFormExample/MauiProgram.cs:
--------------------------------------------------------------------------------
1 | using CommunityToolkit.Maui;
2 | using DevExpress.Maui;
3 | using Microsoft.Maui;
4 | using Microsoft.Maui.Controls.Compatibility;
5 | using Microsoft.Maui.Controls.Compatibility.Hosting;
6 | using Microsoft.Maui.Controls.Hosting;
7 | using Microsoft.Maui.Hosting;
8 |
9 | namespace EditFormExample {
10 | public static class MauiProgram {
11 | public static MauiApp CreateMauiApp() {
12 | var builder = MauiApp.CreateBuilder();
13 | builder
14 | .UseMauiApp()
15 | .UseDevExpress(useLocalization: true)
16 | .UseMauiCommunityToolkit()
17 | .UseDevExpressCollectionView()
18 | .UseDevExpressControls()
19 | .UseDevExpressEditors()
20 | .ConfigureFonts(fonts =>
21 | {
22 | fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
23 | fonts.AddFont("univia-pro-regular.ttf", "Univia-Pro");
24 | fonts.AddFont("roboto-bold.ttf", "Roboto-Bold");
25 | fonts.AddFont("roboto-regular.ttf", "Roboto");
26 | });
27 |
28 | return builder.Build();
29 | }
30 | }
31 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/Android/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/Android/MainActivity.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Content.PM;
3 | using Android.OS;
4 |
5 | namespace EditFormExample {
6 | [Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
7 | public class MainActivity : MauiAppCompatActivity {
8 | }
9 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/Android/MainApplication.cs:
--------------------------------------------------------------------------------
1 | using Android.App;
2 | using Android.Runtime;
3 |
4 | namespace EditFormExample {
5 | [Application]
6 | public class MainApplication : MauiApplication {
7 | public MainApplication(IntPtr handle, JniHandleOwnership ownership)
8 | : base(handle, ownership) {
9 | }
10 |
11 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/Android/Resources/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #512BD4
4 | #2B0B98
5 | #2B0B98
6 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/Android/Resources/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/iOS/AppDelegate.cs:
--------------------------------------------------------------------------------
1 | using Foundation;
2 |
3 | namespace EditFormExample {
4 | [Register("AppDelegate")]
5 | public class AppDelegate : MauiUIApplicationDelegate {
6 | protected override MauiApp CreateMauiApp() => MauiProgram.CreateMauiApp();
7 | }
8 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/iOS/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | LSRequiresIPhoneOS
6 |
7 | UIDeviceFamily
8 |
9 | 1
10 | 2
11 |
12 | UIRequiredDeviceCapabilities
13 |
14 | arm64
15 |
16 | UISupportedInterfaceOrientations
17 |
18 | UIInterfaceOrientationPortrait
19 | UIInterfaceOrientationLandscapeLeft
20 | UIInterfaceOrientationLandscapeRight
21 |
22 | UISupportedInterfaceOrientations~ipad
23 |
24 | UIInterfaceOrientationPortrait
25 | UIInterfaceOrientationPortraitUpsideDown
26 | UIInterfaceOrientationLandscapeLeft
27 | UIInterfaceOrientationLandscapeRight
28 |
29 | XSAppIconAssets
30 | Assets.xcassets/appicon.appiconset
31 | NSCameraUsageDescription
32 | This sample uses the camera.
33 |
34 |
35 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/iOS/Program.cs:
--------------------------------------------------------------------------------
1 | using ObjCRuntime;
2 | using UIKit;
3 |
4 | namespace EditFormExample {
5 | public class Program {
6 | // This is the main entry point of the application.
7 | static void Main(string[] args) {
8 | // if you want to use a different Application Delegate class from "AppDelegate"
9 | // you can specify it here.
10 | UIApplication.Main(args, null, typeof(AppDelegate));
11 | }
12 | }
13 | }
--------------------------------------------------------------------------------
/CS/EditFormExample/Platforms/iOS/Resources/LaunchScreen.xib:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
21 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Readme.md:
--------------------------------------------------------------------------------
1 | # DataFormView for .NET MAUI - Edit a Contact’s Data
2 |
3 | This example demonstrates how to use the [`DataFormView`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormView) control to implement a contact edit form. To edit the user avatar, you can use the [`ImageEdit`](https://docs.devexpress.com/MAUI/DevExpress.Maui.Editors.ImageEdit) control.
4 |
5 |
6 |
7 | ## Implementation Details
8 |
9 | * Specify the [`DataFormView.DataObject`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormView.DataObject) property to bind a `DataFormView` to an object.
10 |
11 | * Use a `DataFormView` editor's [`FieldName`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormItem.FieldName) property to bind the editor to a view model's property:
12 |
13 | ```xml
14 |
15 | ```
16 |
17 | * Call the [`DataFormView.Commit`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormView.Commit) method to validate input values and send changes to the data source.
18 |
19 | * `DataFormView` supports validation events and attributes. The following code uses a validation event for `Email` values:
20 |
21 | ```csharp
22 | private void ValidateCustomerProperties(object sender, DevExpress.Maui.DataForm.DataFormPropertyValidationEventArgs e) {
23 | if (e.PropertyName == "Email" && e.NewValue != null) {
24 | MailAddress res;
25 | if (!MailAddress.TryCreate((string)e.NewValue, out res)) {
26 | e.HasError = true;
27 | e.ErrorText = "Invalid email";
28 | }
29 | }
30 | }
31 | ```
32 |
33 | The following code snippet defines validation attributes for `FirstName` and `LastName` properties:
34 |
35 | ```csharp
36 | public class Customer {
37 |
38 | [Required(ErrorMessage = "First Name cannot be empty")]
39 | public string FirstName
40 | //...
41 | [Required(ErrorMessage = "Last Name cannot be empty")]
42 | public string LastName
43 | //...
44 | }
45 | ```
46 |
47 | * `DataFormView` automatically aligns its editors. You can customize the color and width of editor labels:
48 |
49 | ```xaml
50 |
51 | ```
52 |
53 | * Embedded `DataFormView`'s editors contain customization options such as [`LabelIcon`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormItem.LabelIcon), [`InplaceLabelText`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormItem.InplaceLabelText), [`LabelText`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormItem.LabelText), and [`IsInplaceLabelFloating`](https://docs.devexpress.com/MAUI/DevExpress.Maui.Editors.EditBase.IsLabelFloating).
54 |
55 | * You can use the `LabelIcon` property to divide editors into visual groups.
56 |
57 | ```xml
58 |
59 |
60 |
61 |
62 | ```
63 |
64 | * If an editor's `LabelIcon` property is not specified, `DataFormView` displays the bound property's name in the editor's label area. You can set the editor's `LabelIcon` property to an empty string to hide this text.
65 |
66 | ```xml
67 |
68 | ```
69 |
70 | * `DataFormView` items support masks. Specify the [`DataFormMaskedItem.Mask`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormMaskedItem.Mask) property to define a mask.
71 |
72 | ```xml
73 |
74 | ```
75 | * Specify a [`DataFormItem`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormItem)'s [`Keyboard`](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormTextItemBase.Keyboard) property to define a type of keyboard used to input text.
76 |
77 | ## Files to Look At
78 |
79 |
80 | * [MainPage.xaml](./MainPage.xaml)
81 | * [MainPage.xaml.cs](./MainPage.xaml.cs)
82 | * [MainViewModel.cs](./MainViewModel.cs)
83 | * [App.xaml](./App.xaml)
84 |
85 |
86 | ## Documentation
87 |
88 | * [DataFormView](https://docs.devexpress.com/MAUI/DevExpress.Maui.DataForm.DataFormView)
89 | * [StatusBarBehavior](https://learn.microsoft.com/en-us/dotnet/communitytoolkit/maui/behaviors/statusbar-behavior)
90 | * [ImageEdit](https://docs.devexpress.com/MAUI/DevExpress.Maui.Editors.ImageEdit)
91 | * [DXBorder](https://docs.devexpress.com/MAUI/DevExpress.Maui.Core.DXBorder)
92 |
93 | ## More Examples
94 |
95 | * [Get Started with DevExpress Data Form for .NET MAUI](../DataFormGetStarted)
96 | * [Add and Remove DataFormItems at Runtime](../AddingDataEditorsAtRuntime)
97 | * [Customize a DataFrom Appearance](../CustomAppearance)
98 | * [Display a ComboBoxEdit in the DataForm](../ComboBoxEditor)
99 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/AppIcon/appicon.svg:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/AppIcon/appiconfg.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
9 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Fonts/OpenSans-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/EditFormExample/Resources/Fonts/OpenSans-Regular.ttf
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Fonts/roboto-bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/EditFormExample/Resources/Fonts/roboto-bold.ttf
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Fonts/roboto-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/EditFormExample/Resources/Fonts/roboto-regular.ttf
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Fonts/univia-pro-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/EditFormExample/Resources/Fonts/univia-pro-regular.ttf
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/background.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
118 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/check.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/delete.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/editorscalendar.svg:
--------------------------------------------------------------------------------
1 |
6 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/editorscompany.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/editorsemail.svg:
--------------------------------------------------------------------------------
1 |
6 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/editorslocation.svg:
--------------------------------------------------------------------------------
1 |
6 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/editorsname.svg:
--------------------------------------------------------------------------------
1 |
6 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/editorsphone.svg:
--------------------------------------------------------------------------------
1 |
6 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/gallery.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_arrow_back.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_check.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_frame_circle.svg:
--------------------------------------------------------------------------------
1 |
11 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_frame_rect.svg:
--------------------------------------------------------------------------------
1 |
11 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_mirror_h.svg:
--------------------------------------------------------------------------------
1 |
11 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_mirror_v.svg:
--------------------------------------------------------------------------------
1 |
11 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_rotate_left.svg:
--------------------------------------------------------------------------------
1 |
11 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/ic_rotate_right.svg:
--------------------------------------------------------------------------------
1 |
11 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/jennie_photo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/CS/EditFormExample/Resources/Images/jennie_photo.png
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/pencil.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/savechanges.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
20 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Images/take_photo.svg:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/CS/EditFormExample/Resources/Splash/splash.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
9 |
--------------------------------------------------------------------------------
/CS/GettingStarted.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 17
4 | VisualStudioVersion = 17.0.31611.283
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DataFormGetStarted", "DataFormGetStarted\DataFormGetStarted.csproj", "{2CC57DF5-1395-4D13-AFB7-87234C5DF2B1}"
7 | EndProject
8 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ComboBoxEditor", "ComboBoxEditor\ComboBoxEditor.csproj", "{503BD072-0FF5-4B43-B96D-E8224AED3417}"
9 | EndProject
10 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AddingDataEditorsAtRuntime", "AddingDataEditorsAtRuntime\AddingDataEditorsAtRuntime.csproj", "{7F43CE3F-0C63-45E5-AAC1-5EE5FF2D3041}"
11 | EndProject
12 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CustomAppearance", "CustomAppearance\CustomAppearance.csproj", "{1528F0DE-9FAF-4220-924B-75C26A710C9C}"
13 | EndProject
14 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EditFormExample", "EditFormExample\EditFormExample.csproj", "{76C22E1C-7AB2-488C-9F7E-C4145CFBB029}"
15 | EndProject
16 | Global
17 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
18 | Debug|Any CPU = Debug|Any CPU
19 | Release|Any CPU = Release|Any CPU
20 | EndGlobalSection
21 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
22 | {2CC57DF5-1395-4D13-AFB7-87234C5DF2B1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
23 | {2CC57DF5-1395-4D13-AFB7-87234C5DF2B1}.Debug|Any CPU.Build.0 = Debug|Any CPU
24 | {2CC57DF5-1395-4D13-AFB7-87234C5DF2B1}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
25 | {2CC57DF5-1395-4D13-AFB7-87234C5DF2B1}.Release|Any CPU.ActiveCfg = Release|Any CPU
26 | {2CC57DF5-1395-4D13-AFB7-87234C5DF2B1}.Release|Any CPU.Build.0 = Release|Any CPU
27 | {2CC57DF5-1395-4D13-AFB7-87234C5DF2B1}.Release|Any CPU.Deploy.0 = Release|Any CPU
28 | {503BD072-0FF5-4B43-B96D-E8224AED3417}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
29 | {503BD072-0FF5-4B43-B96D-E8224AED3417}.Debug|Any CPU.Build.0 = Debug|Any CPU
30 | {503BD072-0FF5-4B43-B96D-E8224AED3417}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
31 | {503BD072-0FF5-4B43-B96D-E8224AED3417}.Release|Any CPU.ActiveCfg = Release|Any CPU
32 | {503BD072-0FF5-4B43-B96D-E8224AED3417}.Release|Any CPU.Build.0 = Release|Any CPU
33 | {503BD072-0FF5-4B43-B96D-E8224AED3417}.Release|Any CPU.Deploy.0 = Release|Any CPU
34 | {7F43CE3F-0C63-45E5-AAC1-5EE5FF2D3041}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
35 | {7F43CE3F-0C63-45E5-AAC1-5EE5FF2D3041}.Debug|Any CPU.Build.0 = Debug|Any CPU
36 | {7F43CE3F-0C63-45E5-AAC1-5EE5FF2D3041}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
37 | {7F43CE3F-0C63-45E5-AAC1-5EE5FF2D3041}.Release|Any CPU.ActiveCfg = Release|Any CPU
38 | {7F43CE3F-0C63-45E5-AAC1-5EE5FF2D3041}.Release|Any CPU.Build.0 = Release|Any CPU
39 | {7F43CE3F-0C63-45E5-AAC1-5EE5FF2D3041}.Release|Any CPU.Deploy.0 = Release|Any CPU
40 | {1528F0DE-9FAF-4220-924B-75C26A710C9C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
41 | {1528F0DE-9FAF-4220-924B-75C26A710C9C}.Debug|Any CPU.Build.0 = Debug|Any CPU
42 | {1528F0DE-9FAF-4220-924B-75C26A710C9C}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
43 | {1528F0DE-9FAF-4220-924B-75C26A710C9C}.Release|Any CPU.ActiveCfg = Release|Any CPU
44 | {1528F0DE-9FAF-4220-924B-75C26A710C9C}.Release|Any CPU.Build.0 = Release|Any CPU
45 | {1528F0DE-9FAF-4220-924B-75C26A710C9C}.Release|Any CPU.Deploy.0 = Release|Any CPU
46 | {76C22E1C-7AB2-488C-9F7E-C4145CFBB029}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
47 | {76C22E1C-7AB2-488C-9F7E-C4145CFBB029}.Debug|Any CPU.Build.0 = Debug|Any CPU
48 | {76C22E1C-7AB2-488C-9F7E-C4145CFBB029}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
49 | {76C22E1C-7AB2-488C-9F7E-C4145CFBB029}.Release|Any CPU.ActiveCfg = Release|Any CPU
50 | {76C22E1C-7AB2-488C-9F7E-C4145CFBB029}.Release|Any CPU.Build.0 = Release|Any CPU
51 | {76C22E1C-7AB2-488C-9F7E-C4145CFBB029}.Release|Any CPU.Deploy.0 = Release|Any CPU
52 | EndGlobalSection
53 | GlobalSection(SolutionProperties) = preSolution
54 | HideSolutionNode = FALSE
55 | EndGlobalSection
56 | GlobalSection(ExtensibilityGlobals) = postSolution
57 | SolutionGuid = {61F7FB11-1E47-470C-91E2-47F8143E1572}
58 | EndGlobalSection
59 | EndGlobal
60 |
--------------------------------------------------------------------------------
/Images/data-form-combobox-android.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-combobox-android.png
--------------------------------------------------------------------------------
/Images/data-form-combobox-iphone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-combobox-iphone.png
--------------------------------------------------------------------------------
/Images/data-form-custom-appearance-android.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-custom-appearance-android.png
--------------------------------------------------------------------------------
/Images/data-form-custom-appearance-iphone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-custom-appearance-iphone.png
--------------------------------------------------------------------------------
/Images/data-form-example-iphone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-example-iphone.png
--------------------------------------------------------------------------------
/Images/data-form-example-pixel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-example-pixel.png
--------------------------------------------------------------------------------
/Images/data-form-runtime-android.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-runtime-android.png
--------------------------------------------------------------------------------
/Images/data-form-runtime-iphone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-runtime-iphone.png
--------------------------------------------------------------------------------
/Images/data-form-with-image-edit-bs.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-with-image-edit-bs.png
--------------------------------------------------------------------------------
/Images/data-form-with-image-edit-upload.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/data-form-with-image-edit-upload.png
--------------------------------------------------------------------------------
/Images/maui.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/DevExpress-Examples/maui-data-form/72c5c4666bfc0f93d9e027ebb1b8d21032e95116/Images/maui.png
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
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:
--------------------------------------------------------------------------------
1 |
2 | 
3 | [](https://supportcenter.devexpress.com/ticket/details/T1054610)
4 | [](https://docs.devexpress.com/GeneralInformation/403183)
5 | [](#does-this-example-address-your-development-requirementsobjectives)
6 |
7 | # DevExpress Data Form for .NET MAUI
8 |
9 | [DevExpress Mobile UI](https://www.devexpress.com/maui/) allows you to use a .NET cross-platform UI toolkit and C# to build native apps for iOS and Android.
10 |
11 | 
12 |
13 | You need a [DevExpress .NET MAUI Subscription](https://www.devexpress.com/maui/) to run the example. To evaluate our controls, you can start a [free 30-day trial](https://docs.devexpress.com/MAUI/404024/get-started/register-nuget-gallery) through the DevExpress NuGet feed.
14 |
15 | ## Requirements
16 |
17 | You need to register the DevExpress NuGet Gallery in Visual Studio to restore the NuGet packages used in this solution. See the following topic for more information: [Get Started with DevExpress Mobile UI for .NET MAUI](https://docs.devexpress.com/MAUI/403249/get-started).
18 |
19 | You can also refer to the following YouTube video for instructions on how to get started with the DevExpress .NET MAUI Controls: [Setting up a .NET MAUI Project](https://www.youtube.com/watch?v=juJvl5UicIQ).
20 |
21 | ## What's in This Repository
22 |
23 | ### Get Started with DevExpress Data Form for .NET MAUI
24 |
25 | The [Getting Started](./CS/DataFormGetStarted/) project demonstrates the capabilities of the **DevExpress Data Form for .NET MAUI** — a control that allows you to display and edit data objects.
26 |
27 |
28 |
29 | See the following help topic for more information: [DevExpress Data Form for .NET MAUI](https://docs.devexpress.com/MAUI/403640/data-form).
30 |
31 | You can also refer to the following YouTube video for instructions on how to get started with the Data Form Control: [Adding a Data Form to Your .NET MAUI App](https://www.youtube.com/watch?v=imUCmru5Lwc&ab_channel=DevExpress).
32 |
33 | ### Customize the Data Form Appearance
34 |
35 | The [CustomAppearance](./CS/CustomAppearance/) project shows how to customize the appearance of Data Form items.
36 |
37 |
38 |
39 | ### Add and Remove DataFormItems at Runtime
40 |
41 | The [AddingDataEditorsAtRuntime](./CS/AddingDataEditorsAtRuntime/) project shows how to add and remove Data Form items at runtime.
42 |
43 |
44 |
45 | ### Display ComboBox
46 |
47 | The [ComboBoxEditor](./CS/ComboBoxEditor/) project shows how to display a ComboboxEdit control within the Data Form.
48 |
49 |
50 |
51 | ### Upload and Edit Avatar
52 |
53 | The [EditFormExample](./CS/EditFormExample/) project shows how to integrate the [ImageEdit](https://docs.devexpress.com/MAUI/DevExpress.Maui.Editors.ImageEdit) control within the Data Form to edit the avatar.
54 |
55 |
56 |
57 | ## Documentation
58 |
59 | - [Data Grid](https://docs.devexpress.com/MAUI/403255/data-grid/data-grid)
60 | - [Charts](https://docs.devexpress.com/MAUI/403300/charts/charts)
61 | - [Data Form](https://docs.devexpress.com/MAUI/403640/data-form)
62 | - [Navigation](https://docs.devexpress.com/MAUI/403297/navigation/index)
63 | - [Data Editors](https://docs.devexpress.com/MAUI/403427/editors/index)
64 | - [Collection View](https://docs.devexpress.com/MAUI/403324/collection-view/index)
65 | - [Image Editor](https://docs.devexpress.com/MAUI/DevExpress.Maui.Editors.ImageEdit)
66 |
67 | ## More Examples
68 |
69 | * [Stocks App](https://github.com/DevExpress-Examples/maui-stocks-mini)
70 | * [Data Grid](https://github.com/DevExpress-Examples/maui-data-grid-get-started)
71 | * [Data Editors](https://github.com/DevExpress-Examples/maui-editors-get-started)
72 | * [Charts](https://github.com/DevExpress-Examples/maui-charts)
73 | * [Scheduler](https://github.com/DevExpress-Examples/maui-scheduler-get-started)
74 | * [Tab Page](https://github.com/DevExpress-Examples/maui-tab-page-get-started)
75 | * [Tab View](https://github.com/DevExpress-Examples/maui-tab-view-get-started)
76 | * [Drawer Page](https://github.com/DevExpress-Examples/maui-drawer-page-get-started)
77 | * [Drawer View](https://github.com/DevExpress-Examples/maui-drawer-view-get-started)
78 | * [Collection View](https://github.com/DevExpress-Examples/maui-collection-view-get-started)
79 | * [Popup](https://github.com/DevExpress-Examples/maui-popup-get-started)
80 |
81 | ## Does this example address your development requirements/objectives?
82 |
83 | [
](https://www.devexpress.com/support/examples/survey.xml?utm_source=github&utm_campaign=maui-data-form&~~~was_helpful=yes) [
](https://www.devexpress.com/support/examples/survey.xml?utm_source=github&utm_campaign=maui-data-form&~~~was_helpful=no)
84 |
85 | (you will be redirected to DevExpress.com to submit your response)
86 |
87 |
--------------------------------------------------------------------------------
/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "autoGenerateVb": false,
3 | "runOnWeb": false
4 | }
--------------------------------------------------------------------------------