forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

%WB issues with %IB
Goto page 1, 2  Next
 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+
View previous topic :: View next topic  
Author Message
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Sun May 23, 2021 10:32 am    Post subject: %WB issues with %IB Reply with quote

I have been trying to use %WB for intelligent report but it seem to have an issue when used in conjunction with %IB. if i comment out the line with %IB the example works as expected using the %BT button. With the %IB line in place the example crashes immeadiately when the toolbar button is pressed. If the %bt button is pressed the %WB window opens but crashes with the same error message on close /move

" The instruction at address 100a67a4 attempted to read from location 00000000
100a62a1 constructed_button_procedure@16#70 [+0503]"


PROGRAM TEST
c ============
IMPLICIT NONE
INCLUDE <windows.ins>
INTEGER IWIN
INTEGER OPEN_WEB
EXTERNAL OPEN_WEB
IWIN = WINIO@('%CA@&', 'WB test')
IWIN = WINIO@('%ib[flat]&','tb_web',1,OPEN_WEB)
IWIN = WINIO@('%bx&',0.1d0)
IWIN = WINIO@('%^bt[wb_test]&', OPEN_WEB)
IWIN = WINIO@('%ff%3nl%cn%bt[OK]')
END

INTEGER FUNCTIONOPEN_WEB()
c =========================
IMPLICIT NONE
OPEN_WEB = 1
CALL SHOW_URL_WEB('Report', 'http://www.silverfrost.com')
END

SUBROUTINE SHOW_URL_WEB(CAPTION, TMPPATH)
c ========================
IMPLICIT NONE
INCLUDE <windows.ins>
CHARACTER*( * ) CAPTION, TMPPATH
INTEGER IWIN
IWIN = WINIO@('%CA@&', CAPTION)
IWIN = WINIO@('%80.35wb@&', TMPPATH)
IWIN = WINIO@('%ff%nl%cn%bt[OK]')
END
// resource wb_rec.rc
1 24 default.manifest
tb_web BITMAP "tb_htmlview.bmp"

bitmap file available if required
steve
Back to top
View user's profile Send private message
Kenneth_Smith



Joined: 18 May 2012
Posts: 506
Location: Hamilton, Lanarkshire, Scotland.

PostPosted: Sun May 23, 2021 12:13 pm    Post subject: Reply with quote

It's not much help, but I can confirm that I can replicate the problem as described by Steve..
Back to top
View user's profile Send private message Visit poster's website
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Sun May 23, 2021 1:51 pm    Post subject: Reply with quote

Thanks. At least it possibly eliminates any local setup issues (win XP). I have also tested on a Wn 10 (64) system which also fails FTN95 V8.73. steve
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7160
Location: Salford, UK

PostPosted: Mon May 24, 2021 9:22 am    Post subject: Reply with quote

Steve

When I first tested your sample I had the same experience but I started again and then I could not reproduce it.

The problem must relate to the resource script, maybe even some odd hidden characters.

Try to get the resource script to work first in some other context. Everything else is OK.
Back to top
View user's profile Send private message AIM Address
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Mon May 24, 2021 1:06 pm    Post subject: Reply with quote

Paul

