|
I have this problem with a pocket pc app that I'm working on. The app runs beautifully while the device is running, but when it comes back after sleeping, my app crashes. I'm don't know how to debug this situation since the debugger stops when the device goes to sleep.
Does anyone have any advice on how to debug in this situation?
I'm using activesync 4.5, windows mobile 2003 on pocket pc, VS 2003.
Thanks for your help!
"In the middle of difficulty lies opportunity." Albert Einstein
|
|
|
|
|
If I'm stupid for asking this could someone just tell me so? Please? Or is this just impossible?
|
|
|
|
|
Hi Muthiah,
MuthiahR wrote: Is there any solution to track End/Power button key in modal dialog?
You can handle WM_KEYUP on any key in a modal dialog if you answer to WM_GETDLGCODE with DLGC_WANTALLKEYS .
The SmartPhone key mapping is in <your sdk>\winuserm.h: identifiers begin with VKT_ .
MuthiahR wrote: I am unable to termiate the application from modal dialogs using End/Power button on keypad
Well-behaved mobile applications are 'minimized' (actually set to the bottom of the Z-order) by user or program action and closed by the system when appropriate.
cheers,
AR
|
|
|
|
|
Edit: this is a response to a deleted message
Hi Muthiah,
Looks like it's time for you to stop typing and read some doc.
That could save much of your time (and mine ).
Check your doc for LVN_KEYDOWN.
cheers,
AR
-- modified at 16:15 Monday 1st October, 2007
|
|
|
|
|
Hello AR,
In your previous reply to my post regarding closing or terminating mobile applications, you mentioned,
"Well-behaved mobile applications are 'minimized' (actually set to the bottom of the Z-order) by user or program action and closed by the system when appropriate."
Right now, I am posting a message to main dialog and calling Destroy Window and PostQuitMessage functions to close my applications. Is this correct way to do it? or Is this what you mentioned in your reply?
If not, can you please provide me with some reference? I tried to find or read more about this, but in vain. Your time and reply is greatly appreciated.
Thanks,
Muthiah.
|
|
|
|
|
Hello,
WM 5.0
VS 2005
I have a mobile application that I want to install on a PDA. However all the PDA will not have the CF 2.0 on them.
I have looked a many articles and none of them address the situation if the compact frame is not already installed.
Doe anyone know of any articles where the setup will install compact frame work if it is not already on the PDA.
Many thanks,
Steve
|
|
|
|
|
hi Steve,
When ever you Installing CAB File on PDA, that time you can install CF2.0 (CAB File NETCFv2.ppc.armv4.cab) First.
Pavan Pareta
|
|
|
|
|
steve_rm wrote: Doe anyone know of any articles where the setup will install compact frame work if it is not already on the PDA.
All you have to do is to right click on the .NET Compact Framework Merge Module in your setup and deployment and choose "Include" to include it with your CAB. It will increase the size of your installer quite a bit though.
Pete Soheil
DigiOz Multimedia
http://www.digioz.com
|
|
|
|
|
Hello
VS 2005
CF 2.0
WM5
I have created an application that scynchronizes the central database by sending changes to a web service.
This normally takes 5 to 10 seconds and the customer wants to have some kind of progress bar to show that something is happening.
This is some code that would explain what needs to be monitored. (Only showing the main parts - otherwise to much code to show)
<br />
'Synchronise Data with the central database<br />
Private Sub MenuItem9_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItem9.Click<br />
<br />
Try<br />
<br />
If (dsIncidents.HasChanges()) Then<br />
<br />
dsChanges = dsIncidents.GetChanges()<br />
<br />
'Send only the changes and return a fresh update from the central database<br />
<br />
Dim updatedIncident As DataSet = ws.SynchroniseIncidentChanges(dsChanges)<br />
<br />
'Assign to the global dataset<br />
<br />
Dim objGlobals As New Globals()<br />
<br />
objGlobals.IncidentData = updatedIncident<br />
<br />
Else<br />
<br />
'There was not changes made to the PDA incidents, so just download the latest incidents<br />
<br />
Me.GetLatestIncidentData()<br />
<br />
End If<br />
<br />
End Try<br />
<br />
End Sub<br />
So when the code above is running it should display a progress bar to show how long it will take. Or it could show just a animation so the customer knows there is something going on in the background.
Many thanks for any advice and code samples,
Steve
|
|
|
|
|
Hello,
I am looking for a solution wherein, in a system with Windows XP Embedded, a user boots into my custom application shell, but can switch to the Windows explorer shell, or vice versa, if he so pleases, without having to reboot or log off.
Or can this be possibly better applied by having a theme sort of implementation, much like that in XP desktop, where user have the ability to load different themes? If so, how should I go about it?
Thanx in advance...
-- modified at 0:08 Thursday 27th September, 2007
|
|
|
|
|
I am now using Embedded Visual C++ 4.0 my applications seems to be all in 256 colors rather than the device supported 16-bit color even on the emulator it shows that its compiled with 256 mode. How do I change this?
Thanks
samuel
|
|
|
|
|
please any one help me regarding use timer start & stop in c# mobile CE 5 application.timer1 .start and stop ,pause not working in c#.
please help me
Ram Krishna Pattnayak
Software Developer(SDS)
Sun-Dew Solutions Pvt.Ltd
www.sundewsolutions.com
kolkata
|
|
|
|
|
hi guys
Im transfering data from sql server 2005 to
comapact framework database (*.sdf)
My way to do so is :
Export the table into an XML file (using DataTable)
dt.WriteXml(FName, System.Data.XmlWriteMode.IgnoreSchema)
And on the mobile device I load the XML and save the Dataset
dt.ReadXml(FileName)
da.Update(DataSet11)
Everything is working only my table contains about 1500 records (20 fields)
and it takes about 6 minutes to load and save.
Is there any way or Method to do this any faster ?
Thanks in Advance
Dan.
|
|
|
|
|
Rather ironically for something called 'SQL Server CE', the SQL language is the worst, slowest way to do anything. If you're using .NET Compact Framework 2.0, the solution for loading data that's the fastest to execute while still being pretty readable and maintainable is to use the SqlCeResultSet class.
To do this, create a SqlCeCommand , passing just the name of the table to modify in the query text parameter. Then set the command type to CommandType.TableDirect . Associate it with an open SqlCeConnection and call ExecuteResultSet , using the ResultSetOptions.Updatable option. Then, on the SqlCeResultSet , call CreateRecord to get a new record, set the record's properties, then call Insert to insert it into the table.
See SQL Server Compact Edition Insert Performance[^] for details on just how big a difference this makes.
Equally, a direct table access operation is far, far faster than SELECTing from that table - not just time to first row being returned, but even the time to access each subsequent row. To access the results in a particular order, you can use the IndexName property to use a named index on the table, and you can use the SetRange method to restrict the set of results that are returned.
DoEvents : Generating unexpected recursion since 1991
|
|
|
|
|
|
Hello!
I'm starting to create some PPC aplications, but on a start I have a problem. After creating fresh new PPC project I have no device skin in designer view. Everything in options is set right.
|
|
|
|
|
Hello,
I am writing a smartphone application in visual C++ using WTL. And I want to change background color in progress bar. I am using following code to do this functionality.
CProgressBarCtrl m_ProgressBarCtrl;
m_ProgressBarCtrl.SetBkColor(RGB(0,255,0));
When I compile this code, I am getting following error:-
***********************************************************************************************
error C2039: 'SetBkColor' : is not a member of 'WTL::CProgressBarCtrlT<tbase>'
with
[
TBase=ATL::CWindow
]
***********************************************************************************************
I don't know what else to do to change background color of progress bar.
Can anyone help me with this?
I'd really appreciate it.
Thanks,
Muthiah.
|
|
|
|
|
Hi Muthiah,
MuthiahR wrote: error C2039: 'SetBkColor' : is not a member of 'WTL::CProgressBarCtrlT<tbase>'
The WinCE Progress bar control doesn't support the underlying PBM_SETBKCOLOR message, so WTL::CProgressBarCtrlT<TBase>::SetBkColor() is not present on WinCE platforms.
MuthiahR wrote: I don't know what else to do to change background color of progress bar.
Subclass your progress bar and handle WM_ERASEBKGND at your liking.
cheers,
AR
|
|
|
|
|
Thanks for the information. And I will try this.
Thanks again,
Muthiah.
|
|
|
|
|
I tried it and works fine. Thanks A.R.
Regards,
Muthiah.
|
|
|
|
|
How do I programmatically set the Extra Initialization string on the modem when making a RAS connection through a GSM – GPRS modem device to get TCP/IP connectivity through the ISP provider to the internet??
Here’s the Extra Initialization string needed on the modem for RAS: +CGDCONT=1,"IP,"IPS.CINGULAR"
Here’s my targeted device environment:
OS: Windows CE 5.0 (using .Net Compact Framework 2.0)
Here’s the sample code that I’m calling to connect to a RAS phonebook entry profile.
namespace TestDevices
{
class RasWrapperII
{
[DllImport("coredll.dll")]
public static extern uint RasDial(IntPtr dialExtensions,
IntPtr phoneBookPath,
IntPtr rasDialParam,
uint NotifierType,
IntPtr notifier,
ref IntPtr pRasConn);
[DllImport("coredll.dll")]
public static extern uint RasHangUp(IntPtr pRasConn);
///
/// EntryName ,UserName,Password - same as in RASDIALPARAMS structure (see MSDN)
///
/// <param name="EntryName" />
/// <param name="UserName" />
/// <param name="Password" />
/// <param name="RasConn" />
/// <returns>
unsafe public static uint myRasDial(string EntryName, string UserName, string Password, out IntPtr RasConn)
{
uint r = 0;
RasConn = IntPtr.Zero;
byte[] bRASDIALPARAMS = new byte[1464];
fixed (byte* pAddr = bRASDIALPARAMS)
{
byte* pCurrent = pAddr;
Marshal.WriteInt32((IntPtr)pCurrent, bRASDIALPARAMS.Length);
pCurrent += 4;
foreach (byte b in Encoding.Unicode.GetBytes(EntryName))
{
Marshal.WriteByte((IntPtr)pCurrent, b);
pCurrent++;
}
pCurrent = pAddr + 0x192; //0x192 - offset for RASDIALPARAMS.UserName
foreach (byte b in Encoding.Unicode.GetBytes(UserName))
{
Marshal.WriteByte((IntPtr)pCurrent, b);
pCurrent++;
}
pCurrent = pAddr + 0x394; //0x394 - offset for RASDIALPARAMS.Password
foreach (byte b in Encoding.Unicode.GetBytes(Password))
{
Marshal.WriteByte((IntPtr)pCurrent, b);
pCurrent++;
}
r = RasDial(IntPtr.Zero, IntPtr.Zero, (IntPtr)pAddr, 0, IntPtr.Zero, ref RasConn);
}
return r;
}
}
}
The Call Code:
IntPtr conn; // connection handle
uint rc = RasWrapperII.myRasDial(this.txtPhoneNbr.Text, this.txtUserName.Text, this.txtPassword.Text, out conn);
if (rc == 0)
{
try
{
TcpClient client = new TcpClient();
client.Connect("www.amazon.com", 80);
MessageBox.Show("Successful Connection!", "TCP Client Call", MessageBoxButtons.OK,
MessageBoxIcon.Exclamation, MessageBoxDefaultButton.Button1);
}
catch (Exception ex)
{
MessageBox.Show("Connection Failed! Reason=" + ex.Message, "TCP Client Call", MessageBoxButtons.OK,
MessageBoxIcon.Exclamation, MessageBoxDefaultButton.Button1);
}
RasWrapperII.RasHangUp(conn);
}
else throw new ApplicationException("Return Code: " + rc.ToString());
Thanks in advance for any help that someone can provide.
-Bill
-- modified at 18:04 Friday 21st September, 2007
|
|
|
|
|
It's not officially supported, I'm afraid. The 'Extra Dialling Commands' field is a field of the opaque structure pointed to by the lpbDeviceInfo parameter passed to RasSetEntryProperties which isn't officially documented. Strictly it can be whatever the TAPI (Telephony API) provider for this phonebook entry wants it to be.
For standard dial-up connections, though, the TAPI provider is the Universal Modem (Unimodem) provider. If you have access to the Windows CE shared source code, you discover that it's a DEVMINICFG structure. You'll have to see that source for the definition of the structure and how to use it.
The only supported way of editing this information programmatically is on Windows Mobile 2003 and later, using configuration XML with the CM_PPPEntries configuration service provider. However, normally WM2003 and later devices with a GSM/GPRS radio will ship with Phone Edition and offer a direct Cellular Radio TAPI Provider, which can be used with the CM_GPRSEntries configuration service provider.
DoEvents : Generating unexpected recursion since 1991
|
|
|
|
|
Thanks Mike for the information about the DEVMINICFG structure under the TAPI, at least now I have a starting point to check into!
|
|
|
|
|
Could you please provide the code to set the unimodem dial up connection properties on Win ce 5 using c#... I need to set programatically baud rate, stop bit, flow control, extra dial up string etc.,
Thanks in advance...
my mail id is prajwal_ap@yahoo.co.uk
|
|
|
|
|
hi sir,
I am developing a windows application in C# where i have a small part to send sms to the number specified. i went through the article
http://support.microsoft.com/kb/555578.
(SMS services in ASP.NET Mobile Web Application)
and i used the webservice which you have mentioned here. i am not developing a mobile asp.net application but a normal windows application in C# 2005.
i added the webreference to the webservice and used the code. when i run the application,
however i get a error saying that a firewall is not allowing to estabilish remote connections and that a exception is set. i removed all exceptions and run the program again.
i still get the same problem.
Can you please suggest me any ideas on how to proceed?
Thanks in advance
Regards
Anuradha
Thanks in advance.
Regards
Anuradha
|
|
|
|
|