windows-8

Check if user added new music on Windows Phone 8.1

六月ゝ 毕业季﹏ 提交于 2020-01-02 05:46:09
问题 I'm trying to find out if a user added new music to the Music folder on the phone since app was last used. I try to do this by checking the DateModified of the Music folder (which updates correctly on the computer when adding new music to the phone): async void GetModifiedDate () { BasicProperties props = await KnownFolders.MusicLibrary.GetBasicPropertiesAsync(); Debug.WriteLine("DATEMODIFIED: " + props.DateModified.ToString()); } Unfortunately this returns: DATEMODIFIED: 1/1/1601 1:00:00 AM

Make the button transparent on mouse over

眉间皱痕 提交于 2020-01-02 05:42:07
问题 I'm building a metro style application using Microsoft Visual Studio Express 2012. I am very new to this applications and I need help. I have defined a button in XAML with button background is set from an image. At mouse over the button changes it background to blank. I want to change it an make the image about 50% transparent on mouse over. Is that possible? Any help? Thank you. I have declared the button as follows: <Button Height="100" Width="100" Margin="0,0,0,0"> <Button.Background>

Windows 8 - low latency audio

跟風遠走 提交于 2020-01-02 04:40:48
问题 I'm considering developing an app for the upcoming Windows 8. The app requires low-latency audio recording and playback, and I'm trying find out whether the OS will support that (as opposed to other platforms). So what I'd like to know is: Is there a low-latency audio API in Windows 8? Will it be supported on platforms other than PC (e.g. tablets)? Thanks! 回答1: WASAPI was introduced with Windows Vista as the low-latency audio API. It is available both to desktop and to Metro style

Running a metro app headlessly

三世轮回 提交于 2020-01-01 12:44:33
问题 I've hit a bit of a roadblock, and I'm hoping someone can help! I've written a metro application that serves as a unit test runner, and I now need to be able to call this application headlessly so that it can be used for validation in the build process. The way the metro app works is it runs a bunch of unit tests, generates an XML file that contains the test results, and displays the results to the user. Ideally, I would have a simple script that would run the metro app, execute the tests,

Check if PasswordVault/credential manager has app data at load

喜夏-厌秋 提交于 2020-01-01 09:59:55
问题 Hey I'm using PasswordVault for storing user credentials in my windows 8 app. What I want the app to do on loading is check to see if the PasswordVault/credential manager already has a stored value for my app. if it don't don't I want it to stay on the page so the user can login, but if the credentials are already there then I would like it to go straight to page 2. I tried using the following code: private Windows.Security.Credentials.PasswordCredential GetCredentialFromLocker() { Windows

Remove focus on first textbox

会有一股神秘感。 提交于 2020-01-01 09:08:25
问题 In our Windows Store app we have a textbox, and when the application starts this textbox always get focus. In a desktop scenario that's no problem, but on a tablet device this focus will directly open the onscreen keyboard which is not a scenario that we want. We tried to set the focus on another control programmatic with the .Focus(FocusState) method, but somehow the focus is set back to the textbox. We have both set the focus in the LoadState or the OnNavigatedTo method. Only when we have

C# PCL Reading from File

只愿长相守 提交于 2020-01-01 08:43:12
问题 So I'm writing a portable class library that targets .NET 4.5, Windows 8 and Windows Phone 8. I'm trying to read from a text file that is part of the project as build content. I see that StreamReader is available in PCL's but I can't seem to find out how to get the stream from a file, given a file path. If anyone could point me to the right structures I'd appreciate it. Also if you could give direction for XML files, too. I'm only reading text files right now, but I'm going to be working in

ListBox margin is not the same in Windows 7 and Windows 8

二次信任 提交于 2020-01-01 08:41:55
问题 I have styled an WPF ListBox. I'm developing under Windows 8. After setup the style to be as follows (see image), when I test the application in Windows 7, the margin is not the same. As you can see in the imagen the separation between nodes is 1px in Windows 8, but 0 px in Windows 7. Do you know why is this, and how to solve it? Thanks in advance. 回答1: I actually managed to get rid of it myself, it looks like it's ListViewItem style that's being changed by Windows8, adding a style to the

HDD serial number flipped every 2 bytes in Windows XP, Vista and 7 but not in Windows 8

荒凉一梦 提交于 2020-01-01 08:26:08
问题 I need to get HDD serial number to use it as a key for licensing a software. I used diskid32 code in this url: http://www.winsim.com/diskid32/diskid32.html It used the DeviceIoControl Win32 API with the IO control code of IOCTL_STORAGE_QUERY_PROPERTY . It worked. However, when I double check with the actual serial number printed on the HDD itself, I found that every 2 bytes of the number was flipped. A simple solution could be to simply flip the bytes back. It worked in Windows XP, Vista and

How to disable the Windows 8 Charms bar programmatically?

霸气de小男生 提交于 2020-01-01 06:39:35
问题 I need to create an application that will run full-screen on Windows 8 and which the user shouldn't be able to exit easily. Since the application will be running on computers or tablets with only tactile input, I was going to create a chromeless and top-most WPF application, which could only be closed if a keyboard is connected. The problem is that the app switching bar on the left and the charms bar on the right can still be opened without a keyboard and would allow users to exit the