Coder Social home page Coder Social logo

Comments (44)

SalehAlbuga avatar SalehAlbuga commented on August 11, 2024 1

Same here but it keeps throwing System.Aggregate exception

from parse-sdk-dotnet.

michstmatt avatar michstmatt commented on August 11, 2024 1

@Julien-Mialon I followed your steps, the app has been associated with the store, and I had it working in December, now it is randomly not working (I had not tested it for some time because I had got it working). Do you have any more suggestions?

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

Hello,
I added support for W10, you can check it there : https://github.com/Julien-Mialon/Parse-SDK-dotNET

from parse-sdk-dotnet.

techievbv avatar techievbv commented on August 11, 2024

@Julien-Mialon we are unable to Build the Parse.UWP project in VS 2015. Errors show HttpClient,Httprequest, etc. not accessible due to its protection level. Please check from your side and Suggest what we can do from our side. Thanks.

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@Vaibhavmalik3122 are you using the Parse nuget ? If yes, you should use the Parse source code directly. There is a small modification on Parse code in order to Parse.UWP use the internal types.

from parse-sdk-dotnet.

techievbv avatar techievbv commented on August 11, 2024

@Julien-Mialon @richardjrossiii we are able to build our project using the Parse.UWP reference , and sucessfully registered the username in the Installation table. But, when trying to send a Test push notification via Parse push portal, it is NOT able to send on the Windows 10 device.

from parse-sdk-dotnet.

richardjrossiii avatar richardjrossiii commented on August 11, 2024

@Vaibhavmalik3122 Yep, that sounds par for the course. Our backend does not currently support UWP push, and won't until we 'officially' support the UWP version of the SDK in an official capacity, sadly.

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@Vaibhavmalik3122 : that sound weird, I'm currently using it with an UWP app without any issues, push notifications work great. It uses the same system than WinRT app.

from parse-sdk-dotnet.

techievbv avatar techievbv commented on August 11, 2024

@Julien-Mialon could you please elaborate what small modifications on parse code were you talking about for Parse.UWP to use internal types in previous comments ?

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@Vaibhavmalik3122 : you can check my commit for uwp support there : Julien-Mialon@d6ac21a
Basically, modification in Parse code was in ParseClient.cs to add Parse.UWP to assembly list to use when looking for implementation of interfaces and in AssemblyInfo.Portable.cs add this line [assembly: InternalsVisibleTo("Parse.UWP")] to authorize Parse.UWP project to access internal types of Parse project.

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

@Julien-Mialon Could you provide sample solution to use Parse.UWP solution? I tried to use it by creating new UWP project and referencing the library. On app launch adding this line "await ParsePush.SubscribeAsync("");". But it throwing exception Unable to cast object of type 'Parse.ParseObject' to type 'Parse.ParseInstallation'. please help.

from parse-sdk-dotnet.

techievbv avatar techievbv commented on August 11, 2024

screenshot 90
@Julien-Mialon we have the latest pull of the repository and hence all the modifications you talked about are already there(check the screenshot attached).But still we are not able to send push Notifications from parse dashboard. We need to complete this as our official project deadline is coming to an end soon . Would really appreciate if you could assist us on this, maybe a skype call or teamviewer session would help. Looking forward.

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

I was able to fix cast exception by referencing Parse.dll and initializing ParseClient.Initialize("key", "key") method. But still no luck with push notifications from Parse console :(

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

I just tested this procedure, tell me if it works for you. Otherwise, we can plan teamviewer or skype session to debug that issue.

  • create vs project UWP W10
    01-project_creation
  • clone parsesdk github from my profile (with modification for UWP)
  • copy Parse & Parse.UWP directory in your project directory
    02-sdkcopy
  • right click your solution in vs2015 and import project Parse/Parse.csproj and Parse.UWP/Parse.UWP.csproj
  • Check that reference to Parse in Parse.UWP is correct
  • Add Parse and Parse.UWP in your app reference
    03-parseinstall
  • Check if everything build correctly
  • Go to dev.windows.com
  • Create a new app by reserving its name.
  • In my test it will be called "storeTestingStorm"
  • Look at your app overview and go to section "Services"/"Push notifications"
    04-storeinfo
  • Click on link "Live Services site"
  • Copy package SID & client secret to parse configuration page
    05-sid_clientsecret
  • Go to parse.com and create an app (I called it "testParseUWP")
  • Go to push section and scroll down to "Windows Push Credentials". Paste your app SID and client secret
    06-parseconfig
  • Go to keys section and copy "Application Id" & ".NET Key"
    07-parsekeys
  • Let's go back in VS 2015
  • right click on your app and associate it with your store app (store -> associate app with the store...)
  • In your app.xaml.cs constructor, add "ParseClient.Initialize(APPLICATION_ID, .NET_KEY)" where APPLICATION_ID and .NET_KEY are values from parse keys page.
  • Add "ParseInstallation.CurrentInstallation.SaveAsync();" just after this line
  • Launch your app and suspend it via "Lifecycle events" in VS toolbar (if not available, right click on VS top toolbar and enable "Debug Location") Do not stop the app
    08-lifecycle
  • Go back to parse.com and send a push notification
  • If everything went fine, it shows a push notification on your desktop after a few seconds

from parse-sdk-dotnet.

lukaszkalnik avatar lukaszkalnik commented on August 11, 2024

Great guide, thank you @Julien-Mialon! I have made only a small modification: I'm calling await ParseInstallation.CurrentInstallation.SaveAsync(); in async onLaunched() (and not in constructor), as it's an asynchronous method.

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

@Julien-Mialon Thanks for steps!
As from the steps you mentioned, I was not doing "ParseInstallation.CurrentInstallation.SaveAsync();"
but I will try with this change and see if it works. Thanks again!

from parse-sdk-dotnet.

lukaszkalnik avatar lukaszkalnik commented on August 11, 2024

Although right now I have the (small) problem that the push opens don't get tracked in Parse.com (only push sends - I see e.g. 2 pushes sent and 0 opened).

My code looks like this:

    public App()
    {
 (...)
        ParseClient.Initialize(app_id, app_key);
    }

(...)

    protected override async void OnLaunched(LaunchActivatedEventArgs e)
    {
(...)
        await ParseInstallation.CurrentInstallation.SaveAsync();

        // By convention, the empty string is considered a "Broadcast" channel
        // Note that we had to add "async" to the OnLaunched definition to use the await keyword
        await ParsePush.SubscribeAsync("");

        // Track this application being launched
        await ParseAnalytics.TrackAppOpenedAsync(e);
    }

Any suggestions?

Thanks so much!

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

I tried with above steps but still cannot send push successfully, this is what i see on Parse dashboard
image

[Update]
I was having incorrect package manifest file, associating with store again, it solved.
Thanks

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@lukaszkalnik @mehul9595 about the opened notification count, it's an issue from Parse. I just tried with the WinRT sdk (nuget 1.7.0), it doesn't work either. The sdk expect to receive a json with "push_hash" field to track push notification open count. And this field is not sent by Parse backend, just receiving something like {"alert":"push notification message"}

from parse-sdk-dotnet.

lukaszkalnik avatar lukaszkalnik commented on August 11, 2024

@Julien-Mialon cool, thanks so much for the information! You are really helping a lot, I appreciate it!

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@lukaszkalnik I just opened a dedicated issue (#162) for the problem with the missing field in json notification.

from parse-sdk-dotnet.

techievbv avatar techievbv commented on August 11, 2024

@Julien-Mialon Notifications are working good. Thanks for the steps. But, one issue is bugging us , whenever the app is in Foreground state , the toast notification banner does not appear , even after the app is closed , no notification appears in Action center. The ParsePush.PushNotificationReceived is hit everytime , but on the OS level no notification shows up.

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@Vaibhavmalik3122 I just tested foreground notifications and it works without issue, can you check with the project available there : https://github.com/Julien-Mialon/Parse.UWP.Sample, you just have to associate the app with the store and write your Parse appid and .net key in Constants.cs.

If it's doesn't work for you, check if in the event handler of PushNotificationReceived, args.NotificationType == "Toast" and args.Cancel is not set to true.

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@michstmatt If it's randomly working, I can not really think of something from the app that can block this. But I saw some issue from Windows notification service working sometimes.

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

@Julien-Mialon I was wondering if its possible to send 'adaptive toast notificatoins' which are supported by win10 adaptive templates (ref: http://blogs.msdn.com/b/tiles_and_toasts/archive/2015/07/08/toast-notification-and-action-center-overview-for-windows-10.aspx)
As I can see from Parse dashboard it only allows to send Plain Text or Json data into Push notification. Is there additional things needs to be done in order to these custom push notifications?

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@mehul9595 Not supported for now but I think there is another opened issue about that. #137

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

@Julien-Mialon well exactly what I was looking for. thanks again!

from parse-sdk-dotnet.

michstmatt avatar michstmatt commented on August 11, 2024

@Julien-Mialon I created a new project, I found out that when I copy the Package SID its adds a blank character at the end. Went back into my original projects parse push settings, sure enough blank character at the end, fixed it and its working. Thanks for making this library!

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

@Julien-Mialon is it possible to send push notification with deeplink? if yes, how can it be handled?

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@mehul9595 I think you can do that by sending json content in your notification and then parsing this content in your application. You can embed deeplink info in this json.

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@lukaszkalnik @mehul9595 I just implemented support to track opened notification count in WinRT & winPhone (#164) and did the same modification on my uwp fork you can find here : https://github.com/Julien-Mialon/Parse-SDK-dotNET/tree/features/uwpSupport

from parse-sdk-dotnet.

lukaszkalnik avatar lukaszkalnik commented on August 11, 2024

Thanks @Julien-Mialon, I have just tested the opened pushes reporting and it works flawlessly. Great job!

The only weird thing is that now I get an error when starting the Release build on a Windows 10 Mobile device:
0x76CCE031 (combase.dll) in ApplicationName.exe: 0xC000027B: An application-internal exception has occurred (Parameter: 0x038E60F8, 0x00000002).
When I start a Debug build though everything is working correctly.

On a Windows 10 PC both Debug and Release builds are working correctly.

from parse-sdk-dotnet.

lukaszkalnik avatar lukaszkalnik commented on August 11, 2024

Hmm, I just checked and with your previous version of the SDK I have actually the same problem (Release build not working on a smartphone). Probably this is unrelated to your changes then.

Thanks for your awesome help!

from parse-sdk-dotnet.

SalehAlbuga avatar SalehAlbuga commented on August 11, 2024

@Julien-Mialon Thank you, great job! I have a problem with receiving push notifications. After implementing ParsePush.ParsePushNotificationReceived, Parse.UWP throws System.NullReferenceException when the app receives a notification

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

@SamAlbuga I think you have to subscribe to 2 event, ParsePushNotificationReceived and PushNotificationReceived.

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

@Julien-Mialon is it under master yet? which branch do you suggest to use?

from parse-sdk-dotnet.

Julien-Mialon avatar Julien-Mialon commented on August 11, 2024

For uwp, you can use the branch "features/uwpSupport" on my repo. Not merged with official parse repo for now. https://github.com/Julien-Mialon/Parse-SDK-dotNET

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

cool, I was using master branch from your repo so far working fine for me without issues. I will change to your feature branch.

from parse-sdk-dotnet.

SalehAlbuga avatar SalehAlbuga commented on August 11, 2024

@Julien-Mialon Yes that worked perfectly. Thank you :)

from parse-sdk-dotnet.

techievbv avatar techievbv commented on August 11, 2024

Hey @Julien-Mialon , when app is in foreground, how can we create a custom toast notif. for the user such that, when clicked, a custom event can be hit instead of Onlaunched. for reference , WhatsApp for WP is a good example.

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

@Vaibhavmalik3122 I don't think if that's possible, seems it is an part of enhancement, 137 . Once interactive notifications is supported this can be achieved.

from parse-sdk-dotnet.

mehul9595 avatar mehul9595 commented on August 11, 2024

I found a case where push notification is sent during device is power off, notifications are not delivered on tablet device when tablet is powered on.
On Windows phone, push notification is seen when device is powered on.
Any clue?

from parse-sdk-dotnet.

lukaszkalnik avatar lukaszkalnik commented on August 11, 2024

@Julien-Mialon we are currently testing and turns out I cannot start the app with Parse SDK in Release mode on a Lumia 930 phone. It starts in Debug mode though... I get the following exception:
Exception at 0x777AE031 (combase.dll) in App.exe: 0xC000027B: An application-internal exception has occurred (Parameter: 0x00894FC8, 0x00000002)

update it happens on the ParseClient.Initialize call

from parse-sdk-dotnet.

TobiasPott avatar TobiasPott commented on August 11, 2024

Based on the latest version in the master branch using the Parse SDK on UWP platforms does work.
If any specific problem re-occurs with the latest version from the master branch, feel free to create a new issue to discuss possible solutions.

from parse-sdk-dotnet.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.