I am working on a method that generates another class using the CodeDom, VBCodeProvider, and whatever other classes are necessary. I will be using the method in a Windows Phone 7 (and possibly at some point Windows Phone 8) app, so my first question is, "Are all the necessary classes available...
I am trying to write an Extension Method for IEnumerable(Of T). I will be using reflection on the Type T in the Extension Method to get a list of it's properties so that I can create an Anonymous Type that will include all those properties. I have written Extension Methods before, but never a...
I have several classes in my solution that depend on each other, so the classes need to be built in a certain order for the solution to work. How can I force one class to be built before it tries to build another? Thanks.
I have a class instance that I want to serialize, upload to SkyDrive, download from SkyDrive, and then deserialize. I have the serialization, uploading, and downloading working fine, but the deserialization gives me the following error:
There is an error in XML document (2, 2).
The generated...
I have the following code that serializes an object:
Dim stream As New MemoryStream()
Dim xml As New XmlSerializer(GetType(SyncData))
xml.Serialize(stream, New SyncData(CType(Application.Current, App).Recipients, CType(Application.Current, App).Gifts))
However, when I later attempt to check...
I have a class that I need to serialize using XmlSerializer. The class is declared as follows:
<DataContract()> Public Class Recipient
<DataMember()> Public Property ID() As Byte
<DataMember()> Public Property Name() As String
<IgnoreDataMember()> Public ReadOnly Property Gifts() As Gift()...
I have dates from a data file that I need to parse. Here is an example of one of the dates and what I have so far:
DateTime.ParseExact("2013-01-26T02:43:55+0000","yyyy-MM-dd\THH:mm:ss",
As you can see, the date includes the timezone offset (the "+0000" part at the end). I am not sure how to...
I should probably be kicked out of the development field for not knowing this, but I'll ask it anyway. I have a Form with multiple Buttons, all of which modify the same variable. However, each time the variable gets reset. Here is what my code looks like:
Public Class frmTest
Private myvar...
I am trying to learn to program EZ-Robot (http://www.ez-robot.com/shop/) using VB.NET. I have downloaded the SDK, but the examples it included didn't really look like they did much, and the SDK documentation (http://www.ez-robot.com/SDK/) didn't seem very helpful. I would like to see a complete...
I am attempting to learn to use Microsoft Robotics Developer Studio and Visual Studio 2010 with VB.NET to develop applications for Lego Mindstorms NXT. I downloaded and installed Microsoft Robotics Developer Studio, and it added the following project template:
Visual C# -> Microsoft Robotics ->...
I have an app in which there is a TextBlock that I dynamically update when the user taps certain buttons. When the user first goes to the page, this works perfectly. When the user leaves, I save all the data into Isolated Storage like I should, and then recover the data when they return. The...
I have an IValueConverter in which I need the index of the current DataTemplate. I am using an ItemsControl, and the ItemsSource is a List(Of Single). How can I access the current index from inside the IValueConverter or pass it as a ConverterParameter? Thanks.
I have a Windows Phone 7 app that has a ContentControl that I want to use to fill in some of the cells in a Grid in the ContentControl's ContentPresenter in the ControlTemplate. The ControlTemplate already has the Grid, as well as some of the elements I want in it, I want to use the...
...trouble doing this, but I am not sure what I am missing. In the codebehind for MyControl, I inherit MyBaseClass, but then I receive an error in the *.g.i.vb that says the base class cannot be different. What can I do to fix this? Basically, I just want to create controls that use multiple...
I have an XSD file for all the tables in my SQL Server database. In the TableAdapters in the XSD file, some of my queries return scalar values, but the code for the functions generated by Visual Studio 2010 return an Object rather than a typed value. I know how to manually add functions using...
I have a function that I am using to iterate and display the names & values of all the properties of an object. Here is my current code:
Private Function RequestFormValues(rf As NameValueCollection) As String
Dim type As Type = rf.GetType()
Dim properties() As System.Reflection.PropertyInfo =...
I am currently working on an app that uses the "Windows Phone Silverlight and XNA Application" template. I am new to XNA, but I have managed to get it to do most of the things I want. However, I need to show these things in multiple places on the same page in my app. Because I am using the 3D...
I am using Visual Studio 2010 and have installed the Windows Phone SDK 7.1 (http://www.microsoft.com/en-us/download/details.aspx?displaylang=en&id=27570) on my machine. However, several of the Project Templates were not added, such as Windows Phone 3D Graphics Application. I tried doing a...
While debugging a Windows Phone 7 app I am working on, I receive the following message:
No Source Available
There is no source code available for the current location.
This message is displayed in a tab in Visual Studio 2010. The message is only displayed when I have breakpoints, I do not...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.