×

Discussion Board

Page 2 of 2 FirstFirst 12
Results 16 to 23 of 23
  1. #16
    Super Contributor
    Join Date
    Nov 2010
    Posts
    1,264

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    I have included http at both the places i.e in page2.xaml.cs and sentoast.aspx.cs


    Problem solved.





    Ok I got it.

    Now I found where there is a error and what is ?


    The error is at Page2.xaml.cs




    and it of url relate pleas correct it.



    /*
    Copyright (c) 2011 Microsoft Corporation. All rights reserved.
    Use of this sample source code is subject to the terms of the Microsoft license
    agreement under which you licensed this sample source code and is provided AS-IS.
    If you did not accept the terms of the license agreement, you are not authorized
    to use this sample source code. For the terms of the license, please see the
    license agreement between you and Microsoft.

    To see all Code Samples for Windows Phone, visit http://go.microsoft.com/fwlink/?LinkID=219604

    */
    using Microsoft.Phone.Controls;
    using Microsoft.Phone.Tasks;



    namespace sdkToastNotificationCS
    {
    public partial class Page2 : PhoneApplicationPage

    {
    public Page2()
    {
    InitializeComponent();
    }
    /// <summary>
    /// Event handler for when this page is navigated to. Looks to see
    /// if the tile exists and set the check box appropriately.
    /// </summary>
    /// <param name="e"></param>

    protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
    {
    base.OnNavigatedTo(e);

    //ToDo: make sure not to open again the browser when returning to the app
    WebBrowserTask webBrowserTask = new WebBrowserTask();
    //webBrowserTask.Uri = new Uri(this.NavigationContext.QueryString["urlValue"], UriKind.Absolute);
    // webBrowserTask.Uri = new Uri("http://www.yupptv.com/Movies/Movies.aspx", UriKind.Absolute);

    webBrowserTask.Uri = new Uri(this.NavigationContext.QueryString["http://www.yupptv.com/Movies/Movies.aspx"], UriKind.Absolute);
    webBrowserTask.Show();

    }
    }
    }


    The type or namespace uri could not be found as attached in the error screenshot URI scrshot2.jpg
    Last edited by GTO_India; 2013-08-14 at 10:01.

  2. #17
    Super Contributor
    Join Date
    Nov 2010
    Posts
    1,264

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    theothernt all my issues are fixed except It is accepting very small Title and subtitle and showing payload error when long msgs are given.

    Earlier when App is running it used to show long messages atleast.


    Now when the app is running or not runnng.It is not accepting more than 3 words in title and subtitle

  3. #18
    Nokia Developer Champion
    Join Date
    Feb 2013
    Location
    Dublin, Ireland
    Posts
    568

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    Quote Originally Posted by GTO_India View Post
    Now when the app is running or not runnng.It is not accepting more than 3 words in title and subtitle
    Text1 and Text2 should allow very long lines of text, but Param (ie. URI) does have a length limit. All I can suggest is trying to send different length message and see where the limit is?

  4. #19
    Super Contributor
    Join Date
    Nov 2010
    Posts
    1,264

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    Ok Iam all done when I integrate all the method in my App ie Main application"YuppTV" in which push notifications to be sent I got the error in Page2.xaml.cs


    Error 2 'Microsoft.Phone.Tasks.WebBrowserTask' does not contain a definition for 'Uri' and no extension method 'Uri' accepting a first argument of type 'Microsoft.Phone.Tasks.WebBrowserTask' could be found (are you missing a using directive or an assembly reference?) E:\Windows projects\YuppTV\Packages\Page2.xaml.cs 27 28 YuppTV



    What does it mean by


    My page2.xaml.cs is as follows

    using Microsoft.Phone.Controls;
    using Microsoft.Phone.Tasks;
    using System;
    using System.Windows;
    using Microsoft.Phone.Notification;
    using System.Text;




    namespace YuppTV
    {
    public partial class Page2 : PhoneApplicationPage
    {
    public Page2()
    {
    InitializeComponent();
    }


    protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
    {
    base.OnNavigatedTo(e);

    //ToDo: make sure not to open again the browser when returning to the app
    WebBrowserTask webBrowserTask = new WebBrowserTask();
    webBrowserTask.Uri = new Uri("http://www.yupptv.com/Movies/Movies.aspx", UriKind.Absolute);
    webBrowserTask.Show();

    }
    }




    }

  5. #20
    Nokia Developer Champion
    Join Date
    Feb 2013
    Location
    Dublin, Ireland
    Posts
    568

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    Put that error message into your favourite search engine and you should come up with a solution. The issue is very easy to fix.

  6. #21
    Super Contributor
    Join Date
    Nov 2010
    Posts
    1,264

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    It says

    It sounds like you need to update your development machine to the latest Windows Phone SDK :-

    http://www.microsoft.com/download/en....aspx?id=27570

    Or if you have already done this, upgrade your project to 7.1.

    Hope this helps.


    But already I have updated my development machine to the latest Windows Phone SDK.


    Yes I have upgraded my actual project to 7.1



    Now a new error


    Error 1 'GestureEventArgs' is an ambiguous reference between 'System.Windows.Input.GestureEventArgs' and 'Microsoft.Phone.Controls.GestureEventArgs' E:\Windows projects\YuppTV\Packages\LivePlayer.xaml.cs 225 57 YuppTV

    at LivePlayer.xaml.cs

    using System.Linq;
    using System.Net;
    using System.Windows;
    using System.Windows.Controls;
    using System.Windows.Documents;
    using System.Windows.Input;
    using System.Windows.Media;
    using System.Windows.Media.Animation;
    using System.Windows.Shapes;
    using Microsoft.Phone.Controls;
    using System.IO.IsolatedStorage;
    using Microsoft.Web.Media.SmoothStreaming;
    using System.Windows.Threading;
    using System.Diagnostics;

    ;;;;;;




    ;;;;
    ;;;;



    ;;;;;
    private void player_MediaEnded(object sender, RoutedEventArgs e)
    {
    play.Visibility = Visibility.Visible;
    pause.Visibility = Visibility.Collapsed;
    }
    private void GestureListener_Tap(object sender, GestureEventArgs e)
    {
    if (StackPanel1.Visibility.Equals(System.Windows.Visibility.Collapsed))
    {
    StackPanel1.Visibility = System.Windows.Visibility.Visible;
    }
    else
    {
    StackPanel1.Visibility = System.Windows.Visibility.Collapsed;
    }
    }
    Last edited by GTO_India; 2013-08-14 at 14:59.

  7. #22
    Super Contributor
    Join Date
    Nov 2010
    Posts
    1,264

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    It is also giving another error at Page2.xaml


    Error 2 Could not load file or assembly 'Microsoft.SilverlightMediaFramework.Compatibility.Phone, Version=2.2010.1001.1, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified. E:\Windows projects\YuppTV\Packages\Page2.xaml 1 1 YuppTV

  8. #23
    Super Contributor
    Join Date
    Nov 2010
    Posts
    1,264

    Re: How to show my total toast message in 2 to 3 lines etc when teh App is not runni

    Ok I got it Iam thankful verymuch for your support given.

    After upgrading my project and editing


    as private void OnDoubleTap(object sender, Microsoft.Phone.Controls.GestureEventArgs e)


    All my problems are fixed.


    Please go thru my other query for future tasks


    http://developer.nokia.com/Community...-time-duration

Similar Threads

  1. [moved] Toast Message in Windows Phone
    By somnathbanik in forum Windows Phone General
    Replies: 5
    Last Post: 2013-10-07, 13:36
  2. How to create event handler for button in Java ME
    By abhishekpal in forum Mobile Java General
    Replies: 3
    Last Post: 2013-05-30, 14:33
  3. Button click handler
    By phpgenerator in forum Symbian User Interface
    Replies: 4
    Last Post: 2011-01-19, 11:00
  4. Qt N8/mobile version of Android Toast?
    By franklovecchio in forum Qt
    Replies: 0
    Last Post: 2010-12-03, 22:20
  5. Replies: 6
    Last Post: 2004-05-13, 06:39

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×