Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
A

AndyCheetham

@AndyCheetham
About
Posts
19
Topics
6
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • 30 Today
    A AndyCheetham

    Happy Birthday!! I will be joining the big 30 club sooner than I would like to admit. You sunny out look will make reavaluate my, rather bleak, outlook whilst I having by lunch!! Hope you get out to get some surfing done! Andy :-D

    There are No Stupid Questions. But there a LOT of Inquisitive Idiots.

    The Lounge career

  • Programmer Burn-out
    A AndyCheetham

    I too feel like I'm going through burn-out crisis and have bee for a couple of months. Its comforting to hear that others also suffer as if was starting to feel like I was the only one in world with this dark ominous cloud hanging over head. Its even better to hear the great advise that helps you though these times. For a while now I have living a pretty unhealthy lifestyle, eating too much and hardly exercising at all, and it would seam that this has been contributing to by burn-out more that I had envisioned. However over the past week or so I have started to turn this round I now try and exercise at least every other day and am trying to eat better. Roll on a fitter and more productive me!

    There are No Stupid Questions. But there a LOT of Inquisitive Idiots.

    The Lounge help

  • PC Woes
    A AndyCheetham

    hmmm.... I was worried somebody would say that! Cheers Andy There are No Stupid Questions. But there a LOT of Inquisitive Idiots.

    The Lounge visual-studio help

  • PC Woes
    A AndyCheetham

    I am having a problem with a PC (P4 2.5Ghz) here in the office that is sporadically refusing to boot up. Sometimes it freezes when it is detecting the IDE drives or it may just sit on the Windows XP loading page with the progress bar just scrolling round and round or it may boot up without a problem. I have just installed a brand new hard drive (a Maxtor DiamondMax 10 250Gb) as the old hard drive died :( I did notice that on occasions when I turned the power on all the fancy lights and fans started but I wasn't getting anything else, the BIOS wasn't even beeping. Any ideas or any suggestions as to where I could look to try and diagnose the problem. :confused: Cheers Andy C There are No Stupid Questions. But there a LOT of Inquisitive Idiots.

    The Lounge visual-studio help

  • WC : The end
    A AndyCheetham

    There are 4 matches left, if you include the third place play off!:-D

    The Lounge

  • It's Friday!
    A AndyCheetham

    :)I am off to Switzerland for some skiing - I might also spend a couple of hours in the training course I am supposed to be on, you never know!! Cheers AndyC :)

    The Lounge csharp com data-structures question

  • Never let yesterday's disappointments overshadow
    A AndyCheetham

    I Like "Dreams are like rainbows. Only idiots chase them." :laugh:

    The Lounge adobe question

  • ...Of Course African Swallows Are Non-Migratory...
    A AndyCheetham

    "....your mother was a hamster and your father smells of elderberrys now go away or I shall taunt you a second time." Absolute classic!! I got the Monty Python Film Box set for XMas. Now I can't wait to start watching them. AndyC

    The Lounge python com performance learning

  • [Message Deleted]
    A AndyCheetham

    Like many other have said, it is ime for you to move on. However if he is truly a great friend then the two of you will still have good times toghter in the future (when his wife allows it!!). AndyC

    The Lounge

  • Real or fake smile?
    A AndyCheetham

    16 for me! The eyes are the key!!!:)(its a real one!)

    The Lounge question

  • Virtual List Control with Groups
    A AndyCheetham

    Is it possible to use Groups with a virtual list control? The following line never results evaluates to true, which means I guess that the group id is not being requested? if(pItem->mask & LVIF_GROUPID) I am changing an exsiting list control that work in Non-Virtual mode and the groups work great, so I guess I am adding the group correctly. How would I go about configuring the list control to request the Group ID / info. Any ideas? Cheers AndyC

    C / C++ / MFC question

  • how to "new line" in Cstring?
    A AndyCheetham

    Try CString cs; cs="test string line1 \r\n"; cs +="test string line2\r\n"; cs +="test string line3\r\n"; ... AndyC

    C / C++ / MFC tutorial question

  • Deriving a class from more than one interface
    A AndyCheetham

    One way around this problem would be to build intermediate C++ classes that derive from a single interface and impliments the clashing method by making a pure virtual call on a nonclashing name. For example: struct IXInterfaceA : public IInterfaceA { //Add new non clashing method as a pure virtual virtual HRESULT STDMETHODCALLTYPE DoStuffOnA(void) = 0; //impliment the clashing method STDMETHODIMP DoStuff(void) { return DoStuffOnA(); } } If you do the same for your other interface IInterfaceB Your CSomeClass would look like this. class CSomeClass : public IXInterfaceA, public IXInterfaceB { public: CSomeClass(); // IUnknown HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, LPVOID FAR* ppvObj); STDMETHODIMP_(ULONG) AddRef(); STDMETHODIMP_(ULONG) Release(); // IIntefaceA HRESULT STDMETHODCALLTYPE DoStuffOnA(VOID); // InterfaceB HRESULT STDMETHODCALLTYPE DoStuffOnB(VOID); }; Hope this help, it helped me. Regards Andy

    COM business help question announcement

  • Question about [in, out] parameters
    A AndyCheetham

    I have been trying to write a Method on my COM interface that takes an [in, out] parameter. I expected that this would act like a I was passing in a reference. In the idl file the function is: [id(1), helpstring("method Select")] HRESULT Select([in, out] System** System); In the appropiate hear file the function is defined as: STDMETHOD(Select)(System** System); I use the function as below: //In some cases the pSystem object is created other times it will be null ISystemPtr pSystem(CLSID_System); //or ISystemPtr pSystem = NULL; //The Select Method will display a dialog with a set of options, if the object being passed in is //NOT NULL the dialog should have the correct / relavent options selected. If it is NULL the //pSystem object will be created with the selected options and passed back to the client. TheObjectWithTheMethod->Select(&pSystem); The problem is that when an valid (not NULL) pointer is passed into the function the & operator actually releases the pointer to the pSystem and returns a NULL interface pointer. So inside the implimentation of the Select function we always get a NULL pointer. Does anubody have any ideas? Cheers Andy

    COM question com help

  • XML Date type
    A AndyCheetham

    Hi, I have an element defined in a schema of type date, I was wondering if there was, and if so how, I could simply store a year in this element. For example I would simple like the element to appear like so: 1970 When I run this throught XMLSpy it throws the error "Value out of range for datatype date". The scheme entry is ... Cheers Andy

    XML / XSL xml database help tutorial

  • XML schemas for begginers!
    A AndyCheetham

    Hi Guys, I am relatively new to XML and it's associated technologies and was looking for some help / advice. We have a bunch of classes that are arranged into a hierarchy and we now want to represent these classes in XML. Its just so happens that there is already a standard for encoding the object which my classes represent into XML. This encoding is represented in a set XML Schemas. XML schemas is something before today I knew very little about, so I have spent that afternoon reading up on them. Now I have an understanding of what they are and what they do / represent. What I need now is some direction on how to accomplish the task in hand. What I am asking for is some help / advice on how I should now go about using the schemas to create some XML. It does look very much like the XML elements and my classes could be one in the same, so it is very tempting to add a "GetXML" function to my classes. I am reluctant to do this as I am trying to keep my classes very light weight and loosely coupled to other classes. Should I therefore create a set of classes based on the elements in the schema, and these objects get constructed from my current set of classes, and these new classes have the "GetXML" function. It does sound like I am almost answering my own question, and it is sounding less and less like an XML question and more of a structural question. But I would be very interested in any feed back from anybody who has faced and solved similar problems when dealing with encoding objects to XML. Cheers AndyC :)

    XML / XSL xml css database help tutorial

  • List Control with Grouped View
    A AndyCheetham

    Hi David Thanks for your input. Just thought I would let you know that I have solved the problem. You need to include the following line in the rc file! CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "GLook.manifest" where Glook.manifest id replaced with the file name for the manifest file for your application. Unfortunately this is mentioned in the help file that I looked at when I first started looking into the problem. One day I will learn to read instructions more carefully.;):doh: Thanks for your help Andy

    C / C++ / MFC visual-studio debugging business tutorial question

  • List Control with Grouped View
    A AndyCheetham

    The problem is that the groups are not being displayed. When the lsit control gets displayed the two Items are present but like I said there are no groups. The code included in my original post is a bit of proof of concept code, ie just to see the groups working. I was convinced that none of the functions were returning error codes, so I have been back and checked just to be sure. None of the functions return an error code, however what doesn't seem right is the fact that bot calls to InsertGroup returns 0 it should return "index of the item that the group was added to". So I would expect the first call to return 0 but the second call I would expect to return 1. Cheers Andy

    C / C++ / MFC visual-studio debugging business tutorial question

  • List Control with Grouped View
    A AndyCheetham

    Has anybody managed to get the grouping working with the list control (as seen in My Computer as it separates your hard drives from your CD ROMs for example)? It feels like I have been banging my head against a brick wall all afternoon trying to get it to work with no joy. I have created a new project with VS 2002 so I assume all the manifest requirements have been met. I then get the list control from the CListView and add a group using the InsertGroup() function. I then insert two items using the InsertItem() function and for each item I set the Group ID to the corresponding group. This is the code I have so far. I would be eternally grateful if someone could point out what I am not doing correctly or have failed to do all together. //Get the listCtrl from the View CListCtrl& ctrl = GetListCtrl(); //View control in icon veiw ctrl.ModifyStyle(0, LVS_ICON); //Enable the Group View so we can group the entries ctrl.EnableGroupView(TRUE); //Add a Column ctrl.InsertColumn(0, "Name"); ctrl.SetColumnWidth(0, 300); //Add the groups to the control LVGROUP* pGroup = new LVGROUP; if(pGroup != NULL) { ZeroMemory(pGroup, sizeof(LVGROUP)); pGroup->cbSize = sizeof(LVGROUP); pGroup->mask = LVGF_HEADER | LVGF_ALIGN | LVGF_STATE | LVGF_GROUPID; pGroup->pszHeader = L"Coordinate Reference Systems"; pGroup->cchHeader = 28; pGroup->stateMask = 0; pGroup->state = LVGS_NORMAL; pGroup->uAlign = LVGA_HEADER_LEFT; pGroup->iGroupId = 0; LRESULT res = ctrl.InsertGroup(0, pGroup); TRACE("Group added"); } //Add a second group LVGROUP* pGroup2 = new LVGROUP; if(pGroup2 != NULL) { ZeroMemory(pGroup2, sizeof(LVGROUP)); pGroup2->cbSize = sizeof(LVGROUP); pGroup2->mask = LVGF_HEADER | LVGF_ALIGN | LVGF_STATE | LVGF_GROUPID; pGroup2->pszHeader = L"Coordinate Reference Systems"; pGroup2->cchHeader = 28; pGroup2->stateMask = 0; pGroup2->state = LVGS_NORMAL; pGroup2->uAlign = LVGA_HEADER_LEFT; pGroup2->iGroupId = 1; LRESULT res = ctrl.InsertGroup(1, pGroup2); TRACE("Group added"); } //Add a couple of items LVITEM* pLVItem = new LVITEM; ZeroMemory(pLVItem, sizeof(LVITEM)); pLVItem->mask = LVIF_GROUPID | LVIF_TEXT; pLVItem->iItem = 0; pLVItem->iGroupId = 0; pLVItem->pszText = _T("Andy"); pLVItem->cchTextMax = 4; ctrl.InsertItem(pLVItem); LVITEM* pLVItem2 = new LVITEM; ZeroMemory(pLVItem2, sizeof(LVITEM)); pLVItem2->mask = LVIF_GROUPID | LVIF_TEXT; pLVItem2->iItem = 1; pLVItem2->iGroupId = 1; pLVItem

    C / C++ / MFC visual-studio debugging business tutorial question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups