Silverfrost Forums

Welcome to our forums

drop down combos crashing in Windows 8.1

18 Feb 2014 12:16 #13727

Since moving our application over to Windows 8(8.0 or latest updates for 8.1) one of our particularly large dialog screens containing many CWP controls, itself works fine.

BUT, when attempting to build the next - very small - dialog, our app crashes. And consistently so.

Running on all Windows o/s up until W8 has caused no problem.

Does anyone have any ideas ?

Thanks

18 Feb 2014 1:08 #13728

I would need to be able to reproduce the crash on my own machine.

19 Feb 2014 6:18 #13731

Is it the property sheet where it crashes? Does the code crash when debugged or just called via SDBG?

19 Feb 2014 2:23 #13735

Our dialog is very complex, with many consecutive %ob[no_border] and many callbacks to grey/ungrey dialog items, but no property sheets : we have kept away from these !

I am still whittling the code down, but the next dialog still crashes when being built after having previously clicked on a drop-down list item.

19 Feb 2014 4:41 #13736

Is there a trace back of any kind?

19 Feb 2014 4:50 #13737

Sorry, Paul, immediately '< app name > has stopped working'.

As best as I can determine, callbacks on the clicking of the %ls list item alter the greying of the other data items on the dialog.

[ The grey variables are INT*4 and in COMMON and the callback function closes setting itself to 1 ]

19 Feb 2014 5:15 #13738

I believe the problem is indeed the fact that callbacks are being used on the %ls list items. I have not been able to crash W8.1 yet, whereas with the callbacks a crash was immediate.

I shall attempt to get a test example.

20 Feb 2014 10:20 (Edited: 20 Feb 2014 1:21) #13742

FTN95 code follows. If the WINIO@ statements within the Options box are seperated or if the %dy control not used then this test case may be seen to work okay.

C
      IMPLICIT REAL*8 (A-H, O-Z)
      IMPLICIT INTEGER*2 (J)
C
      INCLUDE <WINDOWS.INS>
C
      EXTERNAL ISCRN1, ISCRN2
C
      COMMON / VALUES / IVAL, INDLEV, INDGR1, INDGR2
C
      IVAL = 10      
      INDLEV = 1
      INDGR1 = 1
      I = MNFUNC()
C
      I = WINIO@('Step 1 : select Screen 1&')
      I = WINIO@('%ffStep 2 : click into several drop down lists&')
      I = WINIO@('%ffStep 3 : return here and select Screen 2&')
      I = WINIO@('%ff %ffIn Windows 8 the test will crash&')
      I = WINIO@('%ff %ff&')
      I = WINIO@('Screen : %3^bt[1]&', ISCRN1)
      I = WINIO@('%ff %ff&')
      I = WINIO@('Screen : %3^bt[2]', ISCRN2)
C
      STOP
      END

      INTEGER FUNCTION ISCRN1()	
C
      IMPLICIT REAL*8 (A-H, O-Z)
      IMPLICIT INTEGER*2 (J)
C
      EXTERNAL MNFUNC
C
      INCLUDE <WINDOWS.INS>
C
      CHARACTER CHLIST1(4)*10, CHLIST2(4)*10, CHLIST3(4)*10,
     *          CHLIST4(4)*10, CHLIST5(4)*10, CHLIST6(4)*10
C
      COMMON / VALUES / IVAL, INDLEV, INDGR1, INDGR2
C
      DATA NOSLIST1,ILIST1 / 4, 1 /
      DATA CHLIST1 / 'Off', 'Apples', 'Oranges', 'All' /
C
      DATA NOSLIST2,ILIST2 / 4, 1 /
      DATA CHLIST2 / 'Off', 'VW', 'Ford', 'All' /
C
      DATA NOSLIST3,ILIST3 / 4, 1 /
      DATA CHLIST3 / 'Off', 'AA', 'RAC', 'All' /
C
      DATA NOSLIST4,ILIST4 / 4, 1 /
      DATA CHLIST4 / 'Off', 'A roads', 'B roads', 'All' /
C
      DATA NOSLIST5,ILIST5 / 4, 1 /
      DATA CHLIST5 / 'Off', 'Stone', 'Paper', 'All' /
C
      DATA NOSLIST6,ILIST6 / 4, 1 /
      DATA CHLIST6 / 'Off', 'Sky', 'Land', 'All' /
C
      DY = 0.75D0
C
      I = WINIO@('%sy[3D_thin,thin_border]&')
      I = WINIO@('%ww[no_maxminbox]&')
      I = WINIO@('%bg[btnface]&')
      I = WINIO@('%fd&')
      I = WINIO@('%ca[Screen 1]&')
      I = WINIO@('%`cn&')
