标签: windows-10-universal

在Windows 10通用应用程序中尝试使用DllImport加载DLL时出错

我正在创建Windows应用程序.这是针对Windows 10平台,它是通用Windows应用程序,我使用https://github.com/phatware/WritePadSDK在Windows应用程序中创建写作伙伴.现在我所做的是在我从github下载的解决方案中,我添加了一个针对windows通用应用程序的项目.我已经添加了运行项目所需的所有必需的引用,但每次运行Windows 10通用项目时我都会收到错误无法加载DLL'WinRT_CPPLayer.dll':找不到指定的模块.(来自HRESULT的异常:0x8007007E).

请帮忙

谢谢.

windows dll dllimport windows-10-universal

9
推荐指数
0
解决办法
350
查看次数

从Windows 10 Universal App Platform中的Alt-tab任务栏隐藏应用预览

我正在开发一个应用程序,我想当用户处于平板电脑模式时,当你按下"alt + tab"并显示打开的应用程序时,从一个应用程序切换到另一个应用程序以显示黑屏.我想要显示应用程序的"myTrip"屏幕截图,而不是显示黑屏.

在此输入图像描述

我知道WPF我们ShowInTaskbar = false在Windows 10 Universal App Platform中没有这样的东西.

我到目前为止尝试过:

Window.Current.CoreWindow.VisibilityChanged += CoreWindow_VisibilityChanged;

  private void Current_VisibilityChanged(object sender, VisibilityChangedEventArgs e)
    {
        var parentGrid = RootPanel();
        parentGrid.Visibility = e.Visible ? Visibility.Visible : Visibility.Collapsed;
    }
Run Code Online (Sandbox Code Playgroud)

但应用程序的快照图像是在调用这些事件之前拍摄的.有什么想法怎么做?

问候.

c# win-universal-app windows-10-universal

8
推荐指数
1
解决办法
416
查看次数

UWP Win 10 Tinder在Pivot内刷卡?

首先,这是我的最小版本项目的链接.
我正在尝试在我的Pivot页面内创建一个tinder swipe卡类型的效果.在参考Lightstone Carousel之后能够创建一个C#并在XAML其中工作Grid.
现在我的问题是自定义控件应该进入一个Pivot元素.由于pivot的默认操作会覆盖我的控件在TOUCH设备上的滑动操作.如何向下冒泡到我的自定义控件.根据@Romasz的回答,
无法Touch在Win 10应用程序中找到. 任何其他具有类似效果的控制建议也将受到赞赏. XAML

<Pivot>    
        <PivotItem>
            <Grid Background="White">
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="3*"/>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
                <Grid Grid.Row="0" Background="LightBlue"/>
                <Grid Grid.Row="1" >
                    <ctrl:Carrousel  Grid.Row="0" Background="Green"   ItemsSource="{Binding Datas}" 
                        SelectedIndex="0"
                        TransitionDuration="2500" 
                        Depth="700" 
                        MaxVisibleItems="15"
                        x:Name="CarrouselElement"
                        Rotation="50" 
                        TranslateY="0"
                        TranslateX ="1200">
                        <ctrl:Carrousel.EasingFunction>
                            <CubicEase EasingMode="EaseOut" />
                        </ctrl:Carrousel.EasingFunction>
                        <ctrl:Carrousel.ItemTemplate>
                            <DataTemplate>
                                <Grid Background="Red">
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="Auto"/>
                                        <RowDefinition Height="Auto"/>
                                    </Grid.RowDefinitions>
                                    <Border BorderBrush="#bfbfbf" BorderThickness="1">
                                        <Grid HorizontalAlignment="Stretch">
                                            <Grid.RowDefinitions> …
Run Code Online (Sandbox Code Playgroud)

c# xaml win-universal-app uwp windows-10-universal

8
推荐指数
1
解决办法
663
查看次数

如何在UWP App中创建信息丰富的Toast通知

在我的应用程序中,我想告知用户特定操作何时执行,例如记录更新成功或添加了新记录,但是没有内置控件可以显示此类信息.是否有类似于UWP的Android Toast.makeText?

c# windows-runtime uwp windows-10-universal

8
推荐指数
1
解决办法
9467
查看次数

有没有办法在不进行每次部署的情况下运行Xamarin UWP项目

在运行之前,我是否始终必须单击部署UWP应用程序?这是两个步骤,我只想表演一个.

我刚从Visual Studio 2015更新2中的跨平台,Windows,Visual C#模板列表中创建了一个空白Xaml应用程序(Xamarin.Forms Portable)新项目.有Droid,iOS和UWP项目(通用Windows) )以及其他一些人.我将UWP应用程序设置为启动项目并尝试运行它(通过单击本地计算机上的绿色箭头或按F5),但我收到一条错误消息,说我需要先部署.如果我右键单击该项目,然后选择部署它成功部署,然后如果我运行它成功运行.如果我停止执行,进行修改,然后再次运行我没有看到我的更改.如果我再次部署然后运行我可以看到我的更改.

我正在尝试确保我的UI看起来应该是这样,所以任何有助于我在进行代码更改和在任何平台上查看这些更改之间进行迭代的任何内容都会有所帮助.Droid需要永远启动,我无法运行iOS(没有Mac)或Windows 8.1(我在Windows 10家中),这就是为什么我首先用UWP测试.有没有比在点击运行之前每次点击项目更好的方法?

xamarin visual-studio-2015 uwp windows-10-universal

8
推荐指数
1
解决办法
1143
查看次数

桌面应用转换器/提交到Windows应用商店

