Windows PhoneToolkit ListPicker: implementing a countries list as in the settings? - windows-phone-8

I have a list of countries that I want to display in a list similar to that in the phone settings app
I tried using the toolkit's ListPicker but it had a poor performance in loading as the list size is large, it seems that this is a known issue with ListPicker.
is there any alternatives to implementing such a list ?

I know this is an old question, but here's the solution that worked for me:
Implement a new page with a ListBox.
In the new page, when an item is selected, save the selected Item/Index in the PhoneApplicationService.Current.State
Then navigate backwards and retrieve the saved Item/Index from the page state.

Related

AppScript. Is there a way to check if list item has a checkbox?

Google document allows to add list items with a checkboxes, like on the screenshot below:
I need to write a appscript to check if list item has a checbox, but i haven't found appropriate field/method in documentation and this kind of list item return null instead of GlyphType:
Does anyone know if it is actually possible somehow?
This isn't currently possible!
But there is already a report on Google's Issue Tracker which requests the behaviour you seek:
Add support for all glyph types in Docs (bullets and number formats)
Google does seem to know about this feature request but if it's causing problems I suggest leaving a comment to bump its priority.
You can also hit the ☆ next to the issue number in the top left on the aforementioned pages which lets Google know more people would like to see this implemented.

How to set focus on tab in tabcontrol in URL

I am trying to call a page in my customers webapplication (Exact Synergy Enterprise)
This is the link: http://someserveridontdisclose/Synergy/docs/CSCANEduCourseCard.aspx?ProjectNr=ACPGINTV
Within this page is an Ajax TabContainer with several TabPanels. One of them is called 'Doelgroepen'
I dont have the source for this application, as i am not the developer of it. We only develop custom extentions to it.
Here's the question: Is it possible to focus on one of the tabs USING ONLY AN URL? If so How?
Thank you very much for your thoughts about this.
try to set with javascript. you'll have to write your own js to get index number you want from url, then set like this
$find('<%=TabContainer1.ClientID%>').set_activeTabIndex(2);
http://forums.asp.net/t/1127834.aspx
http://www.aspforums.net/Threads/420684/ASPNet-AJAX-TabContainer-Set-Active-Tab-Client-side-using-JavaScript/
If you do not have access to the code and if this is not part of the requirement / design specification for the application you are using (ie: what you asked the developer to do), then the answer is No.
The control does not have "native" support for URL tab selection. There needs to be specific code in the application in order to handle this.
It is however very easy to implement, if you absolutely need it, it shouldn't take much time (about 15-30 lines of code, depending on how many tabs/urls combination you need).
You can find a running sample of the AjaxControlToolkit Tabs control at the following link (the available functionnalities are described in there):
http://www.asp.net/ajaxLibrary/AjaxControlToolkitSampleSite/Tabs/Tabs.aspx
If the TAB has an ID you could make it visible by adding '#tabid' to the URL.

WP8 Control for picking a number

I need to allow a user to select a number between 5 and 30 in my Windows Phone app, and I find it overall difficult to do.
I am using pivot control so I shouldn't use slider according to MS guidelines.
I have downloaded WPToolkit and they have a neat DatePicker and TimePicker controls, and I think something similar would be perfect to pick a number (just the same way you pick time when setting up an alarm).
I was considering simple textbox, but I think it would be much nicer to just pick from a list of numbers instead of typing in...
Any ideas how to implement it? Or have anyone done that alrady? I think I could put like a textbox with focus or click event that would redirect to another page that has LongListSelector and once an item has been selected I would redirect back to the original page and populate the textbox with the selected number... Is that doable?
You can download the Toolkit source code and modify the DatePicker/TimePicker control to be more generic.
If you don't want to do that, you could just use the ListPicker control instead which is also included in the toolkit. Simply pass a list of numbers between 5 and 30 and the user can pick from the list.
You need to use LoopingSelector from Windows Phone Toolkit. An example how to customize it is here http://www.maxpaulousky.com/blog/archive/2011/01/31/windows-phone-looping-selector-for-digits.aspx.

