Smart Device Programming with Visual Studio .NET 2003

Posted September 22, 2003

Chat Date: September 10, 2003

Please note: Portions of this transcript have been edited for clarity

Chat Participants:

  • Amit Chopra, US-Visual Studio for Devices
  • Jamie De Guerre, Sr Site Operations Analyst - IT Site Operations Americas
  • Mark Cliggett, Group Program Manager - US-Visual Studio for Devices
  • Scott D. Smith, Lead Program Mgr - US-Visual Studio for Devices
  • Carlton Lane, SDE - US-Visual Studio for Devices
  • Mark Prentice, PM - US-.Net Compact Framework

Moderator: Ed_H (Microsoft)
Welcome to today’s chat on Smart Device Programming with Visual Studio .NET 2003. We have members of the Visual Studio For Devices team here to answer your questions today. I will ask the hosts to introduce themselves.

Host: jamied (Microsoft)
Hi! My name is Jamie de Guerre. I joined the .NET Compact Framework team in 2001 and have worked on Performance, Smartphone support, Windows Forms and Drawing.

Host: markcli (Microsoft)
I'm the group program manager in the Visual Studio for Devices team.

Host: ssmith (Microsoft)
Hi I'm Scott Smith, a Program Manager in the Visual Studio for Devices team, primarily responsible for Data Tools.

Host: achopra (Microsoft)
Hi, I am Amit Chopra. I recently started working with the Visual Studio for Devices as a Program Manager. I will be responsible for sustained engineering, release management and also community activities.

Moderator: Ed_H (Microsoft)
And I am Ed Hickey, VS Communities PM. Glad you all could make it today!

Moderator: Ed_H (Microsoft)
Let's get started! Fire away with your questions for our hosts.

Host: jamied (Microsoft)
Q: Hi guys. Noting that the compact framework does not implement serialization fully, how does ActiveSync manage synchronization?
A: ActiveSync actually isn't based on the .NET Compact Framework at all, and the type of synchronization that ActiveSync does is very different than .NET Synchronization. Basically, totally separate types of synchronization :)

Host: jamied (Microsoft) Host: jamied (Microsoft)
Q: mickX : Jamie, what is this other method of serialization?
A: The serialization that ActiveSync uses is just custom for each application type. For example, it serializes Microsoft Word documents between Pocket Word format and the full desktop Word document. Take a look on MSDN for more details on the APIs that ActiveSync exposes, but I do not believe they expose any APIs for serializing data - that's all just done custom for the document types on the device.

Host: jamied (Microsoft)
Q: RobG : Can you use Smart Client on the compact framework? If so, can you run the cached version of the application when disconnected?

Host: jamied (Microsoft)
Rob - I don't understand what you mean by Smart Client. Please elaborate

Host: markcli (Microsoft)
Q: ctacke_eMVP : When can we expect QFEs for CF SP1 for PB 4.2 *and* 4.1
A: CF SP1 is available for PB4.2 today. There are no plans to make it available for 4.1. If you have a clear customer need for this, please let us know. The folks who looked at this didn't see a clear need.

Host: ssmith (Microsoft)
Q: Can you use strongly-type DataSets in the compact framework. It looks like there are several classes not supported by the CF that are used by the dataset class generated by VS.NET.
A: It's not officially supported, but you can use typed datasets in the compact framework, however some functionality might be limited by the unsupported classes in the compact framework. You will need to create a typed dataset using the XSD tool and modify the resulting source code to remove unsupported metadata.

Host: jamied (Microsoft)
Q: RobG : Does Microsoft have any patterns/best practices for synchronizing data from a sometimes connected application. For example a user that is disconnected may update data that has been updated by someone else since the disconnected user got their c
A: There are several options here. Depending on the amount of data you have and the types of ways you're accessing it or modifying it, different solutions may be appropriate. But in general, SQL Server CE with it's Replication features is a very good option.

Host: jamied (Microsoft)
Q: mickX : So in other words my team is in for a long haul? No easy method?
A: Yes, there is no automated way to do serialization of data with the .NET Compact Framework, you will have to implement your own custom serialization.

Host: markcli (Microsoft)
Q: ctacke_eMVP : Mark: The QFE for PB 4.2 is not clear that it contains the SP1 bits, and I've gotten conflicting info as to whether of not the QFE is SP1. As for 4.1 we've got several customers using 4.1 with the CF.ctacke_eMVP : I'm surprised MS feels it worthwhile to have a QFE to add the CF in, but not the newer SP1 version
A: It is available - if you can let me/us know where you are hearing that it isn't, we can fix that. Re: the disconnect between adding it to begin with but not updating it, I made the same point on our internal conf call a few minutes ago. It is good feedback and I will follow up with the net cf team.

Host: jamied (Microsoft)
Q: RobG : jamied_ms : Smart Client (an MS term AFAIK) = WinForm loaded from a URL
A: Ah. Perhaps this is an over-used term here at Microsoft. From our perspective, we refer to a Smart Client application as *any* Windows Form application (since it runs client side), as opposed to a web application. There are some features on the desktop that support very easy deployment through a web page that the .NET Compact Framework does not support. Unfortunately, I'm not totally familiar with those features. You can however, install a .NET Compact Framework application using a CAB file directly from a URL.

Host: ssmith (Microsoft)
Q: Shanti : I am getting examples to sort a DataView of a DataSet. Is there any way to sort DataSet directly?
A: Not that I'm aware of. You can use a DataView or DataView Manager to sort the dataset. See the example at https://www.dotnet247.com/247reference/msgs/5/29132.aspx.