i added iwin = winio@(%bm[tb_web]&',open_web) with the %wb comment out an it work as expected. un-commenting the %wb still cause a crash.

I doubt it the resource as Kenneths' test would have had to regenerate the script file (or copy and paste from the OP) and had to use a different bitmap

The application this example derived from has ~ 160 *.bmp & 130 *.ico files in the resource script (enhanced menus/%bb/ configurable toolbars etc.) which work as expected so i find it hard to suspect the resource file.

When it fails in Win Xp i get the standard trackback window. In Win 10 the example just freezes then stops

If you managed to reproduce the effect once i suspect it would be the interface to the MS internet engine that is being corrupted

regards

steve
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7160
Location: Salford, UK

PostPosted: Mon May 24, 2021 3:35 pm    Post subject: Reply with quote

Steve

There is a problem with %ib but I have not been able to indentify the cause.

%mb is a lot more stable in this context but there is still a problem. For a 32 bit application, the program will sometimes terninate when you close the web dialog. Here is your sample modified for %mb...
Code:
       WINAPP
c ============
       IMPLICIT NONE
       INCLUDE <windows.ins>
       INTEGER IWIN
       INTEGER,EXTERNAL::OPEN_WEB
       INTEGER,PARAMETER::N=1
       INTEGER bstyle(N),bID(N)
       bID    = (/0/)
       bstyle = TBSTYLE_BUTTON
       IWIN = WINIO@('%ca@&', 'WB test')
       IWIN = WINIO@('%^`*mb&', N, bID, bstyle, 'tb_web', OPEN_WEB)
       IWIN = WINIO@('%^bt[wb_test]&', OPEN_WEB)
       IWIN = WINIO@('%ff%3nl%cn%bt[OK]')
       END
       
       INTEGER FUNCTION OPEN_WEB()
c =========================
       IMPLICIT NONE
       CALL SHOW_URL_WEB('Report', 'http://www.silverfrost.com')
       OPEN_WEB = 2
       END

       SUBROUTINE SHOW_URL_WEB(CAPTION, TMPPATH)
c ========================
       IMPLICIT NONE
       INCLUDE <windows.ins>
       CHARACTER*( * ) CAPTION, TMPPATH
       INTEGER IWIN
       IWIN = WINIO@('%CA@&', CAPTION)
       IWIN = WINIO@('%80.35wb@&', TMPPATH)
       IWIN = WINIO@('%ff%nl%cn%bt[OK]')
       END
c ========================
       RESOURCES
       tb_web BITMAP "capture.bmp"
Back to top
View user's profile Send private message AIM Address
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Mon May 24, 2021 4:02 pm    Post subject: Reply with quote

Paul

thanks for the response.
I did have a quick look at %mb but it looked complicated especially as all my %ib toolbars are user configurable (multiples call to %ib to build up toolbar) and it was unclear if %mb would behave in similar way.

The 32 bit stability may also be a limiting issue.

i will play with you example to see if i can utilise it

steve
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7160
Location: Salford, UK

PostPosted: Tue May 25, 2021 8:30 am    Post subject: Reply with quote

Steve

I have located the fault and can now stop it from crashing. There is an outstanding issue (after use, the toolbar button remains depressed and becomes inactive. But I am more hopefull of a complete fix.
Back to top
View user's profile Send private message AIM Address
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7160
Location: Salford, UK

PostPosted: Tue May 25, 2021 9:47 am    Post subject: Reply with quote

This failure has now been fixed for the next release of ClearWin+.

The initial state of the toolbar button should be set to 4 in order to provide a button that toggles.
Back to top
View user's profile Send private message AIM Address
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Tue May 25, 2021 12:02 pm    Post subject: Reply with quote

Paul

Thanks for your efforts

steve
Back to top
View user's profile Send private message
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Tue Jun 08, 2021 8:43 am    Post subject: Reply with quote

Hi Paul

the %wb control is working great now. It even magically managed greying some %tb button i added for the wbGoforward/wbGoback callbacks.

Do you have any ideas on how i can send the %wb contents directly to a printer ('wbPrint' maybe?) i can copy the contents into Word for printing purposes but its a bit inelegant

The are still some stability issues if i add a %ib toolbar to the same window as the %wb. I need to investigate further to isolate the behaviour

thanks

steve
PS: a 'wbFind' would be a great use to the end user
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7160
Location: Salford, UK

PostPosted: Tue Jun 08, 2021 9:22 am    Post subject: Reply with quote

Steve

If you right click on the web page then you should get the option to print.

"Find" is more tricky. You would need to start up a browser for that.
Back to top
View user's profile Send private message AIM Address
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Tue Jun 08, 2021 10:10 am    Post subject: Reply with quote

HI Paul

Im not opening a web page. I use a text file which has been decorated with HTML code (<h2>,<b> , links etc.) to permit the end user to navigate long reports (1000+ lines) in a structured fashion. The right click just shows the %pm options

Currently the user can selected between a %eb or %wb output report. I was trying to duplicate some of the usability functions the %eb report

thanks

steve
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7160
Location: Salford, UK

PostPosted: Tue Jun 08, 2021 5:29 pm    Post subject: Reply with quote

Steve

If you are using %wb to display html code then I would expect that the default popup menu would provide an option to print. Suppying %pm will replace the default by your own menu.
Back to top
View user's profile Send private message AIM Address
steveDoyle



Joined: 04 Sep 2009
Posts: 103
Location: Manchester

PostPosted: Tue Jun 08, 2021 6:07 pm    Post subject: Reply with quote

Paul

thanks for the suggestion but i commented out the %pm and there was no default popup menu

Steve
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> ClearWin+ All times are GMT + 1 Hour
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group