Skip to content

Instantly share code, notes, and snippets.

Avatar
🐼
Thinking

Tuğçe Arar stugcearar

🐼
Thinking
View GitHub Profile
View ListViewPage.xaml
<?xml version="1.0" encoding="UTF-8"?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:control="clr-namespace:XFEmptyViewSample.Controls"
xmlns:helper="clr-namespace:XFEmptyViewSample.Helpers"
xmlns:viewmodel="clr-namespace:XFEmptyViewSample.ViewModels"
x:Class="XFEmptyViewSample.Views.ListViewPage" Title="Birds">
<ContentPage.BindingContext>
<viewmodel:ListViewPageViewModel/>
</ContentPage.BindingContext>
View info.plist
<dict>
<key>CFBundleIcons</key>
<dict>
<key>CFBundleAlternateIcons</key>
<dict>
<key>apple</key>
<dict>
<key>CFBundleIconFiles</key>
<array>
<string>apple</string>
View ChangeIconService.cs
[assembly: Dependency(typeof(ChangeIconService))]
namespace XamarinFormsChangeIcon.iOS.Helpers
{
public class ChangeIconService : IChangeIconService
{
NSError error = new NSError();
public ChangeIconService()
{
}
View swagger2.cs
public void ConfigureServices(IServiceCollection services)
{
//Helper için
services.AddSwaggerGen(c =>
{
c.SwaggerDoc("v1", new Swashbuckle.AspNetCore.Swagger.Info
{
Version = "v1",
Title = "My Web API",
Description = "Awesome WEB API",
View swagger1.cs
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
{
if (env.IsDevelopment())
{
app.UseDeveloperExceptionPage();
app.UseSwagger();
app.UseSwaggerUI(c =>
{
c.SwaggerEndpoint("/swagger/v1/swagger.json", "MyWebAPI Helper Page");
});
View main.xaml
<StackLayout VerticalOptions="Center">
<renderers:CustomPicker DoneButtonText="My Custom Done Text" CancelButtonText="My Custom Cancel Text" />
<renderers:CustomPicker DoneButtonText="My Other Custom Done Text" CancelButtonText="My Other Custom Cancel Text"/>
</StackLayout>
View customrenderer_ios.cs
public class CustomPickerRenderer : PickerRenderer
{
protected override void OnElementChanged(ElementChangedEventArgs<Picker> e)
{
base.OnElementChanged(e);
if (e.NewElement == null) return;
var customPicker = e.NewElement as CustomPicker;
if (Control == null)
{
SetNativeControl(new UITextField
View customrenderer_droid.cs
public class CustomPickerRenderer : PickerRenderer
{
AlertDialog _dialog;
IElementController ElementController => Element as IElementController;
CustomPicker customPicker;
public CustomPickerRenderer(Context context) : base(context)
{
}
protected override void OnElementChanged(ElementChangedEventArgs<Picker> e)
View custompicker.cs
public class CustomPicker : Picker
{
public string DoneButtonText
{
get
{
return (string)GetValue(DoneButtonTextProperty);
}
set
{
View local.settings.json
{
"IsEncrypted": false,
"Values": {
"AzureWebJobsStorage": "UseDevelopmentStorage=true",
"AzureWebJobsDashboard": "UseDevelopmentStorage=true"
},
"ConnectionStrings": {
"MyConnectionString": "<sqlclient-connection-string>"
}
}
You can’t perform that action at this time.