windows-mobile

Programmatically connect to bluetooth headsets on Windows Mobile

早过忘川 提交于 2019-12-24 08:57:23
问题 On a Windows Mobile 5.0 device I have an MFC C++ kiosk application that should programmatically connect to one of 3 Bluetooth headsets and open a bidirectional audio connection to it. The headsets are already known to the device, it's only the switching and connecting part that should be done programmatically. How would I do that? I'm aware of the thread How to “Connect via Bluetooth” in WM programmatically? but would like to have a way that works in C++. Any ideas? 回答1: I would start looking

How to make the background image transparent in windows mobile?

喜你入骨 提交于 2019-12-24 06:36:10
问题 I am developing the smart device application in C#. I am new to the windows mobile. I have added the background image to the form in my application by using the following code. I want to make this image transparent so that other controls on my windows form will be displayed properly. protected override void OnPaint(PaintEventArgs e) { base.OnPaint(e); Bitmap CreateCustomerImage = new Bitmap(@"/Storage Card/background.png"); e.Graphics.DrawImage(CreateCustomerImage, 0, 0); } The background

Does VS2010 support Windows-mobile projects?

我的未来我决定 提交于 2019-12-24 00:47:15
问题 I have Visual-studio 2010 prot and I am trying to create a Windows-mobile or Windows-CE project, but I don't see how to do it. Can anyone help ? 回答1: For VS 2010 there is Visual Studio Phone. You can check VS 2010 Phone. You can find there a lot more for windows phone development. 回答2: No, Window Mobile development is not available in VS 2010. You must use VS 2008. If you want to do Windows Phone 7, you can (and must) use VS 2010, but it is not the same as Windows Mobile (i.e. Smart Device)

Accelerometer Shaken event in windows universal app doesn't work

痴心易碎 提交于 2019-12-23 23:56:28
问题 I try to detect a shake on my phone with the Shaken event from Accelerometer object. The accelerometer object is not null but when I shake the phone, it never go in the _accelerometer_Shaken event. public int shakeCount = 0; Accelerometer _accelerometer = Accelerometer.GetDefault(); public MainPage() { this.InitializeComponent(); if (_accelerometer != null) { _accelerometer.Shaken += _accelerometer_Shaken; } } async private void _accelerometer_Shaken(Accelerometer sender,

Memory Leak with XmlDocument()

╄→гoц情女王★ 提交于 2019-12-23 22:39:20
问题 I believe I have memory leak with some of my code that uses the XmlDocument class. My program runs on a Windows 6.1.4 device (C#) and reads from a database on another server to see if any programs installed on the device need to be uninstalled and then reads from an XmlDocument to get the names of the programs that are uninstallable. The program then matches the lists and uninstalls accordingly, if necessary. This process is looped infinitely and runs in the background but what I'm noticing

.NET Compact Framework Can you get grids which have multi line text in cells?

别说谁变了你拦得住时间么 提交于 2019-12-23 18:50:06
问题 Is it possible to show multiple lines of text in grid cells using the .NET Compact framework? We need to create a grid where the middle column contains an address. We'd like to show this over multiple lines and (possibly) apply some formatting to the final line. e.g. 123 Anywhere Street Birmingham B1 2DU tel: 0123 555555 回答1: Take a look at Ilya Tumanov's example of custom formatting data in the DataGrid. He does custom painting of cells in it. 回答2: You must override "OnPaint" method on the

Zip And Unzip files and folders

走远了吗. 提交于 2019-12-23 15:22:06
问题 I need to zip and unzip the directory hirarchy in Windows Mobile using C++/C#. What is the simplest library available for it? I have googled many times. I found some stuff, but I am not able to go ahead with it. If you have implemented or if you know some stuff about it please let me know. 回答1: For .NET, SharpZipLib. See also: Zip library options for the Compact Framework? 回答2: DotNetZip is a .NET library, has a build for .NET CF. There's a .NET CF sample application delivered with the devkit

Determine number of GDI handles and USER objects

夙愿已清 提交于 2019-12-23 10:14:20
问题 We developed a small test suite for our Windows Forms UI rendering engine which allows to measure performance and detect memory leaks while running test cases in an automated manner. Now we would like to check for handle leaks as well. On the desktop platform we can use this code: [DllImport("User32")] private extern static int GetGuiResources(IntPtr hProcess, int uiFlags); using (var process = Process.GetCurrentProcess()) { var gdiHandles = GetGuiResources(process.Handle, 0); var userHandles

Can I turn off the automatic single instance feature in Windows Mobile 6?

痴心易碎 提交于 2019-12-23 04:57:23
问题 Windows Mobile 6 single instances applications by default can I turn off or override this behavior? This is needed if one needs to automatically restart or self update an application. 回答1: Alex Feinman describes how it works, and how to get around it, in this blog post 回答2: This is needed if one needs to automatically restart or self update an application. This doesn't answer your question, but instead of that I launch a separate restarter or updater process. 来源: https://stackoverflow.com

How to enable ARMv6 unaligned access on WinMobile6?

青春壹個敷衍的年華 提交于 2019-12-23 03:11:21
问题 ARMv6 introduce a great feature - unaligned memory access , which make some things in code much more simplier and faster. But microsoft gives API for it only in winCE6. And most PDAs now based on WinMobile6 (which is on CE 5.x). And unaligned access is disabled by default :( I've try to set unaligned flag in CP15 register, but this doesn't work - I have a crash on read unaligned data. Is it possible to enable unaligned access on WinMobile6? Edit: I've found the tool, which can enable