combo box dropdown via code?
Is there a way to get a dropdown combo box to expand via code? I tried
setting focus but that didnt work.
Thanks Tag: How to change font size in the and listview controls Tag: 61580
progress bar lockup
Hi,
I posted this in the dotnet.csharp forum, but was told to come here to the
CF forum
This code does not run, the application throws when i call Invoke;
private delegate void DelegateStarter();
private void CycleProgressBar()
{
int x = 0;
while( true )
{
progressBar1.Value = x;
x += 10;
if( x > 100 )
x = 0;
Thread.Sleep(200);
}
}
private void button1_Click(object sender, System.EventArgs e)
{
DelegateStarter dls = new DelegateStarter( CycleProgressBar );
progressBar1.Invoke( dls ); // *** THROWS ***
}
Appereently, a progressbar cannot be updated on the main thread, so i need
to Control.Invoke to do the updating, but cant get it working. Can someone
help me?
Joe Tag: How to change font size in the and listview controls Tag: 61579
Help with locating database
Hey Everybody,
I am running a C#code that creates a database called Mobile.sdf
SqlCeEngine engine = new SqlCeEngine ("Data Source = Mobile.sdf");
engine.CreateDatabase ();
Now I am not able to locate the actual database on my PC. Where will
this be stored?
Thanks
Sats Tag: How to change font size in the and listview controls Tag: 61574
Bitmap() constructor fails with C#
Bitmap constructor is causing an exception and the application exits. The is
under WinCE5.0, .netCF and deployed with VS2003.
Anyone else seen and / or solved this problem?
Joe Tag: How to change font size in the and listview controls Tag: 61569
Nasty Error
Hi
I've an Application on my PocketPC Running.
Everything worked fine for weeks. Now I wanted to try some installation
things. and the program doesn't start anymore
these lines of code are producing the error
InitializeComponent();
Icon icon;
icon = new
Icon(this.GetType().Module.Assembly.GetManifestResourceStream("smartCRMPDA13.ico.remote.ico"));
try
{
// Here it Crashes! The Icon is set as embedded source and when I
// COpy the application folder to an other PPC everything works fine!
this.ImageList16px.Images.Add(icon);
}
catch(Exception oErr)
{
// The Exception only says "Exception"....
program.ShowMessageBox(oErr.Message,"Fehler",2);
}
So any hints? I've absolutly no Idea whats going wrong here.... Tag: How to change font size in the and listview controls Tag: 61564
create Virtual Com Port Windows CE 3.0
Can anybody tell me how to create Virtual COM ports for PocketPC with C# ? Tag: How to change font size in the and listview controls Tag: 61563
32Mb is not enough memory for App
Hi all,
From what I've read each CE app can only use 32Mb of memory, is there
anyway to expand this?
Our App is rather large and demanding, and sometimes the app runs out of
memory, usually while doing Sql-stuff.
I've looked into VirtualAlloc, but firstly I don't /really/ understand
it, and secondly, it seems to makes no difference in our App.
Below is an app I whipped up to test memory usage. On my device it runs
39 times, then throws an out of memory exception both with, and without
the VirtualAlloc code commented-out.
[VB.NET]
Public Class Form1
Inherits System.Windows.Forms.Form
Public Shared Sub Main()
Application.Run(New Form1)
End Sub
<System.Runtime.InteropServices.DllImport("coredll")> _
Private Function VirtualAlloc(ByVal lpStartAddr As IntPtr, ByVal size
As Integer, ByVal flAllocationType As Integer, ByVal flProtect As
Integer) As IntPtr
End Function
<System.Runtime.InteropServices.DllImport("coredll")> _
Private Function GetLastError() As Integer
End Function
Private MEM_RESERVE As Integer = &H2000
Private MEM_COMMIT As Integer = &H1000
Private PAGE_READWRITE As Integer = &H4
Private PAGE_NOACCESS As Integer = &H1
Private Sub Form1_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Me.Visible = True
Application.DoEvents()
Dim offset As Integer = 1
'Dim x As IntPtr = Me.VirtualAlloc(Nothing, 2 * 1024 * 1024,
MEM_COMMIT Or MEM_RESERVE, PAGE_READWRITE)
'If x.ToString() = "0" Then
' MessageBox.Show(Me.GetLastError().ToString())
'End If
Try
While True
Dim p As New PictureBox
p.Bounds = New Rectangle(offset * 8, offset * 8, 25, 25)
p.Image = New Bitmap(500, 700)
Me.Text = offset
offset += 1
Application.DoEvents()
End While
Catch ex As Exception
MessageBox.Show(ex.ToString())
End Try
End Sub
End Class
[/VB.NET]
Thanks for reading, and I hope someone is able to help/advise me Tag: How to change font size in the and listview controls Tag: 61560
OpenNetCF DateTimePicker control-CustomFormat
I cannot assign a custom date format for the OpenNetCF DateTimePicker
control, it just seems to ignore the setting.
I need the setting to be "dd/mm/yy", but it defaults to "mm/dd/yy"
I have the following code in my form's Load event...
Dim mPicker As OpenNETCF.Windows.Forms.DateTimePicker
mPicker = New OpenNETCF.Windows.Forms.DateTimePicker
mPicker.CustomFormat = "dd/mm/yy"
mPicker.Format = OpenNETCF.Windows.Forms.DateTimePickerFormat.Custom
mPicker.Bounds = New Rectangle(40, 6, 100, 20)
Me.Controls.Add(mPicker)
I am using v1.4 of OpenNetCF, I have read threads with other guys
having the same issue, but I have not seen any fixes..
TIA
Paul Newton Tag: How to change font size in the and listview controls Tag: 61547
moving and copying files from PC to PDA and vice versa
Hi,
Presently i am working on PDA device.how can i configure activesync to
PDA? I was tried by giving the Serialport and COM1 as my key value
pairs in registry,but it was not working.and also i am working on
PocketPC 2002 Emulator , VS.NET 2003 and Activesync 3.7. please help
me.It is urgent.
Thanks & Regards,
Prasanna Kumar Tag: How to change font size in the and listview controls Tag: 61546
String from unmanaged DLL to managed app
On Windows CE 5.0 and CF2.0 a try to send a string from a unmanaged DLL to
managed app:
extern "C" __declspec(dllexport) void GetError(char *pErrorMessage)
{
strcpy(pErrorMessage, "Hello C# World!");
}
[DllImport("TestDll.dll")]
internal static extern void GetError([MarshalAs(UnmanagedType.LPStr)]
StringBuilder errorMessage);
StringBuilder message = new StringBuilder(500);
GetError(message );
I allways get an error 'NotSupportedException'.
Thanks for help!
Markus Tag: How to change font size in the and listview controls Tag: 61545
Help with deceiding on best solution
Hello all,
I am about to embark on a reasonably large project - I operate an energy
management business and need to install remote controls at a large number of
my clients sites.
My plan is to utilise windows CE devices at the clients sites - they should
be low in cost, reliable (as they have no moving parts) and the development
process should be relatively straight forward - it should also make the
communications to the devices simpler and allow me to extend the
functionality well into the future.
The devices will have a number of communication options - these include GPRS
modem, clients internet connection via wireless of RJ45 - or GPS modem.
The area that I still need to finalise is the method of communication and
the technology to use. The following will be true
1. Communications will need to be over the internet
2. The internet connection will often use a clients internet connection
therefore there will be no ability to have a fixed IP address on the devices
3. It must efficient - if the communication is over GPRS the costs of
transmitting data will be high
3. There will be a large number of devices - the system needs to be
scalable to 100,000's of devices
4. The remote devices will need to send information to our office
5. We will need to be able to send info to the devices with a very small
delay
6. Communications must secure - it will be critical that no one can hi-jack
and control the devices
I have investigated the new WSE 3 and this sounds like a good option for
communication?? It appears to have the security requirements and easily
scalable to manage the communications for this many devices - can windows CE
take advantage of the security features of WSE 3.
Any help from those that may have some experience in these matters would be
very appreciated.
--
matthew Tag: How to change font size in the and listview controls Tag: 61542
ANN: Localized Framework 2.0
.NET Compact Framework 2.0 Localized Versions are Available Now
http://blogs.msdn.com/mikezintel/archive/2005/11/23/496123.aspx
.NET Compact Framework 2.0 Redistributable
http://www.microsoft.com/downloads/details.aspx?FamilyID=9655156b-356b-4a2c-857c-e62f50ae9a55
--
Thomas Scheidegger - MVP .NET - 'NETMaster'
http://www.cetus-links.org/oo_dotnet.html - http://dnetmaster.net/ Tag: How to change font size in the and listview controls Tag: 61541
Setup moans because of newer version
I'm writing software for the QTek 2020 at the moment which is running Pocket
PC Version 4.20.0.
However we're just starting to rollout the same software on the XDA II
running Windows Mobile 2003 Second Edition version 4.21.1088.
The software actually works OK however when it tries to install SQLCE and
SP3 for the .NET Framework it's coming up saying "this software was written
for a previous version of software, and may not work, do you want to continue
with the install"
Is there anyway to get around this?
Many Thanks
Rob Tag: How to change font size in the and listview controls Tag: 61540
Setups
Hi There
how do you create your setups ?
My Target is to get one setup which includes all runtimes and installs them
if necessary.
The Cab files generated by VS don't include any runtimes :-/ (OpenNETCF,
SqlServerCe,CF,...)
Is it possible to "merge" some cab files ? Tag: How to change font size in the and listview controls Tag: 61534
GPIO ports
i have a panel pc and it has Win CE 4.2 OS on it. I need to send data from
GPIO ports . I found stg. about VirtualCopy and VirtualAlloc but not so
clear how to do that. I am using VB.NET on Compact Framework 1.0 while
coding. Would someone give me some source or advice about this?
Thanx in advance Tag: How to change font size in the and listview controls Tag: 61531
WM_SIZE and WM_SETTINGCHANGE not fired in WinCE.NET
Hi to all NG.
I'm unable tu understand why in WinCE 4.2 while rotating the screen,
the WM_SIZE and/or WM_SETTINGCHANGE messages are not fired from the
system (so I can't get the Resize event). In this way I can't
understand when redim my form to the new screen size.
I've seen that neither Word or Explorer redim theyself (and they are
_original_ Microsoft products, so I can think that they are well made).
Can be that WinCE isn't designed for real-time screen rotating (but
only during CE startup -> once a boot) while Windows Mobile yes? Is
this the reason?
I can rotate the screen directly from my application, calling the
ChangeDisplaySettingsEx. In the MSDN
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceshellui5/html/wce50lrfChangeDisplaySettingsEx.asp
you can see that calling that API a WM_SETTINGCHANGE must be fired, but
I can't get that message neither in my C# app (using
Microsoft.WindowsCE.Forms) neither in a simple C++ application.
Any suggest?
Thanks
Massimo Tag: How to change font size in the and listview controls Tag: 61530
OpenNETCF HTMLViewer-Control and Hyperlinks
Hello!
I use the HTMLViewer-Control from OpenNETCF on a WINCE-device.
I want to create a hyperlink, which has no line under the Hyperlink-Text.
I use the following HTML-Code, which I assign the Source-Property of the
HTMLViewer-Control. Normally with 'style="text-decoration: none"' you can
force no line. It works fine on PC and with IE on the device but not with
the HTMLViewer. Has anyone an idea what is wrong?
<html>
<head>
<body>
<a href="www.web.de" style="text-decoration: none">My Hyperlink</a>
</body>
</html>
Many Greetings
Dirk Tag: How to change font size in the and listview controls Tag: 61529
Color-picker dialog for CF 2.0?
Does anyone know of a color picker dialog for CF2.0?
Thanks in advance,
Terry Tag: How to change font size in the and listview controls Tag: 61527
Consider app.config remapping of assembly
Folks,
I have a Smartphone Solution with two Projects:
1) Common
References, among others System and System.Windows.Forms
2) Foobar
References, among others: Common, System, and System.Windows.Forms
The Common Project compiles with no warnings.
Foobar, on the other hand, compiles with the following warnings:
Consider app.config remapping of assembly "System.Windows.Forms,
Culture=neutral, PublicKeyToken=969db8053d3322ac, Retargetable=Yes" from
Version "1.0.5000.0" [] to Version "2.0.0.0" [C:\Program Files\Microsoft
Visual Studio
8\SmartDevices\SDK\CompactFramework\2.0\v2.0\WindowsCE\System.Windows.Forms.dll] to solve conflict and get rid of warning.
Consider app.config remapping of assembly "System, Culture=neutral,
PublicKeyToken=969db8053d3322ac, Retargetable=Yes" from Version "1.0.5000.0"
[] to Version "2.0.0.0" [C:\Program Files\Microsoft Visual Studio
8\SmartDevices\SDK\CompactFramework\2.0\v2.0\WindowsCE\System.dll] to solve
conflict and get rid of warning.
Each Project is referencing EXACTLY THE SAME DLL (V2.0.0.0). Nothing is
referencing V1.0.5000.0 DLLS.
In an attempt to fix this, I created new Projects, added the items from the
original Projects, re-added the References, and then removed the original
Projects from the Solution. The first time I built the Solution there were
no problems. Subsequent builds throw the error message.
In another attempt to fix this, I created a foobar.exe.config and added this:
<assemblyBinding>
<dependentAssembly>
<assemblyIdentity name="System.Windows.Forms" Culture="neutral"
PublicKeyToken="969db8053d3322ac" Retargetable="Yes" />
<bindingRedirect oldVersion="1.0.5000.0" newVersion="2.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System" Culture="neutral"
PublicKeyToken="969db8053d3322ac" Retargetable="Yes" />
<bindingRedirect oldVersion="1.0.5000.0" newVersion="2.0.0.0" />
</dependentAssembly>
</assemblyBinding>
This has no affect on the build; the error messages remain.
I am at a total loss. Any suggestions are gratefully appreciated. Thanks.
Joel Finkel
finkel@sd-il.com Tag: How to change font size in the and listview controls Tag: 61526
Smart Device / Web Service development on the road?
I am in the process of developing a CF2.0 based app using VS2005. The app is
a client for a desktop software package and I am using web services to
communicate from the device to the desktop.
I spend some amount of time on the road with no network connection to my
laptop, but I would like to be able work on this application. This would
require setting up the emulator or a synced device with a network connection.
I am wondering how to set up this networking scenario because with no
wireless or wired network connection I have no ability to assign an IP.
Am I missing something simple? Is there a way to set this up?
Thanks! Tag: How to change font size in the and listview controls Tag: 61525
Combining Laszlo and .net compact framework
Hi,
Is anybody worked with Laszlo as the user-interface in .net
compact framework applications ? If yes, pls guide me .
Thanks, Tag: How to change font size in the and listview controls Tag: 61521
Rs232 access under Netcf
I am migrating a set of Apps from the desktop to Netcf. One uses Rs232
access. It uses the techniques outlined in the Msdn article " Use P/Invoke to
Develop a .NET Base Class Library for Serial Device Communications" which
includes the classes CommBase and CommLine.
Unfortunately the CreateFile() does not work.
Do you have any idea if the approach specified in the article can be made to
work at the Netcf level.
If not is there another alternative.
Thanks.
--
John Olbert Tag: How to change font size in the and listview controls Tag: 61518
CF 2.0 deployment
I didn't have much luck on the PPC.developer board. I thought I would
try here too :P
I have an app I want to install on PPC2003 (which does not support CF
2.0). When I make a CAB in VS 2005 is there something I can check or
enable to allow the CF 2.0 to install with my app or do I have to
install them seperatly?
JR Tag: How to change font size in the and listview controls Tag: 61514
About mscoree.stat
Hi:
Someone knows where I can find the exact definition of all counters of
mscoree.stat file (<myapp>.stat)?
Regards Tag: How to change font size in the and listview controls Tag: 61510
MissingMethodException in SmartPhone
I've created a new application that contains 2 projects
A SmartPhone project and a Class library project. I'm still on the
Emulator
I've created few classes in the Class library project and then tried to
create instances of those classes in the Phone Project
The problem is that I can create the class but when I call one of it's
functions I get "MissingMethodException", which is weird because I know
the function is there
Is it wrong to use Class library project in SmartPhone application?
Should I stick to one project?
Can any one tell me what the problem might be
One last remark, The classes I've create are inherited from base class,
I hardly think that is the problem but than, hay, you can never know
thanks Tag: How to change font size in the and listview controls Tag: 61502
Drawing and signature capture module
Hi,
In a .NET CF application, running on Pocket PC WM2003SE, is it possible to
integrate a drawing capture module allowing users to design schemas and to
save them as bmp files ?
For signatures capture, I already saw some examples on the web, but nothing
for drawing / erasing.
Is it necessary to develop such a feature from scratch, or is it possible to
integrate some existing controls ?
Thanks a lot for your help.
Regards,
Samel Tag: How to change font size in the and listview controls Tag: 61499
WM5 Cab problem
I have an application that references Ver 1.2 of OpenNetCF. When I
create my cab file and install it to a new device it works fine as long
as i already installed OpenNetCF. Or at least it works on WM2003. But
today I got an Axim x51 with WM5. Now when I try to install my
application from a cab file, it wont even copy the files to the
directory. It says that it installed correctly, but it doesnt even
create the program directory. Ive slowly been deleting things from the
cab file to find out what is hanging it up, and when i delete the
reference to OpenNetCF it installs fine. Just wondering if anybody
else has had this problem. Ive installed OpennetCF. And if i manually
create my program directory and copy the files in by hand, the program
runs perfect. Its just the cab file that wont deploy when OpennetCF is
included in my references. I would hate to have to strip out my
opennetCF code, cause its a great tool.
Thanks,
Joe Tag: How to change font size in the and listview controls Tag: 61497
Start witout debugging through macro
Hi,
What change should I make to the Alex's 'macro
(http://tinyurl.com/9zotl) so that it lauches the application withou
debugging support (equivalent to ctrl+F5).
Thanks
--
Dinesh Baja
-----------------------------------------------------------------------
Dinesh Bajaj's Profile: http://www.hightechtalks.com/m25
View this thread: http://www.hightechtalks.com/t229223 Tag: How to change font size in the and listview controls Tag: 61492
New MSDN Articles available
Two new articles by OpenNETCF authors went up in MSDN yesterday:
Device Debugging and Emulation in Visual Studio 2005
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnppcgen/html/Device_Debug_VS2005.asp
Learn about how to use the Visual Studio 2005 Device Emulator and debugger
for smart device projects-managed, native, and mixed. (20 printed pages)
---------------------------------------------------------
Using Visual Studio 2005 to Design User Interfaces and Databases for Device
Applications
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnppcgen/html/UI_Data_Designers_NETCF2.asp
Learn about what's new in Visual Studio 2005 for user interface and database
design to use for .NET Compact Framework version 2.0 applications. (36
printed pages)
--
Chris Tacke
Co-founder
OpenNETCF.org
Are you using the SDF? Let's do a case study.
Email us at d c s @ o p e n n e t c f . c o m
http://www.opennetcf.org/donate Tag: How to change font size in the and listview controls Tag: 61486
Creating control from a string
Hi,
How can I create a control whose type is determined at run-time and i
stored in a string?
I tried Activator.CreateInstance, but it didn't work. I am not eve
able to get the control type from the Type.GetType method.
Please help.
Thanks
--
Dinesh Baja
-----------------------------------------------------------------------
Dinesh Bajaj's Profile: http://www.hightechtalks.com/m25
View this thread: http://www.hightechtalks.com/t229217 Tag: How to change font size in the and listview controls Tag: 61484
Windows Mobile app communicating with a Service
I was wondering if it is possible to create a Windows Service in C# and then
have a Window Mobile app send requests / communicate with that service?
What I would like to be able to do is send requests from the Mobile app to
the service, the Mobile app would go to wait state, the Service would execute
a threaded query or non-query against a non-SQL Server database, then the
service returns information back to the Mobile app. If I can get this
working, there would be possibly 30 - 40 mobile devices running
simultaneously requesting from the service.
Is this something that is possible? If so, where do I need to start as far
as research?
Thanks,
David Tag: How to change font size in the and listview controls Tag: 61481
Developing for Windows Mobile 5.0: State of the art
Hi!
I am starting development for Windows Mobile 5.0.
I have received and intalled the "Windows Mobile 5.0 Developer Evaluation
Kit" including Visual Studio .NET 2005 Beta 2.
I have just received the Windows Mobile 5.0 device and it has not .NET CF
2.0 installed...
So I am trying to install the up to date version of .NET CF on my device so
that I can start developing. While browsing the web for this up to date
version I have been confused by the many versions of the .NET Framework
available. I would really appreciate it if someone could clarify the
situation for me.
I have found that the .NET 2.0 and .NET CF 2.0 final are available. However,
as I am using Visual Studio 2005 Beta 2 it seems that I can't use these
versions, I have to stick to the .NET 2.0 Beta 2 and .NET CF 2.0 beta 2. Is
that correct?
Finally, I have seen that Visual Studio 2005 Final has been launced on 11/7.
I have been through the license of Visual Studio 2005 Beta 2 a long ago, and
as far as I can remember users must sease using it as soon as the final
version is out. Therefore can I still use my Beta 2 version today ? or do I
have to order now the final version?
Thanks a lot, your clarifications will be useful.
Regards,
Lionel Reyero Tag: How to change font size in the and listview controls Tag: 61479
Protecting form controls from screen touch!!
Hello,
I want to be able to keep any underlying controls on my ppc application from
activating when the user taps the screen to turn on the backlight. Does
anyone have any VB code that does this?
Thanks in advance,
nb
------------------------------------------
Noble D. Bell
AgForest Partners, Inc. Tag: How to change font size in the and listview controls Tag: 61478
GPS API
I am going through the managed GPS example and trying to convert all the
bits to VB.NET but I have a couple of translation problems if anyone can
advise:
for (int viewIndex = 0; viewIndex < inViewSatellites.Length && found ==
null; viewIndex++)
(no idea what the && found == null bit does)
public bool SatellitesInViewValid
{
get { return (dwValidFields & GPS_VALID_SATELLITES_IN_VIEW) != 0; }
}
I have translated this as:
Public ReadOnly Property SatellitesInViewValid() As Boolean
Get
Return CType((dwValidFields And GPS_VALID_SATELLITES_IN_VIEW),
Boolean)
End Get
End Property
but don't understand what the !=0 is doing????
And finally in a structure there is a property declared as:
public int this[int value]
How does this translate??
Thanks. Tag: How to change font size in the and listview controls Tag: 61477
Callback from native to .net in CF2.0
Is it possible in CF2.0 to create a callback from native code to the .net
application?
Thanks!
Markus Tag: How to change font size in the and listview controls Tag: 61475
kill process & Overflow Exception (VB net)
cf 1.1
I'm facing with killing a process by its name.
I converted some code found on the net from c# to vb and it works very
well except for some pid values. It gives me Overflow exception
'----
Private m_ihandle As IntPtr
Public th32ProcessID As System.UInt32
Public ReadOnly Property PID() As System.UInt64
Get
Return Convert.ToUInt64(th32ProcessID)
End Get
End Property
'...
m_ihandle = New IntPtr(Convert.ToInt64(peCurrent.PID)) ' <--
System.OverflowException - OverflowException
'----
It's funny because
Convert.ToInt32(peCurrent.PID)
gives me a "System.OverflowException - OverflowException"
so I changed it with
Convert.ToInt64(peCurrent.PID)
it retrieve 2799898626 - Long
The matter seems to be with Intptr constructor but, according to MSDN,
It must accept long argument. Has anyone an idea about it?
Thanks
Fabio Tag: How to change font size in the and listview controls Tag: 61473
Which VS.NET 2005 version to download
I'm MSDN Universal Subscriber and switched to Team Edition for
Developers in order to download the latest VS.NET 2005 version. What a
mess the hellish MSDN Subscription is!
I can see Professional Edition 2005 with 10/28/2005 release date and
Team System Release Candidate with a newer release date. Which version
is the latest stable? That is, MS announced few weeks ago that MSDN
Universal Subscribers could download VS.NEt 2005 final version while
DVD is shipped to subscribers. I think they talked about Professional
edition but..........I would like to hear you, developer's opinion.
Thanks. Tag: How to change font size in the and listview controls Tag: 61463
Digitally signing CABS
Hi,
How is everyone else working with digital signatures in cabs. My
understanding is if I sign it then it will only work on smartphones, or with
AS4. If not then it makes the cab useless...
Is everyone producing two cabs, or have you come across another solution?
Mike Tag: How to change font size in the and listview controls Tag: 61462
USB event notifications
Hello,
I'm new to .NET development in general, and I can't seem to find the
answers I need anywhere else. Is there a way in the compact framework
to detect the insertion/removal of a USB memory stick? I have C# code
which needs to inform other modules of these events (specifically flash
memory devices; I'm not interested in other USB device insertions). I
also need to be able to determine the path to the device (assuming I
can still treat it as a regular drive) and perform read/write
operations.
I've seen this question posted on other groups, but they seem to all
have answers based on the use of WMI and the System.Management API of
the full .NET framework. Am I right in saying that this doesn't exist
for the compact framework?
Any answers, links to code samples, other discussions or documentation
would be greatly appreciated.
Thanks,
Ross Tag: How to change font size in the and listview controls Tag: 61460
Auto reconnect to a WiFi connection
I need to make an application (on a Pocket PC 2003) that automaticaly
reconnect when a connection is available. The application is connected live
to a SQLServer 2000 and when i get a broken connection, It shoud display a
message to the user
"Network connection lost, Reconnect?" Ok = Try to connect to the network
(available configured AccessPoint) an perform operation
Cancel = discard operation an wait until user try again
(the message will loop until success or cancel)
The application is destinated to verry novice user and
should be the most transparent as possible... down want them to get to the
device settings...
I'have tryed many things and nothings seem to work!
What i'm doing wrong... is it my device?
Is i understand something wrong?
The pocket PC is a DELL AXIM
2 Wifi acces point (MYACCESSPOINT no WEP KEY and MYACCESSPOINT2 with WEP KEY)
developping in C# using Visual Studio 2003 Compact Framework 1.0 with latest
service pack.
When i start Internet explorer, it automaticaly connect one of my prefered
access point! I also notice that where i am doing test there is a lot of not
configured device (and should hide the connect to a new network wizard)
== First setup: ==
I configure both as prefered devices and connect to one acces point
- I write a simple apps that open a connection on a SQL server on the network
- I goes out of scope the two acces point
- I came back near the acces point and wait... (1 minute and more)
- Try to re open the connection an get an error like "server does not exists"
== Second setup: ==
I read a bit an try the fallowing (with OpenNETCF),
after the error "server does not exists" i call my function
TakeConnection() but the code never break... so never get connected.. ;o(
private void TakeConnection()
{
ConnectionManager oCon = new ConnectionManager();
foreach( DestinationInfo d in oInfo )
{
bool connected = false;
if(d.description == "work")
{
oCon.Connect(d.guid, true, ConnectionMode.Asynchronous);
while(!connected)
{
if(_oCon.Status != ConnectionStatus.Connected)
{
System.Threading.Thread.Sleep(1000);
continue;
}
connected = true;
}
}
}
}
== Third setup: ==
I keept a member instance of ConnectionManager
and call a function like DoConnection at the form initialisation. (same as
TakeConnection with the global member)
The function also register to events OnConnect, OnDisconnect,
OnConnectionFailed, OnConnectionStateChanged...
When i start the app, i got the OnConnect, but when connection goes out of
my access point, never got disconnected or anythings else...
also never get reconnected when the AP becone available.
== Fourth setup: ==
I tryed SetWirelessSettings to force the reconnection to one of my acces
point, it work fine except that
the way the function seems to be impelemeted (in OpenNETCF 1.4) wipe out all
my prefered device and their
configuration. When i call the fallowing code, the wep key of *ALL* my
prefered access point are gone...
(MYACCESSPOINT doesn't get wep key but MYACCESPOINT2 does)
OpenNETCF.Net.AdapterCollection oCol = OpenNETCF.Net.Networking.GetAdapters();
foreach(OpenNETCF.Net.Adapter a in oCol)
{
if(a.IsWireless)
{
a.SetWirelessSettings("MYACCESSPOINT", true, (byte[])null);
a.RebindAdapter();
}
}
if I could fix theese two issue, this could be a nice solution:
- Retreive a way to get the wep key of the AP configured in the deveice
(settings)
- Find a way to SetWirelessSettings without mixed up all the AP configuration
==Conclusion ===========
Thanks a lot for your help,
please help me to get samples or full articles helping me
to demystify that, my deadlines are really short and have no clue where to
look anymore! Tag: How to change font size in the and listview controls Tag: 61459
Handling Resolution aware Controls in VS2005
Hi,
How is it possible to handle the above from within a Control class. Control
does not contain an AutoScaleMode property.
Of course this applys when using GDI.
Cheers
Simon. Tag: How to change font size in the and listview controls Tag: 61458
VS2005 Remote Tools connectivity issues
How do I get the Remote Tools that come with VS-2005 to work with my Custom
WinCE emulation image. My emulator is not displayed in the "Select a
Windows CE Device" dialog when I lauch Remote Registry Editor. The only
custom platform I see is the device image I created but not the emulator
one.
Note: When I launch eVC++ Remote Tools I can connect to my emulator.
However, when I do this it launches another emulation env. that does not
allow me to connect to the one I am debugging using VS-2005.
Thanks Tag: How to change font size in the and listview controls Tag: 61455
best way to trap keyboard input
i've done this via a form but what if i want some global keyboard input
trapping? e.g. irregardless of which form i am in, i want my app to do
something when the user presses on 'A'. what is the best mechanism for doing
this? is there a place where i can define a global keyboard handler trap so
that i don't have to implement KeyPress event handlers in all my forms? Tag: How to change font size in the and listview controls Tag: 61453
Begin Application with hidden form
Hi,
I'm writting a C# CF application in .net 2003. I'm using a trayicon
in my app and want to the application to start hidden rather than show
me the main form.
Can anyone suggest how to keep the form hidden from view at startup ?
Thanks.. Tag: How to change font size in the and listview controls Tag: 61448
Windows CE 4.2 and .NET Compact Framework 2.0
This may be old news to a lot of you, but it's was very good news to me:
http://pluralsight.com/blogs/jimw/archive/2005/11/14/16776.aspx
Thore Berntsen Tag: How to change font size in the and listview controls Tag: 61447
SSCE 2 and RDA
Hi all,
There is a server with
-Windows 2003 Enterprise Edition
-SQL Server 2000
-IIS
I am trying to use Remote Data Access to scyn my data collector with the
above server BUT it fails...
My Data collector has
-.NET CE
-SSCE 2
But the above data collector successfully sync with my office server which
has
-Windows 2000 Advance server
-SQL Server 2000
Q1. CAN you tell me what are the pre-requirements for setting up RDA on a
Windows 2003 Enterprise Edition.?
Q2. What port is activesync using so that I can bypass the firewall by
setting up exception in firewall CAUSE I have to always turn OFF my firewall
before using RDA.
Thanks in advance...
AA Varda Tag: How to change font size in the and listview controls Tag: 61444
Emulator Serial
I am trying to use the serial port (wm5.0 PPC device, CFV2 serial stuff) on
the emulator. I have configured the emulator as follows but get the
following results:
Emulator COM0 maps to PC COM1 - on opening port I get "The Port 'COM0:' does
not exist"
Emulator COM2 maps to PC COM1 - on opening port I get "The Port 'COM0:' does
not exist"
Emulator COM1 maps to PC COM1 - Now I get comms but it seems something in
the emulator is already using that port as it is sending various strings to
emulator COM1 typically: "+SL_TxIntrEx", which I assume is something to do
with ActiveSync on the emulator.
this is the line that throws the port does not exists error:
Port = New System.IO.Ports.SerialPort("COM2", 9600, IO.Ports.Parity.None, 8,
IO.Ports.StopBits.One)
Port.Open()
I have tried it with and without a colon after COM2.
Any ideas how I can get this to work? Tag: How to change font size in the and listview controls Tag: 61439
Threads
Hi,
I have had to developped an application for PocketPC. In this application, I
create 2 threads but then i can´t kill them and i can´t close completly the
application.
¿How can i kill these threads?
Thanks Tag: How to change font size in the and listview controls Tag: 61435
Re: New to .netcf2 and ppc dev
i might just add that what i'm trying to achieve is
a) at any time, only one form is visible in the task manager. i don't want
to see multiple forms for my app appear in that list! looks odd!
b) to instantiate forms only when required so save on memory and to dispose
/ delete them when i'm done. i know i'm not doing this right now in Class1
but this is something i can figure out later once i get the exact mechanism
figured out....is there a way to delete a form from memory in .netcf? i
understand that .netcf does garbage collection when a variable goes out of
scope but is there an explicit way of doing this? or am i thinking too much
in 'old-school' styled C++ ?
"droll" <droll@invalid.com> wrote in message news:...
> ok i think i'm starting to grasp this. i have a problem with multiple
> forms on my app. so i read some stuff around and people recommended
> creating a class that handles the form switching. a couple of questions
> here:
>
> 1. is Form.Close() the same as deleting the instance of the form? if not,
> then how is it different from Form.Hide() ?? only in respect to events
> being fired off?
> 2. i have created a class like so:
>
> public class Class1
> {
> public static Form2 myForm2 = new Form2();
> public static Form1 myForm1 = new Form1();
> }
>
> and i call Application.Run(Class1.myForm1);
>
> in Form1, i have a menu click event where i do:
>
> Class1.myForm2.Show();
> Class1.myForm1.Hide();
>
> and in form2, when i have another menu click event where i do:
>
> Class1.myForm1.Show();
> Class1.myForm2.Hide();
>
> is this correct?? coz i'm seeing strange behaviour as follows:
> a. in Form1, i click on the meu to open Form2.
> b. Form2 doesn't appear. i still see Form1.
> c. i repeat #a again and this time i see Form2.
>
> am i doing this all wrong? :(
> Tag: How to change font size in the and listview controls Tag: 61431
I'm building my first application
I put listview and treeview controls on the phone but the font is too
big
is there any way to make the font smaller?
"okaminer" <okaminer1@yahoo.com> wrote in message
news:1132765742.368559.279090@g44g2000cwa.googlegroups.com...
> I'm building my first application
> I put listview and treeview controls on the phone but the font is too
> big
> is there any way to make the font smaller?
>
Re: How to change font size in the and listview controls by Fabien
Fabien
Sun Nov 27 12:33:11 CST 2005
Hi,
Try this, me it works fine :
myListView.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F,
System.Drawing.FontStyle.Regular);
Best regards.
Fabien Decret
"okaminer" <okaminer1@yahoo.com> a écrit dans le message de news:
1132848418.927325.6910@g43g2000cwa.googlegroups.com...
> The font property is read only
>