|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
Hi I got a script with some dialogs running for a long time now and the dialogs are loading an iconfile, which is in the scriptdir in the mirc Dir and it's a portable installation, so the $mircdir is the mIRC-Dir itself.
But since 7.64 it says 'error loading icon'. If I test in mirc to reach it with "/run scriptdir/icon.file' it opens. so mIRC should find it there. But it doesn't Was anything changed there?
"icon d-tool\logo\dtool.ico, 0" is the line...at the start of the dialog and it always worked
|
|
|
|
Joined: Jan 2004
Posts: 2,127
Hoopy frood
|
Hoopy frood
Joined: Jan 2004
Posts: 2,127 |
Is $scriptdir the same as d-tool\logo\ ? Using $scriptdir within a script is the folder where that script file is located, but using $scriptdir from the channel editbox is the same as using $mircdir, so it's not clear where you were testing. Your post lists a relative path, which should work as long as $isfile(d-tool\logo\dtool.ico) is $true, but that's not the same as $scriptdir which always begins with the driveletter:\full-path My tests with c:\windows\system32\shell32.dll shows that this is still working the same.
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
yes it is, i'm sorry I wrote scriptdir and you could think I've meant the $scriptdir identifier. I was just too lazy to write d-tool\logo\ , in the script is the path d-tool\logo\d-tool.ico like I said in the last sentence
/run d-tool\logo\dtool.ico in a chanwindow works. this tells me that there should be no problem finding the iconfile. so for me this should go to the bug section maybe
Last edited by del; 20/12/20 10:39 PM.
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
Thanks for answer I'll try...even if it doesn't make sense cause mIRC was able to open this file for many years... could you maybe focus more on mIRC? this should go to the bug section I think... //edit: * /dialog: 'dtool-main' error loading icon '' (line 1221, d-tool.mrc)
Last edited by del; 21/12/20 12:19 PM.
|
|
|
|
Joined: Dec 2002
Posts: 5,477
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 5,477 |
Thanks for your bug report. I tried to reproduce this in a custom dialog with several different icons and they all loaded and displayed without any issues.
Which version of mIRC were you using before upgrading?
Do you have any other .ico files you can test? If you replace dtool.ico with a different icon, does it work?
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
Hi Khaled Thanks for your reply. Yes I tried the icon maroon posted and it was the same error. Before I used mIRC 7.62 and several other versions, down to mIRC 6.16 and it worked always. I added the icons some years ago and never had problems with it. In my first posting I wrote the script line, could that be the problem? Was anything changed there? I looked in the changes of 7.64 and didn't spot anything that could have to do with it
Last edited by del; 21/12/20 06:38 PM.
|
|
|
|
Joined: Jun 2009
Posts: 96
Babel fish
|
Babel fish
Joined: Jun 2009
Posts: 96 |
I'll try...even if it doesn't make sense cause mIRC was able to open this file for many years...
maybe not direct related... dunno how mirc handles icons, but i do know that 6.0x and above all had problems loading icons (from ICL library tho), that were 16bit mirc would give such error, so i had to convert ICL manually to 32bit, and then it was alright again doesn't have to be directly related ... but who knows...
|
|
|
|
Joined: Jan 2004
Posts: 2,127
Hoopy frood
|
Hoopy frood
Joined: Jan 2004
Posts: 2,127 |
My post *was* focusing on mirc. Often, 99% of the fix is identifying a way to make the bug happen, and so far you're the only one finding it. I was trying to eliminate other possibilities by having you try other icons, including the vc.ico which i am using without fail.
So far you're having a bug that nobody else has, and we now know that you also fail with vc.ico which doesn't fail for me, and probably won't for Khaled. So it's hard for someone else to fix a bug that they can't encounter for themselves. Have you tried with the shell32.dll i mentioned, which came with windows itself? Check my url again, and i included a couple of variants of controls.icl that came with DCX. the 2007 version doesn't seem to work, so might be caused by the issue that vinifera mentioned, but the 2014 version of controls.icl works fine.
The more info we know about the problem, the better chance of isolating the cause. So far we know you're having trouble with a .ico and a .icl format. You have trouble with vc.ico that I don't have, but you haven't posted your .icl file to see if we also have trouble with it. If you can't post it, you can come to freenode and dcc it to me or someone. Knowing whether you have trouble with shell32.dll that comes with windows itself is useful, as well as knowing whether you have problems with controls.icl, which is surely something that other 764 users are using.
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
hi maroon. i'll try later out and try to understand what you wrote, and i can understand not being able to reproduce is a problem. Yesterday I commented the line out which loads the iconfile and the error stays. I think I first have to figure out where the problem exactly is @vinifera thanks, mIRC loaded this file for years. so if mirc had a problem, it would always have it right? so that can't be the problem in my opinion //EDIT ok...it was not the line I thought it was... i'm sorry . Maybe it's not a bug and the Script section was right...it's not the Icon in the Titlebar of the Dialog, it's an "icon", in fact a png Image which is loaded in the Dialog icon 7, 7 3 100 49, %dtlogo, 0 noborder and the %dtlogo Variable was not set right anymore, normally it's setup in the initiation commands and it checks the $os Identifier and then chooses the right Directory with the right Image for the System, which have slightly different Backgrounds so that they fit with the current System Background from Windows. So I have to figure out why the Variable is not set right anymore if ( $os == xp ) { set %dtlogo $scriptdir $+ logo\logo-xp.png | set %dtlogosave $scriptdir $+ logo\logo-xp.png } | if ( 2003 isin $os ) || ( 2008 isin $os ) { set %dtlogo $scriptdir $+ logo\logo-2003.png | set %dtlogosave $scriptdir $+ logo\logo-2003.png } | if ( $os == 7 ) || ( $os == vista ) || ( 2016 isin $os ) { set %dtlogo $scriptdir $+ logo\logo-win7.png | set %dtlogosave $scriptdir $+ logo\logo-win7.png } | mkdir d-tool\inis //EDIT Ok...the first Setup is not executed anymore...that's the Problem. Which is strange..cause it depends on nothing else than a yes/no Inputdialog if ( $input(Initiate first Setup?,yv,First Setup) == $yes ) { ... } after this, nothing happens. Was there something changed in the behaviour? I've tested, up to mIRC 7.63 I was able to set the script up right. Initiation commands worked. mh Was something changed in the $input Identifier between mIRC 7.63 and 7.64?
Last edited by del; 22/12/20 01:14 PM.
|
|
|
|
Joined: Dec 2002
Posts: 5,477
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 5,477 |
Ok...the first Setup is not executed anymore...that's the Problem. Which is strange..cause it depends on nothing else than a yes/no Inputdialog Is the part inside the if statement being executed? You can add an /echo inside it to see if it is. The easiest way to debug a script, to track down the cause of an issue, is to add /echo commands to your script in several locations. This will allow you to see which parts of the script are executing and the contents of specific %variables at that point. This should help you narrow down the cause of the issue you are seeing.
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
I exactly added a "echo -a hoho" to it at the start, it's not executed with no reason. cool to hear that from you, the master, cause I always use echos for testing purposes and it was my own idea once, yeah :P
Last edited by del; 22/12/20 01:34 PM.
|
|
|
|
Joined: Dec 2002
Posts: 5,477
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 5,477 |
While editing the script, if you press Control+H to check the script for invalid brackets, do you see an error message?
You may need to do this in other loaded scripts as well, in your aliases and remote sections. If any of them contain invalid bracket combinations, they could affect other scripts.
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
no there is no error message, I pressed Control+h in all scripts which have to do with it, which are two. Where should the error message be, in a Status window? I can't see anything. That should be alright. Other scripts aren't loaded, only these two. Otherwise it's plain mIRC //EDit: Ok...I just wrote a simple script alias testo {
if ( $input(lulu,yv,lala) == $yes ) { echo -a hello }
} doesn't work. alias testo {
if ( $input(lulu,y,lala) == $true ) { echo -a hello }
} works! So for me the Problem is solved and mIRC changed it's behaviour about this
|
|
|
|
Joined: Dec 2002
Posts: 5,477
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 5,477 |
Both of these scripts work fine for me.
Can you paste this command into the status window and post your results:
//echo -a $os $version $beta $md5($mircexe,2) $file($mircexe).sig $alias(0) $script(0) $dll(0) $com(0)
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
2016 7.64 43b55cd52fb11668f4ad7ec89a5174e1 ok 1 3 0 0
ok strange...I just installed and registered again and it works. first there was a fail
|
|
|
|
Joined: Dec 2002
Posts: 5,477
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 5,477 |
When you say "first there was a fail", do you mean that the scripts didn't work the first time? But then did work? Or are you referring to something else?
Last edited by Khaled; 22/12/20 03:06 PM.
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
right, first the scripts didn't work and I got a fail when I executed the command you pasted
|
|
|
|
Joined: Dec 2002
Posts: 5,477
Hoopy frood
|
Hoopy frood
Joined: Dec 2002
Posts: 5,477 |
Odd. Are you using anti-virus software? Which one?
If you install a clean copy of mIRC to a new, empty folder in the Documents folder, using the "Portable" option in the installer, and then use the /echo command I sent you, do you see the same issue?
|
|
|
|
Joined: Dec 2020
Posts: 13
Pikka bird
|
OP
Pikka bird
Joined: Dec 2020
Posts: 13 |
no then it works. That's what I did 2 posts before and everything was fine. No, I'm only using Windows Defender on that machine
Last edited by del; 22/12/20 04:14 PM.
|
|
|
|
|