罗格斯大学文凭〈Rutgers毕业证成绩单〉Q微信9105133留信认证/买美国罗格斯大学(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)Rutgers, The State University of New Jersey
罗格斯大学文凭〈Rutgers毕业证成绩单〉Q微信9105133留信认证/买美国罗格斯大学(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)Rutgers, The State Univ
宾夕法尼亚州立大学文凭〈PSU毕业证成绩单〉Q微信9105133留信认证/买美国宾州立大学(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)The Pennsylvania State
宾夕法尼亚州立大学文凭〈PSU毕业证成绩单〉Q微信9105133留信认证/买美国宾州立大学(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)The Pennsylvania State University
旧金山大学文凭〈USF毕业证成绩单〉Q微信9105133留信认证/买美国USF(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)University of San Francisco
旧金山大学文凭〈USF毕业证成绩单〉Q微信9105133留信认证/买美国USF(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)University of San Francisco
莱斯大学文凭〈Rice毕业证成绩单〉Q微信9105133留信认证/买美国莱斯大学(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)Rice University
莱斯大学文凭〈Rice毕业证成绩单〉Q微信9105133留信认证/买美国莱斯大学(精仿)毕业证成绩单,(真实)学历认证,使馆认证(回国人员证明)Rice University
Picker shows multiple times
if you have multiple pickers on a page like Picker 1, picker 2 ... when you click on picker 1 and select something it works fine, but if you click and select something from second picker the first picker shows by itself. it is happening in XF 3.4.0.1008975 but it is ok in XF version 3.1.0.583944.
Do we have any fixes on its way?
Getting last 4 characters from a string retrieved from a Database
I'm using Firebase Realtime Database and I'm getting a string from the database and displaying it in a view using XAML. In order to cut a string and get last 4 digits, I'd generally do
x:Name="string1"
x.xaml.xs
string1.Text.Substring(string1.Text.Length - 4)
but I'm getting string1 doesn't exist in the current context. Maybe it's because I have it inside a ListView and I'm binding string1?
`
<ListView.ItemTemplate>
<ViewCell.View>
<Label x:Name="string1" VerticalTextAlignment="Center" Text="{Binding itemID}"/>
<Label VerticalTextAlignment="Center" Text="{Binding item}" />
</ViewCell.View>
</ViewCell>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>`
Need help debugging random crashes in GridCalc.cs
Hi, it's been a year or so that im getting random crashes in GridCalc, totally fail to repro, making it impossible for me to avoid. It's just random, on both iOS and Android, whatever forms version, being on latest atm.
Even worse, I cant seem to match Xamarin open source code i can find in inet with stacktrace lines numbers.
If anyone could could give me a direction to dig in, would be grateful for any clue:
12-12 16:08:53.456 I/MonoDroid( 7446): UNHANDLED EXCEPTION:
Thread started: <Thread Pool> #13
12-12 16:08:53.776 I/MonoDroid( 7446): System.NullReferenceException: Object reference not set to an instance of an object.
12-12 16:08:53.777 I/MonoDroid( 7446): at Xamarin.Forms.Grid.MeasureStarredRows () [0x0017c] in D:\a\1\s\Xamarin.Forms.Core\GridCalc.cs:530
12-12 16:08:53.777 I/MonoDroid( 7446): at Xamarin.Forms.Grid.MeasureAndContractStarredRows (System.Double width, System.Double height, System.Double totalStarsHeight) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\GridCalc.cs:403
12-12 16:08:53.778 I/MonoDroid( 7446): at Xamarin.Forms.Grid.MeasureGrid (System.Double width, System.Double height, System.Boolean requestSize) [0x00117] in D:\a\1\s\Xamarin.Forms.Core\GridCalc.cs:510
12-12 16:08:53.778 I/MonoDroid( 7446): at Xamarin.Forms.Grid.OnSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x0002a] in D:\a\1\s\Xamarin.Forms.Core\GridCalc.cs:58
12-12 16:08:53.778 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.OnMeasure (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:760
12-12 16:08:53.778 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00053] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:642
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.Layout.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:131
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.Measure (System.Double widthConstraint, System.Double heightConstraint, Xamarin.Forms.MeasureFlags flags) [0x00054] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:700
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.StackLayout.CalculateNaiveLayout (Xamarin.Forms.StackLayout+LayoutInformation layout, Xamarin.Forms.StackOrientation orientation, System.Double x, System.Double y, System.Double widthConstraint, System.Double heightConstraint) [0x00236] in D:\a\1\s\Xamarin.Forms.Core\StackLayout.cs:198
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.StackLayout.CalculateLayout (Xamarin.Forms.StackLayout+LayoutInformation layout, System.Double x, System.Double y, System.Double widthConstraint, System.Double heightConstraint, System.Boolean processExpanders) [0x00058] in D:\a\1\s\Xamarin.Forms.Core\StackLayout.cs:123
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.StackLayout.OnSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00019] in D:\a\1\s\Xamarin.Forms.Core\StackLayout.cs:80
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.OnMeasure (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:760
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00053] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:642
12-12 16:08:53.779 I/MonoDroid( 7446): at Xamarin.Forms.Layout.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:131
12-12 16:08:53.780 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.Measure (System.Double widthConstraint, System.Double heightConstraint, Xamarin.Forms.MeasureFlags flags) [0x00054] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:700
12-12 16:08:53.780 I/MonoDroid( 7446): at Xamarin.Forms.StackLayout.CalculateNaiveLayout (Xamarin.Forms.StackLayout+LayoutInformation layout, Xamarin.Forms.StackOrientation orientation, System.Double x, System.Double y, System.Double widthConstraint, System.Double heightConstraint) [0x00236] in D:\a\1\s\Xamarin.Forms.Core\StackLayout.cs:198
12-12 16:08:53.783 I/MonoDroid( 7446): at Xamarin.Forms.StackLayout.CalculateLayout (Xamarin.Forms.StackLayout+LayoutInformation layout, System.Double x, System.Double y, System.Double widthConstraint, System.Double heightConstraint, System.Boolean processExpanders) [0x00058] in D:\a\1\s\Xamarin.Forms.Core\StackLayout.cs:123
12-12 16:08:53.783 I/MonoDroid( 7446): at Xamarin.Forms.StackLayout.OnSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00019] in D:\a\1\s\Xamarin.Forms.Core\StackLayout.cs:80
12-12 16:08:53.784 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.OnMeasure (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:760
12-12 16:08:53.784 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00053] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:642
12-12 16:08:53.784 I/MonoDroid( 7446): at Xamarin.Forms.Layout.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:131
12-12 16:08:53.784 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.Measure (System.Double widthConstraint, System.Double heightConstraint, Xamarin.Forms.MeasureFlags flags) [0x00054] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:700
12-12 16:08:53.784 I/MonoDroid( 7446): at Xamarin.Forms.ScrollView.OnSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x0005d] in D:\a\1\s\Xamarin.Forms.Core\ScrollView.cs:233
12-12 16:08:53.784 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.OnMeasure (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:760
12-12 16:08:53.784 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00053] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:642
12-12 16:08:53.785 I/MonoDroid( 7446): at Xamarin.Forms.Layout.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:131
12-12 16:08:53.785 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.Measure (System.Double widthConstraint, System.Double heightConstraint, Xamarin.Forms.MeasureFlags flags) [0x00054] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:700
12-12 16:08:53.785 I/MonoDroid( 7446): at Xamarin.Forms.TemplatedView.OnSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x0003c] in D:\a\1\s\Xamarin.Forms.Core\TemplatedView.cs:39
12-12 16:08:53.785 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.OnMeasure (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:760
12-12 16:08:53.785 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00053] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:642
12-12 16:08:53.785 I/MonoDroid( 7446): at Xamarin.Forms.Layout.GetSizeRequest (System.Double widthConstraint, System.Double heightConstraint) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:131
12-12 16:08:53.786 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.Measure (System.Double widthConstraint, System.Double heightConstraint, Xamarin.Forms.MeasureFlags flags) [0x00054] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:700
12-12 16:08:53.786 I/MonoDroid( 7446): at Xamarin.Forms.Layout.LayoutChildIntoBoundingRegion (Xamarin.Forms.VisualElement child, Xamarin.Forms.Rectangle region) [0x00110] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:165
12-12 16:08:53.786 I/MonoDroid( 7446): at Xamarin.Forms.AbsoluteLayout.LayoutChildren (System.Double x, System.Double y, System.Double width, System.Double height) [0x00046] in D:\a\1\s\Xamarin.Forms.Core\AbsoluteLayout.cs:69
12-12 16:08:53.787 I/MonoDroid( 7446): at Xamarin.Forms.Layout.UpdateChildrenLayout () [0x0014b] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:263
12-12 16:08:53.787 I/MonoDroid( 7446): at Xamarin.Forms.Layout.OnSizeAllocated (System.Double width, System.Double height) [0x0000f] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:223
12-12 16:08:53.787 I/MonoDroid( 7446): at Xamarin.Forms.VisualElement.SizeAllocated (System.Double width, System.Double height) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:798
12-12 16:08:53.787 I/MonoDroid( 7446): at Xamarin.Forms.Layout+<>c.<OnChildMeasureInvalidated>b__45_0 () [0x00080] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:380
12-12 16:08:53.787 I/MonoDroid( 7446): at Java.Lang.Thread+RunnableImplementor.Run () [0x00008] in <ad2f15102b3a4d36b40e9b0cbc11c376>:0
12-12 16:08:53.788 I/MonoDroid( 7446): at Java.Lang.IRunnableInvoker.n_Run (System.IntPtr jnienv, System.IntPtr native__this) [0x00009] in <ad2f15102b3a4d36b40e9b0cbc11c376>:0
Does have visual studio 2017 preview for xaml file?
Is there preview for xaml file by using visual studio 2017 like as WPF?
how to turn on/off OneSignal push notification
Hi xamarin forum
I have implemented OneSignal for push notification but I want to have a turn on off notification with a push of toggle button, How can I acheive it
app crash by editor control : focus search returned a view that wasn't able to take focus!
xamarin forms standard
look like a bug to me and I wonder how to bypass that..
[1]
on some devices the app crash when editor control got focus right after showing the keyboard.
[2]
(on my device) crashes after the clicking the done/next button when on landscape mode.
the error log in bellow.
so for [2] I tried to bypass that by:
having the editor int a frame parent control as so:
<Frame x:Name="frameEditor" IsTabStop="True" >
<Editor Margin="10"
x:Name="txtMemoriam"
HorizontalOptions="FillAndExpand"
AutoSize="TextChanges"
Placeholder="Memoriam"
Parent="frameEditor"
Completed="TxtMemoriam_Completed"
Focused="TxtMemoriam_Focused"
></Editor>
</Frame>
so now: on landscape mode the "done" button change to "next" control...
and apparently, its give focus to DatePicker control (open the datepicker)... (it's unexpected Behavior but it prevents it from crashing...)
for the first issue, I have tried to set focus.. but i dont yet know if its working - cause its not crashing on my device (got the report from google play)..
private void TxtMemoriam_Completed(object sender, EventArgs e)
{
//txtMemoriam.Unfocus();
//frameEditor.Focus();
Xamarin.Forms.Device.BeginInvokeOnMainThread(() =>
{
Task.Delay(1).ContinueWith(x => { this.txtMemoriam.Focus(); });
Task.Delay(10).ContinueWith(x => { this.txtMemoriam.Focus(); });
Task.Delay(100).ContinueWith(x => { this.txtMemoriam.Focus(); });
Task.Delay(1000).ContinueWith(x => { this.txtMemoriam.Focus(); });
});
}
private void TxtMemoriam_Focused(object sender, Xamarin.Forms.FocusEventArgs e)
{
this.txtMemoriam.Focus();
Xamarin.Forms.Device.BeginInvokeOnMainThread(() =>
{
Task.Delay(1).ContinueWith(x => { this.txtMemoriam.Focus(); });
Task.Delay(10).ContinueWith(x => { this.txtMemoriam.Focus(); });
Task.Delay(100).ContinueWith(x => { this.txtMemoriam.Focus(); });
Task.Delay(1000).ContinueWith(x => { this.txtMemoriam.Focus(); });
});
}
Issue: java.lang.IllegalStateException: focus search returned a view that wasn't able to take focus!
FATAL EXCEPTION: main
Process: com.shaot.nosafot, PID: 14496
java.lang.IllegalStateException: focus search returned a view that wasn't able to take focus!
at android.widget.TextView.onKeyUp(TextView.java:6674)
at android.view.KeyEvent.dispatch(KeyEvent.java:2766)
at android.view.View.dispatchKeyEvent(View.java:9948)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.widget.ScrollView.dispatchKeyEvent(ScrollView.java:391)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at android.view.ViewGroup.dispatchKeyEvent(ViewGroup.java:1667)
at com.android.internal.policy.DecorView.superDispatchKeyEvent(DecorView.java:439)
at com.android.internal.policy.PhoneWindow.superDispatchKeyEvent(PhoneWindow.java:1861)
at android.support.v4.view.KeyEventDispatcher.activitySuperDispatchKeyEventPre28(KeyEventDispatcher.java:130)
at android.support.v4.view.KeyEventDispatcher.dispatchKeyEvent(KeyEventDispatcher.java:87)
at android.support.v4.app.SupportActivity.dispatchKeyEvent(ComponentActivity.java:126)
at android.support.v7.app.AppCompatActivity.dispatchKeyEvent(AppCompatActivity.java:535)
at android.support.v7.view.WindowCallbackWrapper.dispatchKeyEvent(WindowCallbackWrapper.java:59)
at android.support.v7.app.AppCompatDelegateImpl$AppCompatWindowCallback.dispatchKeyEvent(AppCompatDelegateImpl.java:2533)
at android.support.v7.view.WindowCallbackWrapper.dispatchKeyEvent(WindowCallbackWrapper.java:59)
at com.android.internal.policy.DecorView.dispatchKeyEvent(DecorView.java:353)
at android.view.ViewRootImpl$ViewPostImeInputStage.processKeyEvent(ViewRootImpl.java:4736)
at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4707)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4244)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4297)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4263)
at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:4390)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4271)
at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:4447)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4244)
at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4297)
at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4263)
at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4271)
at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4244)
at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:6671)
at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:6645)
at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:6606)
at android.view.ViewRootImpl$ViewRootHandler.handleMessage(ViewRootImpl.java:3915)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:156)
at android.app.ActivityThread.main(ActivityThread.java:6524)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:941)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:831)
Height of a WebView
I have a StackLayout
with a WebView
followed by some other controls. The WebView
should be as high as its contents.
Unfortunately the WebView
doesn't occupy any space at all unless I set its HeightRequest
.
For Android I found this SO question which uses the ViewTreeObserver
. I tried that in a custom renderer and I do get a height at some point in time, but when I tried to set the Layout of the WebView
, then the controls below it will not move down. It I call ForceLayout()
on the StackLayout
, then the method is called recursively (even though I removed the PreDraw handler already).
private void ViewTreeObserver_PreDraw(object sender, ViewTreeObserver.PreDrawEventArgs e)
{
var height = Control.ContentHeight;
if(height > 0 && height != Element.Height && Element.HeightRequest <= 0)
{
Control.ViewTreeObserver.PreDraw -= ViewTreeObserver_PreDraw;
Element.Layout(new Rectangle(Element.X, Element.Y, Element.Width, height));
((StackLayout)Element.Parent).ForceLayout();
}
}
How can I set the Height
of the WebView
to be as high as its content on Android and iOS?
Xamarin.Forms *needs* a hot reload system
Flutter is winning the hearts and minds of developers. I can see there is already jobs opening asking for flutter knowledge. Everywhere I read about flutter, people praise one functionality: "hot reload". I tested it and it is really nice. The thing is, flutter does not need it as much as XF. On flutter, things look the same on both devices so you do not spend so much time doing micro adjustments to the UI as on XF. The thing, I think, is that people learning need to see the changes they make to understand and learn. A person that does not know xaml will have a hard time even doing basic things look half decent. An experienced developer will have a hard time making things look exactly how he wants. It is possible but takes a lot of time.
I know about LiveXAML (http://www.livexaml.com/), I use it and it mostly works but it is not free. I know about XAMLator (https://github.com/ylatuya/XAMLator) and HotReload (https://github.com/AndreiMisiukevich/HotReload) but one only works on mac and the other I could not make work on android emulators. So, if this amazing developers are doing it, it is possible.
I think the most important thing for this feature is to be able to edit xaml on VS and see the change on emulators (android and iOS). It would be amazing if it could reload code changes too but only xaml will be a good start. It would be nice too if it could work without Visual Studio too, so I can edit .xaml files on VSCode and see the changes on my running app. This would make things so much better for experienced developers and for newcomers.
So my question is: when will Xamarin.Forms have an official hot reload system?
Is there a tinder-like interface available for Xamarin Forms that runs on IOS/Android/Windows Phone?
Any recommendations?
Xamarin forms Push notification
I want to add push notification in my xamarin forms project. Which method is the best option to implement push notification.
How to STOP Device.StartTimer mid flow
Hi all,
I have a number of buttons on my UI. Each button is intended to have 2 functions - a short press function and a long press function. When the user simply selects the button method_one is called. I want to implement the ability for the user to be able to press and hold the button for 5 seconds and call method_two.
I have been trying to use button.released to call method_one and use button.pressed to call Device.StartTimer for 5 seconds and method_two - which works but I cant figure out how to stop the timer called by onPress once the button is released and vice versa. I always receive both the button.pressed return and button.released return.
Please help
This is a snippet of what I have so far. The button.pressed is called from the XAML file
[code]`
public void OnAdminButtonPressed(object sender, EventArgs e)
{
Device.StartTimer(TimeSpan.FromMilliseconds(5000.0), () =>
{
DisplayAlert("pressed", "5 seconds", "ok");
return false;
});
}
public void OnAdminButtonReleased(object sender, EventArgs e)
{
Device.StartTimer(TimeSpan.FromMilliseconds(500.0), () =>
{
DisplayAlert("Released", "Immmediately Hopefully", "ok");
return false;
});
}
`
[/code]
Recording - Twitch Workshop: Build Your First Mobile App with C#, Xamarin, and the Cloud
Hi,
I was hoping someone has a recording of the "Twitch Workshop: Build Your First Mobile App with C#, Xamarin, and the Cloud" from blog.xamarin.com?
It was hosted by Jame Montemagno.
Kind Regards
The case for .NET Standard in favour of shared project for Xamarin.Forms
There is a bunch of information online about using .NET Standard for your Xamarin.Forms app, but I'm still confused as to why you would want to use one over the other. The main sources I have read through/watched:
1. Sharing Code Overview (MS docs)
2. .NET Standard 2.0 Support in Xamarin.Forms
3. .NET Standard and Xamarin.Forms for the .NET Developer
My history is I've been a Xamarin developer since the Novell days. Since the introduction of Xamarin.Forms (1.5ish?) I've always used it for creating apps over Xamarin.iOS and Xamarin.Android directly. I've never created a Forms app with PCL, always shared library. One thing I've relied heavily on is the ability to just go:
#if __IOS__
UIApplication.SharedApplication.StatusBarHidden = true;
#elif __ANDROID__
// Other things.
#endif
Being able to do this in the Forms code directly has made things nice and easy. Another example I have used it is in in my own HTTP REST classes, and the ability to use cookie containers in certain ways that would work on both platforms (bugs that may have been resolved now). I now know that in the first example I could create a dependency service called StatusBarActions or something. The second example I know now not to re-invent the wheel and I could just use RestSharp. It's just that one of the listed benefits of using shared code is the ability to use those pre-processor directives.
Likewise two of the main pros of .NET Standard are "Allows you to share code across multiple projects." and "Refactoring operations always update all affected references.". But wouldn't this still be true for a shared Forms app?
Lately I was playing around with converting some smaller in progress apps to be .NET Standard Forms apps. I really enjoy the simplicity of having my main NuGet packages (Xamarin.Essentials, Json.NET, FFImageLoading, sqlite-net-pcl, etc) in the Forms project itself. Its really nice to be able to update all packages at once. The package list also stays nice and short, although I think that's more to do that it doesn't list all package dependencies as new packages. I also liked that it forced me to write cleaner code. Things were good... until I tried Xamarin.Forms on macOS.
Although it is still in preview one of the first things I found that out of the box Xamarin.Essentials was not having a bar of it. It's just one of many packages that may not be supported. It made me think of another project I am working on, Onewheel Community Edition App. It relies heavily on the Plugin.BLE NuGet package that doesn't support macOS or UWP. If I wanted to add either of those platforms I now have to add it via a dependency service or something similar. Alternatively if I used a shared project I could just have a
#if __IOS__ OR __ANDROID__ etc.
I can see both being possible. One makes it easier when a core component is platform specific, but can also make it more of a pain in the case of Xamarin.Essentials when you may just want to use it to display the app version number.
So the real things I want to know are:
- Is it worth it?
- Are there any performance benefits of either?
- Are there binary size or binary security differences that are worth noting.
What are other peoples experience with it shared vs .NET Standard. Are there some other programming paradigms that I am not thinking of to make .NET Standard apps make more sense?
Native linking failed error in xamarin for GoogleSign
I am following this tutorial for GoogleSign in my project. https://www.pujolsluis.com/google-client-plugin-for-xamarin/ .Works fine in android. But getting Native linking failed errors while rebuild in ios.
Native linking error: clang: error: no such file or directory: '/Users/cybasetechnologies/Library/Caches/Xamarin/mtbs/builds/login2.iOS/0f92dcc98e9717a0d2643ed70077af70/obj/iPhone/Debug/mtouch-cache/FirebaseInstanceID'
Native linking error: clang: error: no such file or directory: '/Users/cybasetechnologies/Library/Caches/Xamarin/mtbs/builds/login2.iOS/0f92dcc98e9717a0d2643ed70077af70/obj/iPhone/Debug/mtouch-cache/FirebaseNanoPB'
Native linking failed. Please review the build log.
Native linking error: clang: error: no such file or directory: '/Users/cybasetechnologies/Library/Caches/Xamarin/mtbs/builds/login2.iOS/0f92dcc98e9717a0d2643ed70077af70/obj/iPhone/Debug/mtouch-cache/FirebaseCoreDiagnostics'
Native linking error: clang: error: no such file or directory: '/Users/cybasetechnologies/Library/Caches/Xamarin/mtbs/builds/login2.iOS/0f92dcc98e9717a0d2643ed70077af70/obj/iPhone/Debug/mtouch-cache/FirebaseAnalytics'
Native linking error: clang: error: no such file or directory: '/Users/cybasetechnologies/Library/Caches/Xamarin/mtbs/builds/login2.iOS/0f92dcc98e9717a0d2643ed70077af70/obj/iPhone/Debug/mtouch-cache/GoogleSignIn'
Native linking error: clang: error: no such file or directory: '/Users/cybasetechnologies/Library/Caches/Xamarin/mtbs/builds/login2.iOS/0f92dcc98e9717a0d2643ed70077af70/obj/iPhone/Debug/mtouch-cache/FirebaseCore'
Deleted bin and obj folders in both mac and visualstudio; clean and rebuid; still error persists.Please help..
[UWP] Changing image on button causes flicker
I typically change images on a button from one image to another, like enabled image to disabled greyscale image. Both of these images are the same size. When the image changes on Android/iOS, no problem. But when the image changes on UWP, it looks like the entire widget hierarchy is recalculated and redrawn causing a horrible flicker. I can understand this if the images were different sizes, but they aren't. Anybody experience this issue on UWP and have a good workaround?
publish app to win store
hello,
i would like to publish my uwp (beside the Microsoft store)
so services like
https://www.mobile9.com/
https://publishers.apps.bemobi.com/
now: Xamarin gives me the AppxBundle file type..
while the mentioned services asking for .cab file type..