C
      I = WINIO@('%ob[named_l][Options]&')
      I = WINIO@('%dyChoice 1 :%ta%dy%`^12.4ls&', 
     *           DY, -0.75D0, CHLIST1, NOSLIST1, ILIST1, MNFUNC)
      I = WINIO@('%ff %ff%dyChoice 2 :%ta%dy%`^12.4ls&', 
     *           DY, -0.75D0, CHLIST2, NOSLIST2, ILIST2, MNFUNC)
      I = WINIO@('%ff %ff%dyChoice 3 :%ta%dy%`^12.4ls&', 
     *           DY, -0.75D0, CHLIST3, NOSLIST3, ILIST3, MNFUNC)
      I = WINIO@('%ff %ff%dyChoice 4 :%ta%dy%`^12.4ls&', 
     *           DY, -0.75D0, CHLIST4, NOSLIST4, ILIST4, MNFUNC)
      I = WINIO@('%ff %ff%dyChoice 5 :%ta%dy%`^12.4ls&', 
     *           DY, -0.75D0, CHLIST5, NOSLIST5, ILIST5, MNFUNC)
      I = WINIO@('%ff %ff%dyChoice 6 :%ta%dy%`^12.4ls&', 
     *           DY, -0.75D0, CHLIST6, NOSLIST6, ILIST6, MNFUNC)
      I = WINIO@('%cb&')
C
      I = WINIO@('%ff %ff%ob[no_border]&')
      I = WINIO@('%`~rb[Variable]&', INDLEV, INDGR1)
      I = WINIO@('%~rd&', IVAL, INDGR21)
      I = WINIO@('%cb&')
C
      I = WINIO@('%if%ff %ff %ff%6bt[OK]')
C
      ISCRN1 = 1
C
      RETURN
      END
20 Feb 2014 11:01 #13743

Remaining code :

      INTEGER FUNCTION ISCRN2()
C
      IMPLICIT REAL*8 (A-H, O-Z)
      IMPLICIT INTEGER*2 (J)
C
C
      I = WINIO@('%sy[3D_thin,thin_border]&')
      I = WINIO@('%ww[no_maxminbox]&')
      I = WINIO@('%bg[btnface]&')
      I = WINIO@('%fd&')
      I = WINIO@('%ca[Screen 2]&')
      I = WINIO@('%`cn&')
C
      I = WINIO@('Second screen&') 
C
      I = WINIO@('%if%ff %ff %ff%6bt[OK]')
C
      ISCRN2 = 1
C
      RETURN
      END


      INTEGER FUNCTION MNFUNC()
C
      IMPLICIT REAL*8 (A-H, O-Z)
      IMPLICIT INTEGER*2 (J)
C
      COMMON / VALUES / IVAL, INDLEV, INDGR1, INDGR2
C
      INDGR1 = 1 - INDGR1
      INDGR2 = INDLEV * INDGR1
C
      MNFUNC = 1
C
      RETURN
      END

The most sure way to not crash is to not have the callbacks in place. Somehow, breaking the WINIO statements up or not including the %dy only delays a crash.

Hope this helps, Paul

20 Feb 2014 5:31 #13745

For your info, Paul :

Seeing as the 6 example %`ls are all different lists, I have attempted to use 6 different callbacks. Crashes still occur.

I also attempted to remove the %cb surrounding the list boxes. Crashes still occur.

Is the problem CWP or Windows API ?

21 Feb 2014 8:33 #13746

I will take a look at this shortly. At the moment I have not idea what might be going wrong.

21 Feb 2014 11:17 #13747

Paul, I have just experimented using the callback return value of 2 and using window_update@. I have yet to crash my app. This may be a stop gap at the moment.

21 Feb 2014 2:02 #13748

A return value of 2 is preferred unless it means the screen is not being refreshed.

21 Feb 2014 2:44 #13749

A return value of 2 is preferred unless it means the screen is not being refreshed.

Paul,

This is not a stated requirement in the literature, as far as I know.

We have loads of software that uses callback return values of 1.

Do you intend to identify the problem, please ? Thanks

21 Feb 2014 8:50 #13751

Steve: Does not crash in my Windows 8.1 Paul: Do all callbacks have generally return 2 ? I used 1 so far with my 1000s of callbacks

24 Feb 2014 10:20 #13753

I have also tried you combo example in my surface pro under windows 8.1.

It works fine with the mouse or touch pad input but crashes when trying to select an item in the combo lists with the stylus or touch pad. Same message

<app name> has stopped working.

I re-ran the program in debug mode in visual studio. When the program crashes the stack frame show the message.

 ninput.dll +0088ee.

This is exactly the same message I get with my own reported problem trying to select a simple menu item for the popup menu list.

Buttons and top level menu items all work ok.

Please login to reply.