Host: jamied (Microsoft)
Q: pursca : Can someone help me on how to make emulator to work with ActiveSync 3.7?
A: We are actually releasing a Power Toy for connecting your emulator to ActiveSync that will make this much easier. In the past the only way to do this was using a serial cable, connected from one port on your PC back to the other port. The new power toy allows you to do this without any cable very easily. Check back to the Pocket PC downloads site and it should be posted there soon! (It may even be out already ... I'll try to check for you)

Host: jamied (Microsoft)
Q: RobG : jaimied_ms: Is there an example of CAB deployment via URL
A: No - I'm not sure of any samples out there for this. Essentially if you post a CAB file to a URL, the user can browse to it from the device and it will launch the CAB on the device, install the application and run any custom logic you have in.the CAB file.

Host: jamied (Microsoft)
Q: RobG : PeterFoot_MVP: With CAB via URL, does the app get installed on the device or do you always have to get it from the URL?
A: Gets installed on device.

Host: jamied (Microsoft)
Q: pursca : By using changing the registry entry to notify desktop app, how can we notify activeSync the job is not done and not close connection?
A: I'm not sure what you're referring to here ... Could you explain the scenario you're doing a little bit more?

Host: jamied (Microsoft)
Alex: If you get a repro case for this that you can get to repro somewhat consistently, please send it our way and we'll definitely take a look.

Host: jamied (Microsoft)
Pursca: I'm not very familiar with programming ActiveSync in the method you're describing. However, you might find the information at the following url helpful.

Host: carlton (Microsoft)
Q: Is there anyway for me to resize a datagrid to match the contents of the grid so as to avoid any "white space" where no data is displayed?
A: The only way to dynamically resize a DataGrid column width is to measure the text length of each row item and determine the widest column. It's painful but a one-time hit when the DataGrid loads its data.

Host: jamied (Microsoft)
Q: pursca : jamied, are you saying that once I have the connection, as long as I do not release it, ActiveSync will not close the connection unless someone take the PPC out of craddle?
A: I'm not sure, sorry I don't have more details. Try taking a look at the information provided on MSDN. I don't see why ActiveSync would drop it's connection, but it's definitely possible with ActiveSync.

Host: jamied (Microsoft)
Q: LUCKYGAL : I am trying to download updates...but can't
A: What updates are you trying install?

Host: jamied (Microsoft)
Q: ademar : My problem is, ListView.EnsureVisible Equivalent in DataGrid
A: Sounds like a great feature request. We'll take that feedback for the next version and consider adding that functionality to the DataGrid.

Host: carlton (Microsoft)
Q: My problem is, after sorting DataView of a DataGrid and try to read Cell contents by CurrentCell Row and Col Numbers, I get wrong data. Is there any way to get correct row and column Numbers?
A: Shanti, don’t use CurrentCell to determine the data value. Try getting the DataRowView from the DataView[rowIndex] and then DataRowView[index] or DataRowView["column"] to determine your data value.

Host: carlton (Microsoft)
Q: so I just size it small in design mode and it will adjust in real time as I add rows and columns?
A: Yes, You'll need to do this for each column.

Host: jamied (Microsoft)
Q: bistia06 : Using Graphics.DrawLine : is there a way to change the pen's width?
A: Unfortunately this is unsupported in the first version of the .NET Compact Framework, but we plan to add support for this to the next version. In the meantime you need to work around the missing Pen.Width property.

Host: jamied (Microsoft)
Q: RobG : Does CF app support application.config for application settings?
A: No. However, there are great third party samples out on the internet from our developer community and MVPs that implement the whole library for the .NET Compact Framework as an add on. For example, take a look at https://opennetcf.org/Forums/topic.asp?TOPIC\_ID=45

Host: markpre (Microsoft)
Q: ctacke_eMVP : Mark: The QFE for PB 4.2 is not clear that it contains the SP1 bits, and I've gotten conflicting info as to whether of not the QFE is SP1. As for 4.1 we've got several customers using 4.1 with the CF.
A: Just to follow up, We understand the messaging around our releases has been a bit vague. We are working on ways to make the communications better. For now here is the breakdown:

1. Web Redist. (RAM Install) The first release of SP1 was only targeted at PPC devices. We heard from you all in the community that this was not adequate. We decided to re-release the web redist with support for all devices NETCF supports, including WinCE 4.1

2. OS Updates. (ROM Install) We have released Device OS updates for, WinCE 4.2 (PB 4.2 QFE), PPC 02 (AKU 6), PPC 03(AKU 1).

Host: markpre (Microsoft)
We are waiting strong customer need to implement a PB 4.1 QFE which includes NETCF SP1. (a customer to call up support, make a good business case and request the QFE)

Host: jamied (Microsoft)
Thanks to the great development community and MVPs for creating great content like that for us!

Host: ssmith (Microsoft)
Q: Shanti : Can I read and write a Pocket XML file or a plain comma delimited files as done in Jet Databases in VB?
A: There are a number of ways of writing files on the PPC. You can use the ReadXML and WriteXML methods on the dataset for example.

Moderator: Ed_H (Microsoft)
This has been a GREAT chat. Thank you to everyone. Unfortunately, it is time to go. Thanks for participating, and we'll see you next time!

Host: jamied (Microsoft)
Thanks everyone!

For further information on this topic please visit the following:

Newsgroups: Mobile and embedded application development topics

Mobile and Embedded Transcripts: Read the archive

Website: Visit the Mobile & Embedded Developer Center

Top of pageTop of page