Border editing dropdownlist (toolbar property of an annotation)

PDF-XChange Editor SDK for Developers

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
Post Reply
Audros
User
Posts: 77
Joined: Fri Jun 08, 2018 1:39 pm

Border editing dropdownlist (toolbar property of an annotation)

Post by Audros »

Hello,
Please we have a question about the border editing dropdownlist (toolbar property of an annotation), we could customize it so that it only displays the first 4 elements, but we could'nt find how to make the dropdownlist entry box read-only.
Can you help us? you find here the source code we used:


IUIX_CmdItem cmdBw = frm.cmbari.FindFirstItemByCmdName("cmd.borderWidth");
if ((cmdBw != null) && (cmdBw.Cmd != null))
{
IntPtr outPtr;
PDFXEdit.IUIX_Combo ctl = null;
cmdBw.Ctl.QueryImpl(typeof(PDFXEdit.IUIX_Combo).GUID, null, out outPtr);
ctl = (PDFXEdit.IUIX_Combo)System.Runtime.InteropServices.Marshal.GetObjectForIUnknown(outPtr);
ctl.CueText = "Simple";
if (ctl.Count - 1 > 4)//27/06
{
List<int> lI = new List<int>();
for (int i = ctl.Count - 1; i > 4; i--)
{
if (i == 5)
{//lI.Add(0);
//((PDFXEdit.IUIX_Combo)ctl).RemoveItem(0);
lI.Add(i);
lI.Add(0);
i--;
break;
}
lI.Add(i);
// ((PDFXEdit.IUIX_Combo)ctl).RemoveItem(i);
}

for (int j = 0; j < lI.Count; j++)
{
((PDFXEdit.IUIX_Combo)ctl).RemoveItem(lI[j]);
}

}
}

Best regards
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17824
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by Tracker Supp-Stefan »

Hello Audros,

Are you using the Editor SDK?
As you've posted in the end user section of the forums, and our devs do not monitor or reply to topics here.
So please let us know and we will move it in the correct forum so that it can be properly answered!

Regards,
Stefan
Audros
User
Posts: 77
Joined: Fri Jun 08, 2018 1:39 pm

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by Audros »

Hello Sir,
Yes we are using PDF Editor Sdk, thank you , and we are still waiting for your answer.

Best Regards
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by TrackerSupp-Daniel »

Hello Audros,
I apologize but as you have been told before, our developers try to answer at least once each day, thus please be patient, you will receive aid in time. Ensuring you post in the correct forum will see you with a response more rapidly. As neither myself, nor Stefan are developers ourselves we are unable to assist directly.

I have moved this topic to the appropriate Editor SDK forums for you, in the future, please ensure you post any Editor SDK questions here to ensure that our support developers can assist you directly.
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by Sasha - Tracker Dev Team »

Hello Audros,

You will have to get the IUIX_Edit https://sdkhelp.pdf-xchange.com/vi ... Combo_Edit and then set the IUIX_Edit::ReadOnly property to true.

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Audros
User
Posts: 77
Joined: Fri Jun 08, 2018 1:39 pm

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by Audros »

Hello,
thanks, but i tried this and its generate exception:
the code is:

ctl = (PDFXEdit.IUIX_Combo)System.Runtime.InteropServices.Marshal.GetObjectForIUnknown(outPtr);
((IUIX_Edit)ctl.Edit).ReadOnly = true;

i placed it in OnEventMonitor function
Best Regards.
Sasha - Tracker Dev Team
User
Posts: 5522
Joined: Fri Nov 21, 2014 8:27 am
Contact:

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by Sasha - Tracker Dev Team »

Hello Audros,

Can you please write the casts in the separate lines with creating of variables, try again and point out the line of code with the exception again

Cheers,
Alex
Subscribe at:
https://www.youtube.com/channel/UC-TwAMNi1haxJ1FX3LvB4CQ
Audros
User
Posts: 77
Joined: Fri Jun 08, 2018 1:39 pm

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by Audros »

Hello,
Thanks a lot, it's Ok.
Best Regards
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17824
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: Border editing dropdownlist (toolbar property of an annotation)

Post by Tracker Supp-Stefan »

Glad to hear that Audros!

Cheers,
Stefan
Post Reply