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
R

Rick Dangerous

@Rick Dangerous
About
Posts
18
Topics
2
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • File open dialog misery
    R Rick Dangerous

    Hi, I have created an Explorer extension to provide a custom column. This column is quite happy being turned on and off on a per folder basis in Explorer - I can tell any particular folder whether to display the column. Now, in my application, I want to do a file open dialog (CFileDialog, GetOpenFilename() etc). This is all ok and after no small effort I have managed to get this dialog to use the 'Report' view by default for the ListView control. The problem is that the dialog only shows the default columns (Name, Size, Type etc...) and pays no attention to the individual folder settings - thus my column is not displayed even if the particular folder is supposed to be showing it. I can select the column to be displayed in a folder but then if I browse to another and return the column settings have disappeared. If I tell every folder to display the column (Tools-Folder Options-View-Like Curent Folder) then the column wil be displayed in my file open dialog. However, I don't want this column to be displayed for every single folder in Explorer (I intend adding quite a few more columns which show information inappropriate to most folders). I know about the SHELLDEF_View and SysListView32 classes that implement the ListView control and can get to the interfaces below: IID_IShellFolder2 IID_IShellIcon IID_IPersistFolder3 IID_IShellIconOverlay None of these interfaces appear to have methods that allow me to manipulate the columns shown. I know I can manually add columns with ListView.InsertColumn() but then there is no way of populating the control properly (or is there?) and it seems to blow up if I try and change views. Does anyone know of a way of telling the control which columns to show, and to get it to remember which columns are to be shown. I know it can be done (Visual Studio.net has a dialog such as I need but it's quite possible that that uses it's own which just happens to be very similar to the standard dialog) but how? I really cannot believe that one of the most used dialog boxes in the known universe is such a pain in the ar** to use (well obviously I can but even so...). Do I have to implement my own IShellView + place it over the top of the standard one? This would be annoying due to having to implemnent the sorting, right click etc. Thanks for any help on this particularly matter because it's driving me up the wall : ) Rick Dangerous

    C / C++ / MFC csharp help visual-studio algorithms tools

  • Who has the lowest spec machine
    R Rick Dangerous

    Does the *original* IBM protable PC count? With its fixed screen 9" orange monitor, and fold down keyboard. We used to develope on it when our company first started. I remember upgrading to an 8Mhz 286 and thinking it was the bees knees. :-D We have the IBM here in the office somewhere. I think its in the anchient history section. Roger Bin Allen

    The Lounge question

  • Owner drawn button flicker hell
    R Rick Dangerous

    Whenever your window is being resized, your main window is receiving a WM_ERASEBKGND message. This message by default erases all the controls on the window which then need to be redrawn. This is bad for flicker. One was around this would be to use the following routine to only fill in that windows area by excluding the areas of the controls on the window so they are not erased:

    int dont_erase_indexes[] =
    {
    IDC_DPAS_LAMP,
    IDC_INSTRUMENT_TYPE,
    IDC_LABEL1,
    IDC_LABEL2,
    IDC_DESTINATION,
    IDC_CURRENT_STATUS,
    IDC_LOG,
    IDC_GRAPH,
    IDC_DOWNLOAD_STATUS,
    IDC_DOWNLOAD_PROGRESS,
    ID_AUTO_LOAD,
    IDC_UPLOAD_ASSAYS,
    IDC_AUTO_UPLOAD,
    IDC_BROWSE_FOR_FOLDER
    } ;

    BOOL CYourWindow::OnEraseBkgnd(CDC* pDC)
    {
    static int dont_erase_indexes[] =
    {// this is a list of the ID's of the controls on the parent window
    IDC_DPAS_LAMP,
    IDC_INSTRUMENT_TYPE,
    IDC_LABEL1,
    IDC_LABEL2,
    IDC_DESTINATION,
    IDC_CURRENT_STATUS,
    IDC_LOG,
    IDC_GRAPH,
    IDC_DOWNLOAD_STATUS,
    IDC_DOWNLOAD_PROGRESS,
    ID_AUTO_LOAD,
    IDC_UPLOAD_ASSAYS,
    IDC_AUTO_UPLOAD,
    IDC_BROWSE_FOR_FOLDER
    } ;
    CRect clip ;
    pDC->SaveDC() ;
    for (int i = 0 ; i < sizeof(dont_erase_indexes) / sizeof(int) ; i++)
    {
    GetDlgItem(dont_erase_indexes[i])->GetWindowRect(&clip); // get rect of the control
    ScreenToClient(&clip);
    pDC->ExcludeClipRect(&clip);
    }
    pDC->GetClipBox(&clip);
    pDC->FillSolidRect(clip, GetSysColor(COLOR_BTNFACE));
    pDC->RestoreDC(-1) ;
    return FALSE;
    }

    Hope this helps out Roger Bin Allen :-D

    C / C++ / MFC c++ com question

  • I am not your....
    R Rick Dangerous

    Michael Martin wrote: Where's Roger Allen when you need him He was on his first holiday this year (that is of 2001) Michael Martin wrote: pommy bastard that didn't bother turning up to get me a job like I asked a few weeks ago You can cast aspersions(sp?) about my job getting skills, but not my parentage! :-D Did I mention I was born in the USA, but consider myself British? <- Cat goes out among pidgeons Michael Martin wrote: these slackers like Tim Smith and Roger Allen How did you know I was a slacker? Michael Martin wrote: maybe even revoking membership Its hard to revoke membership for me, as I have lost my account until my hard disk is fully recovered (hopefully later today) (yay......) Also what would I do without CP? go back to codeguru? (Shudder) Roger Bin Allen Using his mates account until this afternoon (hopefully)

    The Back Room help question

  • Wet Lips
    R Rick Dangerous

    Michael Martin wrote: complete with wet shiny looking lips I think this may be because they need the lip gloss to be water resistant (otherwise it would come off when licking your lips). Because of the ingredients, this gives a shiny gloss like texture to the lips. This is me trying to be scientific. Of course it could be bullsh!t;) Michael Martin wrote: Anyone (besides John) out there agree or have a differing opinion? Maybe goats are attracted to it :-D Michael Martin wrote: Kylie Minogue She is a babe as you say. Roger Bin Allen

    The Lounge csharp question

  • What did Santa leave under your Christmas tree?
    R Rick Dangerous

    Nish [BusterBoy] wrote: He's hijiacking people's CP accounts for a long time now Does this make me a terrorist? But at least I am signing my name to them.... OK, my PC is busted. It should be back up by 3rd January. So if I am still doin it then, you have my authority to do ... nothing, erm nasty things? Roger Bin Allen Hijacking his mates account :-D

    The Lounge com data-structures question

  • Well, Now She's Done It
    R Rick Dangerous

    John Simmons / outlaw programmer wrote: I already know I'm going to copper the hull Don't you mean scupper the hull! :laugh: Roger Allen

    The Lounge python question

  • What did Santa leave under your Christmas tree?
    R Rick Dangerous

    Well.......don't snigger too much.... An answer phone :-D Some cufflinks :( A new shirt :( Some lynx aftershave :( (sigh) Some plastic chewy sweets. :-D For the first time, we hosted the christmas day meal/party/etc at my house instead of my parents. I think my mum liked not having to cook and wash up for a change! And we didn't get food poisoning. Paul Watson wrote: totally loose the plot in the Lounge Is this some kind of detective story? Or are we making a drama out of a web site? ;P Roger Allen Using his mates account.

    The Lounge com data-structures question

  • Reading
    R Rick Dangerous

    Konstantin Vasserman wrote: Do you guys/girls read a lot? I myself would normally get through one or two books a week, in the sci/fi or fantasy genre. I would recommend these authors for you: Peter F Hamilton (Excellent sci/fi) Robert Jordan (Fantasy) Harry Turtledove (alternate history - ww2 with alien invasion!) I am also slogging through ATL COM programming at work at the moment :( - not my usual kind of book Roger Allen Using his mates account as his PC is bust.

    The Lounge question learning

  • Words are fine but...
    R Rick Dangerous

    Unfortunately I got it all :eek: Roger Allen aka RIGamortis

    The Lounge com collaboration question

  • Words are fine but...
    R Rick Dangerous

    Paul Watson wrote: *hangs head in shame* Yes, you should be shamed! Do something about it now! Make a mess! Not that kind of mess! I mean a paper notes one! :laugh: Paul Watson wrote: a bad habit I have picked up form having lots of clients around Having clients (in my case visiting chemists etc) around does not cause my desk to be made tidy. The other day the company director confiscated my squeeze gun ammo until I cleaned up my desk (about 4 weeks ago). I have yet to get it back! :(( Bullying and coersion does not work on me....:-D Paul Watson wrote: I am a web developer I can just about get 1 line of HTML to work, let alone a web site. If you enjoy doing it, good for you. Paul Watson wrote: developers do not willingly subjugate themselves to any form of physical exertion Sorry to tell you, but I break the mold on this one. I am addicted to exercise! I go running at lunch times; I go circuit training; I run marathons*1; I swim*2; I even shower afterwards*3 Paul Watson wrote: a developer would play tug of war online with a sumo wrestler in an internet cafe in japan And he would win, by any means possible.... Roger Allen aka RIGamortis on his mates account. *1 I have only done one so far, and have been turned away from 4 as they were full :(( *2 Its more of a sink at times *3 Only sometimes :laugh:

    The Lounge com collaboration question

  • Words are fine but...
    R Rick Dangerous

    Michael P Butler wrote: Is Rick Dangerous a real name or taken from the classic Amiga game? It's my mates nickname (I am using his account - he's on holiday and my PC is bust). He got it from the amiga/ST game (I have personally completed RD2 with no lives lost! tis difficult) My normal nickname is RIGamortis, which originally can from arcade games putting in my initials (ye olde 3 letter names...). I extended it to RIGamortis when I used to write demo code in assembly on an Atari ST. Nothing of mine ever really went mainstream. The best things I did was a Repton 3 clone (the BBC boulderdash game). All BBC R3 maps sould work in it if you copied them across. You could also design all the characters used in the game. The sound samples I did for it sound rather poor and get really annoying after a while, but its a good tough game. It also had a level editor and was overscanned so that it could display the right amount of display area. If any body has an ST emulator, I could did out the .exe disks and you could have a play with it. I could possibly also supply the assembly code source for those who are interested. :cool: Roger Allen aka RIGamortis

    The Lounge com collaboration question

  • Words are fine but...
    R Rick Dangerous

    Having looked at the two pictures, I have come to the conclusion that you are *not* a bonifidi developer for the following reasons: 1. Your desk is too tidy. 2. There is a MAC on your desk. 3. You are doing something mildly related to programming. (i.e. this site) :-D There are some pictures of me on the net under the news section on our compant web site. They are of us at our annual tug of war competition in the village where we work, so if your interested take a look at http://www.sirius-analytical.com/news3.htm Roger Allen Using his mates account while his computer is repaired :((

    The Lounge com collaboration question

  • Reflections is back up :)
    R Rick Dangerous

    I did this again just now, and I had left over 1 mirror and 3 prisms Lots of tips with solution at end 1. Get the top right bulb first 2. get the bottom middle 3. get top left 4. get bottom left 5. place the doublle mirror 4 squares above the laser 6. place a mirror directly yo its right 7. place a prism 3 square above the mittor 8. reflect the through bulb 1 9, use mirror to reflect from edge 10. relect through bulb 2 11. releft from very top 12. reflect from edge 13 prism from top 14, mirror down 15, off double mirror 16, down onto last bulb Note : do it in the right order at points to avaoid hitting bombs

    WMWPMBWMW W W
    W1W W1 WLW1W
    MWLW1 P 1W W W
    WMW1W W1WB
    BWBW 1 W W
    M DM1 1 WM
    1 1WLWB W
    WLW W W W
    BWB W WM
    W W G

    W = wall M = mirror D = double mirror P = prism B = bomb L = light bulb 1 = 1 way route Roger Allen

    The Lounge

  • Help Wanted
    R Rick Dangerous

    Michael Martin wrote: You lame arse bastard I'd take offence, but I can't be bothered. ;P Michael Martin wrote: Get your arse on a plane Its too big to fit in a seat. Michael Martin wrote: fly down here to Australia Australia is real? I thought it was a myth. Michael Martin wrote: write me a résumé You saw how bad my spelling was in the first post! Michael Martin wrote: get me an interview I could get an interview for a job as a floor cleaner. Michael Martin wrote: attend it and get me a job I don't think I would pass the interview, being a limey pom. Michael Martin wrote: Godammit Should that not be : God dammit, you poms are so lazeee.....get of your arse and do some work....etc....you can go on verbatum at this point.:-D Make my day....insult me some more!* :cool: Roger Allen On his mates account *All insults taken on account, subject to status, repayable on 5 seconds notice, or how fast my net connection is, whichever is faster (i.e. 3 weeks)

    The Lounge csharp help question career

  • Help Wanted
    R Rick Dangerous

    I would, but I don't have any enthusiasm either. Roger Allen Using his mates account as his own computer failed catastophically (sp?) earlier this week and this is the first time he has been able to use the internet since last Friday. Hopefully the problem should be sorted once the HD recovery people have pulled all the data of my dead hard drive (small cost of arounf £1000 - £2500) Note for others: Make backups! I only lost 2 weeks work, but it could have been an awful lot worse........:eek:

    The Lounge csharp help question career

  • Passing SAFEARRAYS through COM events
    R Rick Dangerous

    Hi, there is no error generated as such. The problems I'm having centre around: 1. The IDL complaining that an interface doesn't support automation. 2. The interface being seeminly ok until I try to use it in a client. The client (i'm testing in VB) will try to implement the event handler and either not catch it or crash at the first line of code in the handler. Judging by other stuff i've seen on the net there seems to be a problem with passing SAFEARRAYS and VARIANTS through event interfaces.

    COM c++ com testing beta-testing question

  • Passing SAFEARRAYS through COM events
    R Rick Dangerous

    Hi, I'm using ATL and have written an event that passes a SAFEARRAY (of doubles) back to the client as one of its parameters In the IDL file I've declared this as: [id(2), helpstring("method SpoilValuesReadyEvent")] HRESULT TFASpoilsReadyEvent(SAFEARRAY(double)* a, double b, double c); producing: HRESULT Fire_TFASpoilsReadyEvent(SAFEARRAY * * a, DOUBLE b, DOUBLE c) etc... in the proxy file. I'm testing the code from a VB client. The client produces: Private Sub test_TFASpoilsReadyEvent(a() As Double, ByVal b As Double, ByVal c As Double) This all seems to be OK. However, when I fire the event, it is not caught by the client. Is there any reason for this apart from probable incompetence ? :((

    COM c++ com testing beta-testing 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