|
I don't quite follow you. You wanted to know how to obtain the timezone using Visual C++. I suggested you use GetTimeZoneInformation() . Now you are talking about browsers and XML files. What exactly is it that you are looking for?
"Money talks. When my money starts to talk, I get a bill to shut it up." - Frank
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hi..can anyone help me out of thiss???
i trying to load a a ImageList of 24Bit Color Bitmap , but when it draw on a Static Control ot Losses it Quality to 16 Color im doing this to load a Image List :
/////////////////////////////////////////////////////////
[B]
CImageList m_imgList;
HIMAGELIST hImageList = ::ImageList_LoadImage ( AfxGetInstanceHandle(),
_T("d:\\total.bmp"),
64, 32,
RGB(255,255,255),
IMAGE_BITMAP, LR_LOADFROMFILE);
if(NULL != hImageList)
{
BOOL bRet = m_imgList.Attach(hImageList);
HICON m_hIco = m_imgList.ExtractIcon(0);
//CStatic Control on Dialog with SS_ICON
m_bBitmap.SetIcon(m_hIco);
}
/////////////////////////////////////////////////////////[/B]
i also tried to Draw the Extracted Image to Dialog box by calling the Funtion in CImageList
Draw(....); and DrawIndirect(...); and same problem done in this Also.. the Quality of Image loss
please please help me out of this
|
|
|
|
|
It's my recollection that you need to create an empty image list and copy the 24 bit images into it in order for them not to revert to the lower bit depth.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
thnx for reply... but can you tell me how to copy the 24bin image to CimageList.. and i want to Animate the Images, but if i load one by one image into the Imagelist in Startup initailization then it takes a lot resource and thr will be lots of bitmap image files in the skin folder. like if i want to create a animation of 20 frames then user have to create the 20 images , and i think its better if we use a Image List instead of loading a Single bitmap into imagelist without lossing qualit !
please tell me a way out of this.. thnx
|
|
|
|
|
There are actually articles on this site with 24 bit images in toolbars. It would be easier for you to read one of them than for me to repost the code here.
If you want to create a 20 frame animation, you will need to load 20 images, they take up the same size in an image list as they do in a bitmap.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Can I use serialization on a RecordSet Class? To be more exact. I have a program which does all sorts of things with a database. Can I save the results of a querry in a file? And can I load them when I want?
|
|
|
|
|
tanarnelinistit wrote: Can I use serialization on a RecordSet Class?
Yes.
tanarnelinistit wrote: Can I save the results of a querry in a file? And can I load them when I want?
Most definitely (to both).
"Money talks. When my money starts to talk, I get a bill to shut it up." - Frank
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
|
Sanroop wrote: bitmaps to combobox
See Here
[^]
Somethings seem HARD to do, until we know how to do them.
_AnShUmAn_
|
|
|
|
|
You can derived CComboBox and use from WM_DRAWITEM
like this
void CMyCombo::DrawItem(LPDRAWITEMSTRUCT lpDrawItem)
{
CDC dc;
CString str;
dc.Attach(lpDrawItem->hDC);
CRect rect(lpDrawItem->rcItem);
...
...
DrawIconEx(dc.GetSafeHdc(),rect.left,rect.top,
hIcon,0, 0, 0, NULL, DI_NORMAL);
...
...
dc.Detach();
}
|
|
|
|
|
I have a structure x which have a CString s; in it. I have created a pointer to that structure; In one of my functions i want to assing a string to that 's'; i wrote px->s = "y"; There i am getting an debug assertion failure window.
Can u show me the way.
Thank you.
KIRAN PINJARLA
|
|
|
|
|
did you create the structrure with the new operator?
modified 9-Mar-17 17:14pm.
|
|
|
|
|
|
why creating the struct in the heap ?
no need to call new .
|
|
|
|
|
Then how do you want to create the struct???
Dream bigger... Do bigger...Expect smaller
aji
|
|
|
|
|
struct TestStr {
CString m_str;
};
TestStr varTS;
varTS.m_str = _T("Another way");
TestStr* pTS = &varTS;
pTS->m_str = _T("Hello");
|
|
|
|
|
toxcct wrote: TestStr* pTS;pTS->m_str = _T("Hello");
this time to what pTS is points to????
Dream bigger... Do bigger...Expect smaller
aji
|
|
|
|
|
my mistake. fixed it. see the previous post.
|
|
|
|
|
Dream bigger... Do bigger...Expect smaller
aji
|
|
|
|
|
can you please show us the code around where it crashed ?
i see no pb in the line you shown, but maybe px is pointing to nowhere (NULL ?)...
|
|
|
|
|
USER * pUser = new USER;
if (NULL == pUser)
{
return NULL;
}
ZeroMemory(pUser, sizeof(USER));
pUser->pMember = pMember;
hr = pMember->GetName(&bstr);
if (FAILED(hr))
{
AddLog("Problem with GetName");
}
else
{
name = BSTRtoStr(bstr);// THIS IS MY FUNCTION
//pUser->strName.Insert(0,name); -----******* HERE WHERE IT IS CRASHED
SysFreeString(bstr);
m_ListMembers.InsertString(-1,name);
}
KIRAN PINJARLA
|
|
|
|
|
|
typedef struct USER
{
INmMember *pMember; //INmMember is a componant Interface
CString name;
}USER;
KIRAN PINJARLA
|
|
|
|
|
why do you use CString::Insert() instead of CString::Operator = ???moreover, how is declared name ??
|
|
|
|
|
Actually i tried all assignments of CString and insert was one of it.
I tried name =..., name.Format("%s",...
But it doesnt work.
KIRAN PINJARLA
|
|
|
|