Announcement

Collapse
No announcement yet.

Can't add dialog icon using PbForms

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Mike Doty
    replied
    don't click apply in powerforms, just ok after adding icon. http://www.powerbasic.com/support/pb...ead.php?t=9630

    r&d, hope you read this.

    ------------------

    Leave a comment:


  • Mike Doty
    replied
    Thank, Kerry. I know it worked before.

    ------------------

    Leave a comment:


  • Kerry Goodin
    replied
    PBforms will not generate the ICON information for me also.

    Had to add it to the define line
    add the RCdata line and
    then in the .BAS file add
    the constant and the DIALOG SET ICON statement
    all manually

    If I changed the dialog in PBform 1.5 it gets rid of the
    Icon as well



    ------------------

    Leave a comment:


  • Mike Doty
    replied
    Re-installed PBforms and didn't correct.
    Wonder if a corrupted resource compiler or bad path?
    Just added an icon to a blank dialog and the icon doesn't
    appear in the testing window or generate any code.
    Used one of the icons supplied with Power Basic to
    rule out the icon itself. Are there setup files that
    can be wiped out and recreated in PbWin80 and Power Forms?



    ------------------

    Leave a comment:


  • Richard Angell
    replied
    Mike,

    I just tried a blank dialog with an icon. No problems, The code is generated.
    Code:
        DIALOG NEW hParent, "test", 70, 70, 400, 246, %WS_POPUP OR %WS_BORDER OR _
            %WS_DLGFRAME OR %WS_CAPTION OR %WS_SYSMENU OR %WS_CLIPSIBLINGS OR _
            %WS_VISIBLE OR %DS_MODALFRAME OR %DS_3DLOOK OR %DS_NOFAILCREATE OR _
            %DS_SETFONT, %WS_EX_CONTROLPARENT OR %WS_EX_LEFT OR _
            %WS_EX_LTRREADING OR %WS_EX_RIGHTSCROLLBAR, TO hDlg
        DIALOG  SET ICON hDlg, "#" + FORMAT$(%IDR_IMGFILE1)
    However, as you will note PB-Forms is also generating the resource file and copying the selected icon there.
    Code:
        //#PBForms Begin RCData
        IDR_IMGFILE1    ICON   DISCARDABLE "C:\\PBWin80\\All_Projects\\Project101\\pdv_program_icon.ico"
        //#PBForms End RCData
    I'd suggest looking at the .rc and making sure the icon in that path is still there and is still valid. This does not sound like a PB/Forms issue, but is because of some other anomalie during development that is causing the icon not to be loaded.

    ------------------
    Rick Angell

    [This message has been edited by Richard Angell (edited September 21, 2005).]

    Leave a comment:


  • Adam J. Drake
    replied
    If you want to set an icon for an app, add it into a resource and send %WM_SETICON to your dialog on dialog startup either in the dialog show procedure or under %WM_INITDIALOG in the callback.

    If you'll search the forum on 'WM_SETICON' it will return some good code samples...

    ------------------

    Leave a comment:


  • Mike Doty
    started a topic Can't add dialog icon using PbForms

    Can't add dialog icon using PbForms

    Using the latest version of PBForms and PBWin and for some
    reason no code is generated to create the dialog icon.
    When selecting the icon it displays correctly, but not
    in the compiled program or when testing.
    Is there a certain style or option that needs to be set?

    ------------------
Working...
X