|
hi,all
In my EVC4 project, I need to show a 800*600 bmp picture to a window which
size is 80*50,
I do it in the window's paint function:
Paint(CDC& dc)
{
CDC memDC;
memDC.CreateCompatibleDC(&dc);
HBITMAP oldBmp = (HBITMAP)::SelectObject(memDC.m_hDC, m_hBitmap);//m_hBitmap
is the my bmp picture's handle
StretchBlt(dc.m_hDC,0, 0, 80, 50 ,
memDC.m_hDC, 0, 0, 800 , 600, SRCCOPY);
memDC.SelectObject(oldBmp);
//Copy the content from Memory DC to current DC
dc.BitBlt(0, 0, 80 , 50, &m_MemDC, 0, 0, SRCCOPY);
//here, the picture was showed. But the size is not exactly as 80*50, it is
about 80*40
}
Does anyone happend it before?
And also, in msdn, in stretchBlt(), it says "The only raster operations
Windows CE supports in the dwRop parameter are SRCCOPY and SRCINVERT. Windows
CE does not support mirroring.
" What does mirroring means?
Thanks
|
|
|
|
|
Hi,
Just having a play around with the File control in eVB. Does anyone know how to use it to determine how many lines there are in a text file. I'm trying to send each line of a text file to a portable printer which I have working but need to know how to do the above.
Many thanks in advance.
|
|
|
|
|
Hi,
I'm writing a program and i need to detect when user uses keyboard.
Actually i want to resize some controls in my dialog when user uses keyboard.
and when the user close it(the keyboard panel), the program should change the control sizes to default sizes.
I'm looking for message handler or something ...
Platform: PPC 2003, eVC++ 4.0
Regards,
Hadi
|
|
|
|
|
Have anybody tried to use XMLDomDocument e.t.c. in Pocket PC???
I need some examples - who can share them ?
|
|
|
|
|
hi!
how can i set the path environment variable on a pocket pc 2002 device.
thanks
|
|
|
|
|
hi!
i am writing a program that requires me to change the MAC address of my PDA
through a program. I have a C++ program to do just that - it changes the
value in the registry. To prevent a restart to allow the new MAC to take
effect, it uses functions in the Windows COM Interface that allow you
to change an adapter's MAC address without needing to restart. this needs
netcon.h which i cant find in the pocket pc SDK which leads me to velieve
that the functionality is not there for pocket pc.
so is there any other way to do this?
thanks
cheers
|
|
|
|
|
Hi everyone,
I need help in getting the unique device identifier(device id) of a pocket pc using EVC++ functions.I need this to generate unique registration codes to my products to stop piracy of my products.
Thanks.
Chandru
|
|
|
|
|
|
#include "winioctl.h"
extern "C" __declspec(dllimport)
BOOL KernelIoControl(
DWORD dwIoControlCode, LPVOID lpInBuf, DWORD nInBufSize,
LPVOID lpOutBuf, DWORD nOutBufSize, LPDWORD lpBytesReturned
);
#define IOCTL_HAL_GET_DEVICEID CTL_CODE(FILE_DEVICE_HAL, 21, METHOD_BUFFERED, FILE_ANY_ACCESS)
CString GetSerialNumberFromKernelIoControl()
{
DWORD dwOutBytes;
const int nBuffSize = 256;
byte arrOutBuff[nBuffSize];
BOOL bRes = ::KernelIoControl(IOCTL_HAL_GET_DEVICEID,0, 0, arrOutBuff, nBuffSize, &dwOutBytes);
if (bRes)
{
CString strDeviceInfo;
for (unsigned int i = 0; i<256; i=i+1)
{
CString strNextChar;
strNextChar.Format(TEXT("%02X"), arrOutBuff[i]);
strDeviceInfo += strNextChar;
}
CString strDeviceId =
strDeviceInfo.Mid(40,2) + strDeviceInfo.Mid(45,9) + strDeviceInfo.Mid(70,6);
return strDeviceId;
}
else
{
return _T("");
}
}
hi,let's go ...
|
|
|
|
|
Hi,
I am new in using eMbedded Visual C++ 4.0. I want to create a project which can accept Chinese Resoure file. I am trying to create a project with "Chinese as language for resource", but I don't see an option for Chinese Language. I do see "French, Germany, Italy etc...".
I appreciate if some one can help me in this.
Thanks
V V
|
|
|
|
|
A question and some info...
Is it possible to write multiple bitmaps to a memDC and then 'copy' that memDC to a Device DC in order to avoid image 'flutter' or flicker?
Under Windows CE there is the ::TransparentImage function, for copying a memory DC to a Device DC with a transparent colour.
The function also accepts a bitmap handle in place of a memory DC: so there is no need to Select a bitmap into a memDC beforehand.
The following function demonstrates its use. In my project I make several calls to my function with diffent bitmap IDs to form a 'layered bitmap' image on the device DC (screen in my case).
void CWizzHMIDlg::DrawTransparentBitmapDirect( CDC *pDC, WORD BitmapID, POINT Posn, COLORREF TransparentColor)
{
CBitmap Bitmap;
BITMAP BmpInfo;
Bitmap.LoadBitmap(BitmapID);
Bitmap.GetBitmap(&BmpInfo);
::TransparentImage(
pDC->m_hDC,
Posn.x, Posn.y,
BmpInfo.bmWidth, BmpInfo.bmHeight,
Bitmap.m_hObject,
0,0,
BmpInfo.bmWidth, BmpInfo.bmHeight,
TransparentColor);
}
I have tried various ways to copy several bitmaps on a memDC first, before copying to the device DC, but to no avail. Using a memDC parameter with TransparentImage does not appear to work more than once.
Regards & Thanks, Jack@SIL
|
|
|
|
|
Hi all,
For the treeView Control in .Net CF, the afterCollapse event is missing. But I need to trigger some action when the user click the
minus button on the tree, what should I do ?
Thanks
Patrick
|
|
|
|
|
hi,
does anyone know the difference between class 1 and class 2 in Bluetooth?
i know it's somthing about the range,but i need more details.
regards,
eli
|
|
|
|
|
Hi
Is there any possibility to connect WinCE (Simpad) to regular MS SQL Server without SLQ Server CE and webservices?
My "mobile" devices are wall mount, so there's no need to local store data on them. I wanted to use regular SQL CLient as always do in windows forms but there is "PlatformNotSupportedException" thrown when playing with simulator - I've not tested it on physical device.
Any ideas?
|
|
|
|
|
Hello,
I developed a Web-Service which i want to consume from a Smart Device Application. I developed the Smart Device Application and create a Web Reference to the Web Service, but when i want to test the Smart Device Application in the Emulator the following error occurs:
A managed WebException occured at SoapHttpClientProtocol:doInvoke+0x23f
Unable to connect to the remote server
SoapHttpClientProtocol::doInvoke+0x23f
SoapHttpClientProtocol::Invoke+0x9
Service1::GetHypotenuse+0x17
Form1::ctor+0x3a
Form1::Main+0x5
Ok to terminate
Other Desktop WebClients which consumes WebServices on my Desktop works, and also a MobileWebApplication which consumes the same WEb-Service as the SmartDeviceApplication works, only when i want to test the Smart Device Application in the Emulator the error occurs. I think it may concerns the emulator because when i want to browse in the emulator in the pocket explorer to a site, it does not work.
Can anybody help me??
|
|
|
|
|
hi!
i am trying to build OpenSSL for pocket pc 2002 using EVC++ 3.0
the first problem is when i do an nmake, i get an error saying it can tfind windows.h
i have executed WCEARM.BAT to set up the environment and also included the path to pcket pc2002 sdk\include in my PATH and INCLUDE variables.
the other problem that i get when doing a make (i copied the all the include files to a folder beneath the current directory) is that
cryptlib.c
.\crypto\cryptlib.c(513) : error C2220: warning treated as error - no object file generated
.\crypto\cryptlib.c(513) : warning C4013: 'abort' undefined; assuming extern returning int
NMAKE : fatal error U1077: 'clarm.exe' : return code '0x2'
Stop.
and i hav no clue about it
can someone help?
thanks
|
|
|
|
|
I have a annoying problem with PocketPC emulator and ActiveSync.
Have followed http://blogs.msdn.com/exchange/archive/2004/02/23/78930.aspx and then installed Emuasconfig and Windows Mobile Powertoys as i have read in forums and on pages.
Did a search here and tried all kinds of things but keep getting an annoying error and can't use ActiveSync at all with the emulator!
The error message i am getting is
Error in starting ActiveSync Connection
I am out of ideas why it keeps giving me that.
/Forser
|
|
|
|
|
|
It syncs but dies and gives me
Critical communications services have failed to start.
/Forser
|
|
|
|
|
|
|
Hi!
I followed that and i get
Critical communications services have failed to start.
when it is trying to sync, I have no firewall running so it isn't that.
/Forser
|
|
|
|
|
Did you run the command line configuration app as the document says? This solved my connection problems with the PPC 2003 emulator.
Regards,
João Paulo Figueira
Embedded MVP
|
|
|
|
|
Yes, i ran /ppc flag..
/Forser
|
|
|
|
|
Forgot to say that i don't run Embedded C++ at all..
Maybe that makes it not working?
/Forser
|
|
|
|
|