| |
|
|
| Webseitenaufruf via Double-click on Links in Multiedits
CompileMarkSeparation {$Crq}
Declare Medit&,B#,Lasturl$,Tx$,Dlg&
Dim B#,255
Dlg&:=Createdialog(%Desktop,"Multiedit-Linkz",10,10,width(%desktop)-20,height(%desktop-50))
Tx$:="XProfan: https://www.xprofan.de"+Chr$(13)+Chr$(10)+"Community: https://profanforum.de.vu"
Medit& := Createmultiedit(Dlg&,Tx$,10,10,width(dlg&)-20,height(dlg&)-20)
setfocus(medit&)
Usermessages 16
Whilenot %Umessage==16
Getmessage
If %Lastmessage==515
Sendmessage(Medit&,176,B#,0)//curpos
Lasturl$:=Parseurl( Multiedittosingleline(Medit&),Long(B#,0) )
If Len(Lasturl$)
Shellexec(Lasturl$,"open",3)
Endif
Endif
Wend
Dispose B#
Destroywindow (Dlg&)
End
Proc Parseurl
Parameters S$,P&
S$:=Trim$(Del$(S$,1,P&-1))
If Len(S$)
If Instr(" ",S$)
S$:=Substr$(S$,1," ")
Endif
If Len(S$)
If Upper$(Mid$(S$,1,5))=="HTTP:"
If Instr("/",S$)
Ifnot Instr(".",S$)
S$:=""
Endif
Else
S$:=""
Endif
Endif
Endif
Endif
Return S$
Endproc
Proc Multiedittosingleline
Parameters Hdl&
Declare I&,S$
For I&:=1 To Getlinecount(Hdl&) Do begin
S$:=S$+Getline$(Hdl&,I&-1)+" "
end
Return Trim$(S$)
Endproc
//hope helps, iF
|
|
|
| |
|
|
|
Peter Mallow | XPSE streikt!
make I what wrong, or Why says XPSE, that Error present are? |
|
|
| WinXP Pro SP2, XProfan 9 + XPSE AMD Athlon 64 X2 3800 | 10/06/05 ▲ |
|
|
|
|
| certainly because the Source already something older is as the neuste XPSE - I schaus me on! |
|
|
| |
|
|
|
| so - functions again. The code is revised.
there XPSE has but very viewed what it not fit!
salvo. |
|
|
| |
|
|