windows-8

Where are the possible VisualStates for Windows 8 Metro controls documented?

不羁岁月 提交于 2019-12-08 17:28:32
问题 When writing a custom ControlTemplate (XAML) for a Win 8 Metro control we need to use the VisualStateManager to update the control according to VisualState transitions. I see the below sample all over MSDN, but I can't find where the VisualStateGroup "CommonStates" is documented and what other VisualStates are defined other than "PointerOver" and "Normal"? Do you have to go dig in the SDK to find the default ControlTemplate for a button? If so, where? <ControlTemplate TargetType="Button">

Go to declaration does not work in resharper on vs2005/2008/2010/2012 on win8 64 bit?

与世无争的帅哥 提交于 2019-12-08 17:25:25
问题 I have a User class which I created. However when i CTRL+left mouse click on it's instances , it suppose to go to the class " User " itself : But it doesn't. ( it should. in vs2010 it works). But if I right click on it and choose : "goto declaration" It does work : and redirects me to : (the User Class) resharper ver : 7.1.3000.2254 vs 2012 pro Here are the current settings : How can I fix it ? Edit. After another check, it's also with vs2010. I guess the problem is compatibility with win8

Suspend camera when user switches away from app, and resume camera when user switches back to app

守給你的承諾、 提交于 2019-12-08 17:03:36
Currently, I would like to suspend my camera when user switches away from my app, and resume camera when user switches back to app I am referring to Application lifecycle (Windows Store apps) (Windows) However, Suspending | suspending event isn't being triggered immediately once the user switches away from my app. You need to wait for few seconds (Or it will not trigger at all if OS decides not to do so). So, how I can know, when I should run my camera suspension code when user switches away from my app. If I referring to Media capture using capture device sample , they are using Windows.Media

How should a Windows 8 Metro Application connect to a central database?

烂漫一生 提交于 2019-12-08 16:18:14
问题 How should a Windows 8 Metro application connect to a central database? I've read about local storage, but I haven't read anything about connecting to a central database. Obviously, this architectural design decision needs to support the disconnected scenario. WCF web services seem to make sense. But even if they do make sense, should we really create separate methods for all read/write operations? Or are OData WCF services the way to go? It seems like tablet software architecture should be

Portable class library and .NET ConcurrentDictionary

こ雲淡風輕ζ 提交于 2019-12-08 15:45:36
问题 Looking at http://msdn.microsoft.com/en-us/library/dd287191(v=vs.110).aspx, it seems that ConcurrentDictionary and all of its friends in the System.Collections.Concurrent namespace are available for use in a Portable Class Library. However, when I create either an F# or C# Portable Class Library, even if I explicitly add a reference to mscorlib.dll , the compilation fails when using ConcurrentDictionary . Why? 回答1: The term "Portable" should be loosely applied right now. When you create the

Microsoft Advertising SDK for Windows 8 RTM causes Access Denied Error

巧了我就是萌 提交于 2019-12-08 15:27:25
问题 Note these things: I have Windows 8 RTM. I have Visual Studio 2012 RTM. I have Microsoft Advertising SDK RTM. All I do is: Add a reference to it. The Error: System.UnauthorizedAccessException Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED)) at Microsoft.Expression.DesignHost.Isolation.Remoting.STAMarshaler.WaitForCompletion(NestedCallContext nestedCallContext, BlockingCall call, WaitHandle timeoutSignal) at Microsoft.Expression.DesignHost.Isolation.Remoting.STAMarshaler

VariableSizedWrapGrid and WrapGrid children size measuring

时光总嘲笑我的痴心妄想 提交于 2019-12-08 15:09:14
问题 Both VariableSizedWrapGrid and WrapGrid have strange measuring - they measure all children based on the first item. Because of that, the following XAML will clip the third item. <VariableSizedWrapGrid Orientation="Horizontal"> <Rectangle Width="50" Height="100" Margin="5" Fill="Blue" /> <Rectangle Width="50" Height="50" Margin="5" Fill="Red" /> <Rectangle Width="50" Height="150" Margin="5" Fill="Green" /> <Rectangle Width="50" Height="50" Margin="5" Fill="Red" /> <Rectangle Width="50" Height=

How to open pdf files in windows 8 application using c#?

故事扮演 提交于 2019-12-08 14:17:28
How to read the pdf files in windows 8 app .In my windows 8 application how to open the pdf files . In manifest file i wrote the below code. <Extensions> <Extension Category="windows.fileTypeAssociation"> <FileTypeAssociation Name="pdf"> <SupportedFileTypes> <FileType>.pdf</FileType> </SupportedFileTypes> </FileTypeAssociation> </Extension> </Extensions> and code behind. string imageFile = @"Images\DX730_EN.pdf"; var file = await Windows.ApplicationModel.Package.Current.InstalledLocation.GetFileAsync(imageFile); if (file != null) { // Set the option to show the picker var options = new Windows

Open Windows Explorer from Windows Store app

谁说我不能喝 提交于 2019-12-08 13:46:11
问题 It's actually a simple question, I have a n index of saved locations of my local network, like \\server\file01 . I'm showing the user a grid with these entries and I want to open Windows Explorer when the user clicks on an item (path). According to the documentation of launchUriAsync, it is possible to do so since they state: You must specify the privateNetworkClientServer capability in the manifest in order to launch intranet URIs, for example a file:/// URI pointing to a network location.

Crop image with rectangle

时间秒杀一切 提交于 2019-12-08 13:37:31
问题 I have a Image and I want crop it by using a rectangle, code below is the code I put a image and draw a rectangle at middle of the image: MainPage.Xaml: <Canvas x:Name="canvas" HorizontalAlignment="Center" VerticalAlignment="Center" Width="340" Height="480" Background="Blue"> <Image x:Name="photo" HorizontalAlignment="Center" VerticalAlignment="Center" ManipulationMode="All"> <Image.RenderTransform> <CompositeTransform/> </Image.RenderTransform> </Image> <Path Stroke="Black" StrokeThickness=