I have been working on a vb Project for 2 weeks. But can't disable js alert. I'm using GeckoFX 33.0 (this) . There are Many discussion But none of them is alive for me. I tried a lot. Can anyone help me to solve this Problem please ?
Asked
Active
Viewed 797 times
1
-
could you post some code example and some workarounds you did? – Prashanth Benny Oct 08 '16 at 08:25
-
1ok Something like this ? If I load this in a HTML file it would give me a alert. How can I stop this ? – Taki Ahmad Elias Oct 08 '16 at 08:28
-
refer this link [here](http://stackoverflow.com/questions/29931050/disable-javascript-alerts-geckofx-c-sharp/29932722#29932722) – Prashanth Benny Oct 08 '16 at 08:42
-
This does not work anymore in geckofx-core 33.0 – Taki Ahmad Elias Oct 08 '16 at 08:45
-
check the upgraded version 45.... i am not sure weather it helps, since i have not used it. the link is [here](https://bitbucket.org/geckofx/geckofx-45.0/overview) you need to install it as a nuget – Prashanth Benny Oct 08 '16 at 08:51
-
Yes I got that. But v45 is for C#. I'm using vb :( – Taki Ahmad Elias Oct 08 '16 at 09:01
-
is it mandatory that you use version 33? probably version 29 has a fix right? – Prashanth Benny Oct 08 '16 at 09:05
-
Yes I think So. 33 is not mandatory. – Taki Ahmad Elias Oct 08 '16 at 09:08
-
you have the fix already :) – Prashanth Benny Oct 08 '16 at 09:11
-
Can you just overwrite the script with your own? `window.alert = function() {};`... It won't do anything as it's just empty... – Trevor Oct 08 '16 at 11:44
-
I did this But it did not work. – Taki Ahmad Elias Oct 08 '16 at 12:29
-
http://stackoverflow.com/a/28977359/361714 – Tom Oct 11 '16 at 20:15
1 Answers
0
please check out this answer
https://stackoverflow.com/a/43878928/2892378
It basically means you have to implement the the nsIPromptServcice2 and nsIPrompt interfaces, but do not provide any code inside the methods defined.