Admin Rights When Saving Bitmap ?

Add-in Express™ Support Service
That's what is more important than anything else

Admin Rights When Saving Bitmap ?
 
RIBEIRO David




Posts: 12
Joined: 2014-04-24
Hi,

I'm currently developping an IEAddon in C# for IE >= 10.

The IEAddon work like this :

1. If current site web is "www.XXXX.fr" -> add some embedded JS Library to HTML Page;
2. When all Libs are added -> C# call a JS Function to init some JS vars and adding some special button;
3. When user click on some special button -> JS trigger a C# function to do a SnapShot of the area parent of the special button;
4. The SnapShop (Bitmap) is saved to a location selected by user (with SaveFileDialog).

All are perfectly working.

But when I'm in Debug mode, when I save the jpeg in Desktop, Downloads or what another directory I don't see the file...
If I do another snapshot, in the SaveFileDialog I see the file...

I've tried to publish the Addon, the installation is perfect but same thing, file don't appear after saving, but when I retry to save, in the SaveFileDialog I see file.

To see the file on my Desktop for example after saving I have to run Internet Explorer in Admin Mode ...

Have you got an idea why ?
How I can change this ?

Plugin have to be installed in some non admin workstation.


I'm not sure what I write is perfectly clear :s sorry for my bad english.

I'm a C# beginner.

Softs used :
- VS 2013 Pro;
- Add-in Express Standard;
- WiX;
- Win 7 Pro up to date & IE 11.

Thanks in advance.

Here a little video exposing my problems : http://hevaweb.com/Video.m4v
You read it with VLC.

Thx
RIBEIRO David
Posted 24 Apr, 2014 08:33:24 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Hello David,

I suppose this is caused by Protected Mode; it is turned on in your IE. Running IE via "Run as administrator" effectively disables it. Please check the section Protected Mode in the PDF file in the folder {Add-in Express}\Docs on your development PC. You can download the most recent version of the Developer's Guide at http://www.add-in-express.com/downloads/documentation.php.


Andrei Smolin
Add-in Express Team Leader
Posted 24 Apr, 2014 10:20:35 Top
RIBEIRO David




Posts: 12
Joined: 2014-04-24
Hi,

Beautiful, perfect :)

Thanks for fast reply.

Just a question, How I can close/kill the Broker Process when the user close IE or when OnFinalize is triggered ?
Because sometimes when I close IE the broker process still running.

Thanks in advance.
RIBEIRO David
Posted 25 Apr, 2014 09:54:55 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
David,

This can be caused by your code. Could you please comment it out and check if the issue is reproducible?


Andrei Smolin
Add-in Express Team Leader
Posted 28 Apr, 2014 06:01:17 Top
RIBEIRO David




Posts: 12
Joined: 2014-04-24
Hi,

Thanks for fast reply.

It was a little buggy peace of code.

Thanks.


Last one question : Can I create a single "Setup installer" for IEAddon & IE Broker.
Or I have to create 2 differents installer, one for the IEAddon and another for IEBroker.

Thanks.
RIBEIRO David
Posted 29 Apr, 2014 10:43:55 Top
RIBEIRO David




Posts: 12
Joined: 2014-04-24
Hi,

Find it, I have to create a new Setup Project, and select the broker.


Thanks.
RIBEIRO David
Posted 30 Apr, 2014 01:44:25 Top
Andrei Smolin


Add-in Express team


Posts: 18825
Joined: 2006-05-11
Thank you for publishing the solution here!


Andrei Smolin
Add-in Express Team Leader
Posted 30 Apr, 2014 03:45:21 Top
RIBEIRO David




Posts: 12
Joined: 2014-04-24
Hi,

mmm I have trouble when I install a simple project in a clean install :
Detailed technical information follows:
---
Date and Time: 30/04/2014 02:03:38
Machine Name: IE10WIN7
IP Address: fe80::30f5:bd0f:8e55:81f0%13
Current User: IE10WIN7\IEUser

Application Domain: C:\Program Files\IETestAddon\
Assembly Codebase: file:///C:/Program Files/IETestAddon/AddinExpress.IE.DLL
Assembly Full Name: AddinExpress.IE, Version=9.0.6121.0, Culture=neutral, PublicKeyToken=4416dd98f0861965
Assembly Version: 9.0.6121.0

Exception Source:
Exception Type: AddinExpress.IE.ADXIEBrokerApplicationException
Exception Message: Unable to open broker pipe.
Exception Target Site: Object reference not set to an instance of an object.

---- Stack Trace ----



I've created a simple addon with juste the BrokerGuid set in the "InitializeComponent()" function of addon and a clean broker (All in C#).

I've published a fresh Installer with no prerequisites (because .net Framework 4.5 are manually installed).
Installation complete ok.

I start IE, I see the broker starting (in the Windows Task Manager) and after few secondes broker disapear and the add throw the error (pasted up).

Tested in a virtual machine picked-up from modern.ie (Win7 entreprise & IE 10).

Here a video : http://www.hevaweb.com/Video2.m4v

Thanks in advance.
RIBEIRO David
Posted 30 Apr, 2014 04:21:44 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi David,

Is the broker guid set in IEModule equal to the BROKER_GUID value in the App.config file of the broker project?
Posted 30 Apr, 2014 09:34:14 Top
RIBEIRO David




Posts: 12
Joined: 2014-04-24
Hi,

Yes, Copied from "App.config" in the Broker Project :
<add key="BROKER_GUID" value="{BB61627E-0CBE-444B-B159-C88B2AFDB3BF}"/>


And Pasted in the "InitializeComponent()" Function in my IEModule.cs like that :

//
// IEModule
//
this.HandleShortcuts = true;
this.LoadInMainProcess = false;
this.ModuleName = "IETestAddon";
this.BrokerGuid = "{BB61627E-0CBE-444B-B159-C88B2AFDB3BF}";
// AND TESTED WITH FOLLOW TOO
//this.BrokerGuid = "BB61627E-0CBE-444B-B159-C88B2AFDB3BF";


Where my Sample Test Project : http://www.hevaweb.com/IETestAddon.zip

Thanks
RIBEIRO David
Posted 30 Apr, 2014 09:39:37 Top