ListView add more items in Metro apps?

I have a metro application in which I have a Listview and service data contains above 100 items. Initially when am loading listview in my page it has to display only 8 items plus 1 more-related item and later if i click on a more-item it needs add another 9 items to my page and totally it has to show 17 items in my page and need to display more item also like that flow continues.What should I get to get my scenario.Can anyone help me.Below I tried to give u my scenario.
Thank you.
Take a look to this article: http://www.silverlightplayground.org/post/2012/06/10/Metro-Incrementally-load-GridView-and-ListView-with-ISupportIncrementalLoading.aspx.
There are a couple of solutions -- all depending on the work that you want to undertake. Also, I would suggest that you don't have a "More" button if you can help it -- it's not the best user interaction. Option 2 is going to give you the best experience.
Option 1
Use WinJS.Binding.List as your data source -- using this you can manipulate it like a JavaScript Array (e.g. push, pop etc). As you add & remove items from the list, the list view will react to those changes.
Full details are here.
Option 2
Create a VirtualDataSource derivation that is intimately aware of the ways in which you can request your data, and can offer up a consistent interface to the ListView. This enables your UI to be completely flexible to it's layout, and request enough data to satisfy the available space, while virtualizing the UI elements (better memory/performance), and the data (ensuring only the data needed by the user is requested.
Full worked example here.

My slots not listed in Qt Creator Signal/Slot editor

I created a Qt4 Gui application. I have the main window. I put a QStackedWidget and two QPushButtons on the MainWindow's central widget. I am using QtCreator as my IDE.
In the attached image the shown stacked widget has two pages and the two pushButtons 1 and 2 are for navigation to firstPage and SecondPage of the stacked widget respectively.
Problem 1:
When I opened signal/slot editor I selected sender=button1 and signal=clicked, then receiver=stackedWidget and slot=? . It supposed to be setCurrentIndex() but its not listed in the drop down list.
Problem 2:
In the right object panel of QtCreator there is marked the "Denied Symbols". I don't know why those symbols are there? Is there any problem ?
I am attaching the screenshot below. If any more details are required please let me know.
I too am learning QT and QT Designer, and ran into the same problem. A determined search of the Internet revealed several other people with the same question, and no answers. You'd think someone out there would have explained it by now. Sigh.
Anyway, the problem is that the signals sent by the push-buttons don't match the signature of the "setCurrentIndex(int)" slot on the stacked-widget, so "setCurrentIndex(int)" doesn't show up in the menu when one tries to use a push-button "clicked()" signal. That is, "clicked()" has no parameters, and "setCurrentIndex(int)" has a single integer parameter, therefore they have different signatures.
In my project, I was trying to connect menu items to a stacked widget, so that one of the contained widgets would be displayed when the menu item was selected. The menu items only have the "triggered()" signal, there's no "triggered(int)" signal, and QStackedWidget's "setCurrentIndex(int)" slot is expecting a signal that has a single integer parameter in its signature.
In other words, you can't do what you want, directly.
Here's how I solved it in my code. Keep in mind that I'm writing my Qt app in C#, using MonoDevelop (to do C# development under Linux) and Qyoto (which is a C# interface to Qt).
After creating my main window (and assiging it to a variable called "layout"), I did this:
QObject.Connect (layout.someMenuItem, SIGNAL("triggered()"), showSomeView);
This causes my menu item to call the showSomeView() function whenever it's triggered.
I then wrote
public void showSomeView()
{
layout.stackedWidget.SetCurrentWidget(layout.someView);
}
Now it does what I mean!
The solution in your project's language should be similar to this. It's unfortunate that the signal/slot connections have to be set up in code, instead of in QT Designer's GUI, but I don't know how else to do it.