windows-phone-7.1

How to attain virtualization in listbox with different layouts of Windows Phone App

佐手、 提交于 2019-12-12 05:45:35
问题 I have a List box with different user controls in WP7 app. How should I apply virtualization with Virtualization Mode as "recycling". Because when I applied the results are not smooth. There seem to be a jerk while scrolling. In Android, for the same scenario the User Controls will be tagged their recycling is handled preoperly since they are perfectly distinguished and here any such option is not given. Any idea how to handle this scenario? I tagged silverlight and c# becuase WP7 has both

Using Obscure and UnObscure…Am I doing this right?

微笑、不失礼 提交于 2019-12-12 04:17:10
问题 WP 7.5 app. I have two Storyboard animations - one on image and another on Text. Issue1: When I move to next page and go back, the image and text blinks. Solution1: So I added OnNavigateFrom and explicity Stop the animations and also reset any properties involved in animations to 0. Issue2: Now say the screen goes to lock-mode and when I unlock it, since I set opacity of one of my element to 0 in OnNavigatedFrom the element is hidden, which actually should be visible until the user moves to

HttpWebRequest “POST” returning server error (Exception)

▼魔方 西西 提交于 2019-12-12 04:04:58
问题 I'm trying to call the google URL shortner API from a WP7 app, I tried first on a Console Application by doing this: var httpWebRequest = (HttpWebRequest)WebRequest.Create("https://www.googleapis.com/urlshortener/v1/url"); httpWebRequest.ContentType = "application/json"; httpWebRequest.Method = "POST"; using (var streamWriter = new StreamWriter(httpWebRequest.GetRequestStream())) { string json = "{\"longUrl\":\"http://www.google.com/\"}"; Console.WriteLine(json); streamWriter.Write(json); }

Load a listbox with two textblock from a database with LINQ windows phone

时光毁灭记忆、已成空白 提交于 2019-12-12 02:33:56
问题 I am trying to load a listbox with two textblock from a database with LINQ in windows phone 7.1. My problem is that data does not appear in the textblock. Maybe the problem is in the xaml code, but I don´t know. This is the xaml code: <controls:Pivot Title="CEBADEROS"> <controls:PivotItem Header="Entradas"> <ListBox x:Name="EntradasList" Margin="0,0,-12,0"> <ListBox.ItemTemplate> <DataTemplate> <StackPanel Margin="0,0,0,17"> <TextBlock Text="{Binding Fecha_entrada}" TextWrapping="NoWrap"

WP7 - HLSL effects from WPF/Silverlight

别等时光非礼了梦想. 提交于 2019-12-12 02:28:35
问题 I KNOW I did this in WP7 (not WP7.1) and I can't figure out what I did. I'm using this Effect Library I'm using this Effect Build Task and Template So basically I opened my WP7 csproj file in notepad add added the following lines: Under Project Root <UsingTask TaskName="ShaderBuildTask.PixelShaderCompile" AssemblyName="ShaderBuildTask, Version=1.0.3072.18169, Culture=neutral, PublicKeyToken=44e467d1687af125" /> <Target Name="EffectCompile" Condition="'@(Effect)' != '' "> <PixelShaderCompile

WP7, WP8 How to set several ResourceDictionaries to use custom FontFamilies

喜你入骨 提交于 2019-12-12 01:57:24
问题 I want to set custom fonts for some controls, so if I set a font inside the only one ResourceDictionary and use it in styles then everything works just fine . But this approach is not fine for me, because I need to have font declarations in a separate dictionary then styles that are using them. In App.xaml I have made several Resource Dictionaries <Application ...> <Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="Resources

image stream to base64 string in WP7

邮差的信 提交于 2019-12-12 01:32:25
问题 in my wp7 application i am selecting image from media library and i want to get base64 string of that image because i am sending it to my wcf service to create image on server. the code for getting base64 string is as follows: void taskToChoosePhoto_Completed(object sender, PhotoResult e) { if (e.TaskResult == TaskResult.OK) { fileName = e.OriginalFileName; selectedPhoto = PictureDecoder.DecodeJpeg(e.ChosenPhoto); imgSelected.Source = selectedPhoto; int[] p = selectedPhoto.Pixels; int len = p

Showing error in release mode

时光怂恿深爱的人放手 提交于 2019-12-12 01:20:12
问题 In my application I had added Listpicker and Datepicker with proper DLL and Namespaces while I build in debug mode it runs well but in Release mode it is showing error in the generated page(Mainpage.g.i.cs). The error message is "The type or namespace name 'ListPicker' does not exist in the namespace 'Microsoft.Phone.Controls' (are you missing an assembly reference?) 回答1: This happened to me too on one project, and all I did was change from debug to release. I fixed it by simply removing the

WP7 ScrollViewer programatically scroll a background ScrollViewer in sync with front ScrollViewer

送分小仙女□ 提交于 2019-12-12 00:43:23
问题 I am trying to create an animation whereby when a user Scrolls the "FrontScroll" the app automatically scrolls "BackgroundScroll", of the same size, to the same offset at the same rate. Layered in-between the front and background scroll is an image I would like to remain static. The middle image only fills 1/4 of the screen, the rest of the image is transparent in the png. I am trying to create the effect that other images appear gradually over and behind the static image when the user

Error adding System.Data.Services.Client reference to windowsphone7.1 sdk

眉间皱痕 提交于 2019-12-11 20:39:42
问题 After asking my first question Windows Phone 7.1 app accessing Azure Storage directly, I download wp7facebookazure wp7.0 sample. After i downloaded wp7facebookazure sample from http://wp7azurequickstarts.codeplex.com/releases/view/65745, I compiled WindowsPhoneCloud.StorageClient library, I see it is using custom System.Data.Services.Client library. After I change the sample to use windowsphone7.1 sdk and then I add System.Data.Services.Client reference, I get following error: Microsoft