@HALIA
0 / 0 / 0
Регистрация: 14.11.2015
Сообщений: 12
|
|
|
03.04.2016, 22:50. Просмотров 487. Ответов 3
Помогите, пожалуйста, считать данные с сайта ( http://www.nbp.pl/home.aspx?f=/kursy...sow_walut.html) и загнать иформация о валюте в текстбокс для Windows phone 10.
XML | 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
| <Page
x:Class="App2.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:App2"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d">
<Grid Height="640" HorizontalAlignment="Center" Width="360" Background="{ThemeResource AppBarItemDisabledForegroundThemeBrush}">
<Button x:Name="button" Content="Показати дані" HorizontalAlignment="Left" Height="79" Margin="117,43,0,0" VerticalAlignment="Top" Width="127" Click="button_Click"/>
<TextBox x:Name="textBox" HorizontalAlignment="Left" Height="64" Margin="9,414,0,0" TextWrapping="Wrap" Text="TextBox" VerticalAlignment="Top" Width="340" TextChanged="textBox_TextChanged"/>
<Button x:Name="button1" Content="" HorizontalAlignment="Left" Height="25" Margin="320,40,0,0" VerticalAlignment="Top" Width="25" Click="button1_Click">
<Button.Background>
<ImageBrush Stretch="None" ImageSource="Assets/Wide310x150Logo.png"/>
</Button.Background>
</Button>
<HyperlinkButton Content="Historia" HorizontalAlignment="Center" Margin="249,518,18,0" VerticalAlignment="Top" Height="69" Click="Forward_Click" Width="93"/>
<TextBox x:Name="textBox_Copy" HorizontalAlignment="Center" Height="40" Margin="-1,0,0,0" TextWrapping="Wrap" Text="Середній курс валют" VerticalAlignment="Top" Width="361" TextChanged="textBox_TextChanged" TextAlignment="Center" FontFamily="SWComp" FontSize="15"/>
<TextBox x:Name="textBox1" HorizontalAlignment="Left" Height="216" Margin="10,193,0,0" TextWrapping="Wrap" Text="TextBox" VerticalAlignment="Top" Width="335" TextChanged="textBox1_TextChanged"/>
</Grid>
</Page> |
|
C# | 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
| using System;
using System.Windows.Input;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices.WindowsRuntime;
using Windows.Foundation;
using Windows.Foundation.Collections;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Windows.UI.Xaml.Controls.Primitives;
using Windows.UI.Xaml.Data;
using Windows.UI.Xaml.Input;
using Windows.UI.Xaml.Media;
using Windows.UI.Xaml.Navigation;
using System.Xml.Linq;
using System.Text;
using System.ComponentModel;
using System.Data;
using System.Windows;
using System.Net.Http;
using System.Threading.Tasks;
using System.Net.Http.Headers;
using Windows.Web.Http;
using System.Net;
using System.Net.WebClient;
// Документацию по шаблону элемента "Пустая страница" см. по адресу [url]http://go.microsoft.com/fwlink/?LinkId=402352&clcid=0x409[/url]
namespace App2
{
/// <summary>
/// Пустая страница, которую можно использовать саму по себе или для перехода внутри фрейма.
/// </summary>
public sealed partial class MainPage : Page
{
public MainPage()
{
this.InitializeComponent();
FileInfo file = new FileInfo("dir.txt");
}
private void button_Click(object sender, RoutedEventArgs e)
{
textBox.Text = File.ReadAllText("dir.txt");
}
private void textBox_TextChanged(object sender, TextChangedEventArgs e)
{
}
private void button1_Click(object sender, RoutedEventArgs e)
{
Application.Current.Exit();
}
private void HyperlinkButton_Click_1(object sender, RoutedEventArgs e)
{
}
private void Forward_Click(object sender, RoutedEventArgs e)
{
if (Frame.CanGoForward)
Frame.GoForward();
else
Frame.Navigate(typeof(App2.BlankPage1));
}
private void textBlock_SelectionChanged(object sender, RoutedEventArgs e)
{
}
private void button2_Click(object sender, RoutedEventArgs e)
{
}
private void textBox1_TextChanged(object sender, TextChangedEventArgs e)
{
}
}
} |
|
0
|