Can anybody tell me how do i add search-box control in "XAML" windows phone 8?
i have tried for search-box control but seems that there is no such control exist.No such Namespace exist error shown by compiler..please suggest any answer thank you in advance.
You could use AutoCompleteBox which is a control works like a searchBox
<toolkit:AutoCompleteBox x:Name="txtSearch" ItemsSource="{Binding}" Margin="0,22,3,10" />
Related
I 'm developping a windows phone 8.1 application and I would like to make a view with the panorama control but Its impossible to find the control
I have the Pivot control but not the panorama, is the panorama control is available on windows phone 8.1 ?
I have find nothing on it on the Internet so far :/
Thanks for the help :)
The Panorama control has been renamed Hub because it’s now available on both Windows Phone and on Windows. So, you would do something like:
<Hub Header="My header">
<HubSection Header="My sub header">
<DataTemplate>
<Grid />
</DataTemplate>
</HubSection>
<HubSection Header="My sub header 2">
<DataTemplate>
<Grid />
</DataTemplate>
</HubSection>
There are some changes in the API, as you will use HubSection instead of a PanoramaItem, and you must have a DataTemplate inside a HubSection, so be sure to check the following reference:
https://msdn.microsoft.com/en-us/library/windows/apps/windows.ui.xaml.controls.hub.aspx
There are some nuances as a slightly different and odd behaviour when you have only 2 HubSections, as noted here: Windows Phone 8.1 app with 2 hub sections, but that may or may not be an issue for you. Some guidelines and implementation examples can be found here:
https://msdn.microsoft.com/en-us/library/windows/apps/dn449149.aspx
I use in the application Ad Mediator. I need to add a button(see example)
I tried to use the Canvas and Canvas.Zindex. But then does not display advertising. Please tell me how to do it.
Just embed it in a panel like Grid so it just follows the DOM. Something like (in pseudo);
<Grid>
<AdMediator/>
<Button/>
</Grid>
I'm developing a windows phone 8 app. I'm new to windows phone 8 development.
I need to add placeholder for text box . I searched in Google & Stack Overflow i got one solution by using The windows phone Toolkit.
I try with following Code.
Step-1: Add Windows Phone Toolkit In Reference By Using Nuget gallery
Step-2: Add namespace in page header
xmlns:xtk="using:WinRTXamlToolkit.Controls"
Step-3: My Textbox XAML code
<TextBox Name="Usernametxt" Text="User Name"></TextBox>
<TextBox Name="Passwordtxt" Text="Password"></TextBox>
<TextBox Name="Emailtxt" Text="Eamail Address"></TextBox>
Step-4: I add the following code under the Usernametxt box [I don't know it's correct or not]
<xtk:WatermarkTextBox WatermarkText="some text" />
I got error in above line The Name WatermarkTextBox does not exist in namespace"using:WinRTXamlToolkit.controls"
I got this solution Here
I don't know how to use this property . I need to add placeholder for 4 to 5 textbox in same page.
Help me to solve this problem.
You are mixing up Windows Phone 8 and Windows 8.
You need a reference to correct toolkit
xmlns:toolkit="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls.Toolkit"
And then you can
<toolkit:PhoneTextBox Hint="some text" Name="Usernametxt" />
Make sure you can got the right Nuget package, more details here.
I am workng on windows 8 app getting problem to use text watermark to text box, can anybody help me to find out how we can apply water mark init .
below is the code of my text box.
<TextBox x:Name="txtUserName" Width="351" Height="45" BorderBrush="Gray" BorderThickness="2" Background="{x:Null}"/>
Use
<TextBox Width="250" Name="_txtBox" PlaceholderText="Please enter CS#"/>
you can use Callisto toolkit for windows 8 it has watermark textbox control. you can install it from nuget package manager.
use this namespace in your page..
xmlns:CallistoControls="using:Callisto.Controls"
use the control like this.
<CallistoControls:WatermarkTextBox Watermark="Type to message" HorizontalAlignment="Stretch" TextWrapping="Wrap" AcceptsReturn="True" MaxHeight="100" Padding="5,5,20,30" />
there are other useful controls too. hope this helps you
There's no way to do it without using a third-party library or overriding the text box and creating your own "Watermark Text Box" class. You just listen for the got/lost focus events and display your text appropriately.
If you don't want to rely on 3rd party SDKs, you can create your own. Check out these tutorials.
Create Your First WinRT WatermarkTextBox Control
Watermark TextBox in Windows Store apps
WaterMarkTextbox Control in Windows Store Application Using XAML
How do I style a LongListSelector to look like below?
I have tried styling it as you would normally style a ListView in a XAML (Windows Store) app or Desktop app but obviously it's different so it didn't work. I have also spent a while searching but I have never seen anything like this for a LongListSelector. But there are no other types of lists.
i think u are looking for WrapPanel
more info at http://www.geekchamp.com/articles/wp7-wrappanel-in-depth
I got it.
You need to add LayoutMode="Grid" and GridCellSize="75, 75":
<phone:LongListSelector LayoutMode="Grid" GridCellSize="170, 150"/>