小编fip*_*n88的帖子

从UWP XAML中的HyperlinkBut​​ton中删除下划线


我需要删除内容中的下划线HyperLinkButton. TextDecorations在此XAML元素中不存在.

<HyperlinkButton x:Name="BtnTeste"
                Width="100" Height="50" BorderThickness="1" 
                HorizontalAlignment="Center"
                Foreground="Black" Background="#ffffff"
                NavigateUri="www.google.com"
                Content="Execute" />
Run Code Online (Sandbox Code Playgroud)

c# xaml windows-10-mobile uwp uwp-xaml

14
推荐指数
2
解决办法
3665
查看次数

配置Visual Studio 2015 - Windows 10项目

我需要在Visual Studio 2015中添加新配置.存在其他配置并且正确且有效.

当我有一个名为"Test"的新配置时,在选项"Copy Settings from:"中选择"Empty"并选中"Create new project configuration".

如果我使用这个新配置运行应用程序(例如Release,Debug等...)我有一个错误:

"无法在锁定文件中找到所需信息.请确保您的目标中提到了UAP,版本= v10.0.240/Win10-".

我不知道解决这个错误.

谁来帮帮我?

谢谢

configuration win-universal-app windows-10 visual-studio-2015

7
推荐指数
1
解决办法
659
查看次数

ContentDialog Windows 10移动XAML - 全屏 - 填充

我在我的项目中放了一个ContentDialog用于Windows 10上的Login Popup.当我在移动设备上运行这个项目时,ContentDialog没有全屏显示并且在这个元素周围有一个最小的填充.键盘是可见的(例如在焦点元素文本框上) )键盘和内容对话框之间存在边距

在FullScreen上有这个解决方案吗?我设置属性"FullSizeDesired"为true,mas的问题是一样的吗?

有人帮助删除这个: - 填充, - 全屏

我的代码是:

<ContentDialog
    x:Class="ExampleApp.SignInContentDialog"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:ExampleApp"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    Title="SIGN IN">

    <Grid x:Name="GridMobile" VerticalAlignment="Center" HorizontalAlignment="Center">

            <Button x:Name="MakeOff" 
            Height="32" BorderThickness="1" 
            HorizontalAlignment="Center"
            Foreground="Red" Background="Black"
            Style="{StaticResource ButtonStyle}"
            Margin="0">

            <HyperlinkButton x:Name="btnRegister"
            Height="32" BorderThickness="1" 
            HorizontalAlignment="Center"
            Foreground="Red" Background="Black"
            Margin="0"
            NavigateUri="www.google.pt"
            Style="{StaticResource HyperLinkButtonStyleMobile}"
            Content="Register">
                <HyperlinkButton.ContentTemplate>
                    <DataTemplate>
                    <TextBlock Text="{Binding}" />
                    </DataTemplate>
                </HyperlinkButton.ContentTemplate>
            </HyperlinkButton>
    </Grid>
Run Code Online (Sandbox Code Playgroud)

页面按钮中的边距/空格是为"PrimaryButton"和"SecondaryButton"保留的,但我需要更多按钮,这个边距/空间不适合我.我想删除它.

谢谢.

c# xaml login popup windows-10-mobile

3
推荐指数
1
解决办法
4211
查看次数

了解Windows 10何时是平板电脑模式 - Windows 10/Windows 10 Mobile

我在适用于Windows 10和Windows 10 Mobile的Universal App上工作.有谁知道如何检查Windows 10是否在平板电脑模式下运行?

我在这里找到了这个问题但是对于Windows窗体:我如何检测Window 10何时在Windows窗体应用程序中进入平板电脑模式?

谢谢

c# windows-10 windows-10-mobile

3
推荐指数
1
解决办法
1042
查看次数

控件变为可见时以编程方式设置焦点

我有一个AutoSuggestBox只在我点击一个按钮时显示.当AutoSuggestBox变得可见时,它也应该获得焦点.

我尝试了很多方法,但没有一个工作.

我的代码:

 <AutoSuggestBox x:Name="AutoSearchBar" 
      HorizontalAlignment="Right" 
      VerticalAlignment="Center" 
      PlaceholderText="Text to find" 
      Visibility="Collapsed"/>

 <Button x:Name="searchButton" 
      Visibility="Visible" 
      HorizontalAlignment="Right"
      FontFamily="Segoe MDL2 Assets" 
      Background="Red"
      Content="&#xE094;"
      Click="searchButton_Click"/>
Run Code Online (Sandbox Code Playgroud)

代码背后:

  private void searchButton_Click(object sender, RoutedEventArgs e)
  {
      AutoSearchBar.Visibility = Visibility.Visible;
      searchButton.Visibility = Visibility.Collapsed;
  }
Run Code Online (Sandbox Code Playgroud)

我试图把它放在代码隐藏中searchButton_Click,但AutoSearchBar控件只出现而且没有集中.

         AutoSearchBar.Focus(FocusState.Keyboard);
         AutoSearchBar.Focus(FocusState.Pointer);
         AutoSearchBar.Focus(FocusState.Programmatic);
Run Code Online (Sandbox Code Playgroud)

c# xaml focus autosuggest windows-10-mobile

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

如何更改背景颜色应用程序返回按钮 - Windows 10 - C#

如何更改本机 Windows 10 应用程序中后退按钮的背景颜色?

这是它目前的样子:

按钮

c# xaml back-button back windows-10

0
推荐指数
1
解决办法
837
查看次数

TeamCity 记录 UTF8 - Powershell 脚本

我创建了 powershell 脚本以在 TeamCity 上的一个步骤中读取文件。如果我在 Powershell 应用程序中读取文件并放置下一个脚本,它可以正常工作,但是当在运行程序类型“PowerShell”的步骤中执行该文件时,编码不起作用并且某些字符没有编码(例如“áãéí”等,等等)

$userDocuments = [environment]::getfolderpath("mydocuments")
$file= "myfile.txt"
$fullPath = Join-Path $userDocuments -ChildPath $file
Get-Content -Encoding UTF8 $fullPath
Run Code Online (Sandbox Code Playgroud)

有人帮我好吗?

提前致谢

powershell teamcity encoding readfile

0
推荐指数
1
解决办法
1086
查看次数