我有一个较旧的应用程序,我已使用Microsoft的"桌面应用程序转换器"转换为创建UWP应用程序.该应用程序似乎转换良好,我可以在我的本地计算机上安装和运行它.不幸的是,当我尝试将应用程序提交到Windows App Store时,我收到以下错误:

包接受验证错误:我们不允许您指定的功能:runFullTrust.

包接受验证错误:您无权在包DownloadManager.appx的appx清单文件中指定以下命名空间:http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities.

有什么想法导致这个和修复是什么?

我正在运行Windows 10企业版预览版1511,Build 14352.1002

windows converter windows-store windows-10-universal

8
推荐指数
1
解决办法
870
查看次数

如何在UWP项目中使用预先设计的SQLite?

我有一个来自另一个项目的SQLite数据库,我想在UWP应用程序中使用它.但我不知道如何将这个数据库导入到项目中!

sqlite uwp windows-10-universal

8
推荐指数
1
解决办法
1245
查看次数

如何从Windows 10通用应用程序中的CD导入.CDA曲目?

我需要从CD导入曲目,但到目前为止我无法这样做.我可以成功地从CD导入.mp3或许多其他音频格式.出于导入目的,我首先扫描CD的文件和文件夹.然后我向用户显示文件列表并复制用户从列表中选择的文件.

这是我扫描目录或CD的代码:

    List<StorageFile> allTrackFiles = null;
    private async Task GetFiles(StorageFolder folder)
    {
        if(!scanningRemovableTask)
        {
            return;
        }
        try
        {

        if(allTrackFiles == null)
        {
            allTrackFiles = new List<StorageFile>();
        }
        var items = await folder.GetItemsAsync();

        foreach (var item in items)
        {
                if (item.GetType() == typeof(StorageFile))
                {
                    StorageFile storageFile = item as StorageFile;
                    allTrackFiles.Add(storageFile);

                    var basicProperties  = await storageFile.GetBasicPropertiesAsync();
                    var musicProperties = await storageFile.OpenReadAsync();
                }
                else
                    await GetFiles(item as StorageFolder);
        }

        }
        catch(Exception e)
        {

        }
    }    
Run Code Online (Sandbox Code Playgroud)

我将CD路径传递给此函数,它为我创建了一个文件列表.当CD只有.mp3或任何着名的音频格式时,此代码可以正常工作.但是当CD具有.CDA扩展轨道时,它会造成麻烦.我们知道.CDA文件本身不能播放,它们只是原始媒体文件的快捷方式.

现在,这就是我现在被困住的地方.如何阅读.CDA文件或将.CDA文件媒体导入我们在通用Windows应用程序中的本地目录.

c# windows-store-apps uwp windows-10-universal

8
推荐指数
1
解决办法
627
查看次数

Xamarin.Forms:在UWP中悬停时自定义按钮样式

我已经App.xaml在Xamarin Forms项目中定义了一些样式.但是,如果将鼠标悬停在按钮上或按下按钮,则不会影响该按钮.字体颜色在此处更改为黑色,并且按钮周围出现灰色边框.现在我要覆盖这种风格.

首先尝试:App.xaml为UWP项目添加定义

<Application
    x:Class="YourApp.UWP.App"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:YourApp.UWP"
    RequestedTheme="Light">

    <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.ThemeDictionaries>
                <ResourceDictionary x:Key="Light">
                    <SolidColorBrush x:Key="ButtonPointerOverBackgroundThemeBrush" Color="#00FF00" />
                </ResourceDictionary>
            </ResourceDictionary.ThemeDictionaries>
        </ResourceDictionary>
    </Application.Resources>
</Application>
Run Code Online (Sandbox Code Playgroud)

结果:完全没有变化

第二次尝试:覆盖UWP项目中的PointOver视觉状态App.xaml

<Application
    x:Class="YourApp.UWP.App"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:YourApp.UWP"
    RequestedTheme="Light">

    <Application.Resources>
        <ResourceDictionary>
            <Style TargetType="Button" x:Key="HoverButtonStyle">
                <Setter Property="Template">
                    <Setter.Value>
                        <ControlTemplate TargetType="Button">
                            <Grid>
                                <VisualStateManager.VisualStateGroups>
                                    <VisualStateGroup x:Name="CommonStates">
                                        <VisualState x:Name="PointerOver">
                                            <Storyboard>
                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="Border"
                                                                                Storyboard.TargetProperty="Background">
                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="#00FF00" />
                                                </ObjectAnimationUsingKeyFrames>
                                                <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter"
                                                                                Storyboard.TargetProperty="Foreground">
                                                    <DiscreteObjectKeyFrame KeyTime="0" Value="#00FF00" />
                                                </ObjectAnimationUsingKeyFrames>
                                            </Storyboard>
                                        </VisualState>
                                    </VisualStateGroup>
                                </VisualStateManager.VisualStateGroups>
                            </Grid>
                        </ControlTemplate>
                    </Setter.Value> …
Run Code Online (Sandbox Code Playgroud)

button xamarin xamarin.forms uwp windows-10-universal

8
推荐指数
1
解决办法
5268
查看次数

如何将我的协议添加到 Windows 10 的默认程序中?

嗨,我有一个新协议 URL:myTest,如何将它添加到 Windows 10 中,以便我可以看到它在默认程序中列出?我要在注册表中添加它吗?我如何/在哪里可以做到这一点?

我想将程序与此协议相关联。

windows registry protocols windows-10-universal

8
推荐指数
1
解决办法
1万
查看次数