Answered
InDesign SDK - how to get link's properties from insertLabel?
Hi everyone,
On INDD server, I am using insertLabel method to save my custom data
var links = document.links;
var link = links[0];
link.insertLabel("AAA", "Test1");
link.insertLabel("BBB", "Test");
When exporting, I got the result as expected
<Rectangle Self="ue9" ContentType="GraphicType">
<TextWrapPreference Inverse="false" ApplyToMasterPageOnly="false" TextWrapSide="BothSides" TextWrapMode="None">
...
</ObjectExportOption>
<Image Self="u143" Space="$ID/#Links_RGB" ActualPpi="72 72">
<Properties>
...
</Properties>
<TextWrapPreference Inverse="false" ApplyToMasterPageOnly="false" TextWrapSide="BothSides" TextWrapMode="None">
...
<Link Self="ue8" AssetURL="$ID/" AssetID="$ID/" RenditionData="Actual" LinkResourceURI="file:D:/AAA.jpg" LinkClassID="35906" LinkClientID="257" LinkResourceSize="0~1e97c">
<Properties>
<Label>
<KeyValuePair Key="AAA" Value="Test1" />
<KeyValuePair Key="BBB" Value="Test2" />
</Label>
</Properties>
</Link>
<ClippingPathSettings ClippingType="None" InvertPath="false" IncludeInsideEdges="false" />
<ImageIOPreference ApplyPhotoshopClippingPath="true" />
</Image>
</Rectangle>
Now, comes to the SDK with cpp code (I don't have much expierence and knowlege...)
I have tried many different ways but couldn't get these properties
How should I do here?
PMRsrcID MyCustomLinkProvider::GetUpdatedIconForLink(const ILink* link, const ILinkResource* linkResource) const {
// How to get these properties?
}
Thanks very much !
