photools.com Community

IMatch Discussion Boards => General Discussion and Questions => Topic started by: PandDLong on August 09, 2021, 07:24:09 PM

Title: Access Global Attributes as a Variable?
Post by: PandDLong on August 09, 2021, 07:24:09 PM

Are Global Attributes directly accessible as a variable?  ie. without being referenced from a file attribute.


As context, I do use a couple of user defined variables to retain some "global data".   I am looking to have some global data that can behave the same as a "repeatable tag" and use the filter and count functional arguments.   


Michael
Title: Re: Access Global Attributes as a Variable?
Post by: Mario on August 09, 2021, 07:35:09 PM
If I can bother you to just look it up in the variables help: Attribute Variables (https://www.photools.com/help/imatch/#var_basics.htm?dl=h-173) and there especially the section for Global Sets (https://www.photools.com/help/imatch/#var_basics.htm?dl=h-176)

How did I find this?
I opened the variables help topic and then did a <Ctrl>+<F> in the browser to search for global. It's the second match on the page  ;)
Title: Re: Access Global Attributes as a Variable?
Post by: PandDLong on August 09, 2021, 08:37:12 PM

I have read that section and all other references to Attributes I could find in the Help - I also did a search of this forum for Global Attributes topics and read through at least a dozen.

I think it is one of those situations that isn't described how to do it but the documentation doesn't say it is can't be done either.   I can assume it isn't possible but I wanted to check that my assumption is right. 


All of the material I read uses a per-File attribute that is set to reference a global attribute, I could not find any examples of just directly accessing a global attribute set as a variable.

I can create a per-file attribute set to reference my global attribute sets and then I can follow the examples.  Just checking on options.


Thanks for your prompt response.

Michael
Title: Re: Access Global Attributes as a Variable?
Post by: Mario on August 09, 2021, 09:15:20 PM
There are no variables which allow you to query global attribute sets. They were never needed, never requested. I don't see any use-case for such a thing.
How would selection or enumeration work. For what purpose...?

If you need functionality like this, I recommend looking into writing an app for IMatch: https://www.photools.com/dev-center/doc/imatch/
Title: Re: Access Global Attributes as a Variable?
Post by: sinus on August 09, 2021, 09:42:54 PM
Michael

Good question. At the beginning I wanted also have this, but it is not possible, unfortunately (for example easy checking all adresses with street and so on).

MAYBE
you could create some files with all references and then create a "data-driven" - category.

See my attachment, say you have
a file attribute "Verrechnung" and
a global attribute "Adressen"

As Mario pointed out, there is no variable that you can see all adresses (global).

But if you have linked some files with a field (or several fields) with adresses, than you could create a "dd", where you can see, like in my example, all names of the global adresses.
You could create, I guess, simply some files with links to all fields, what you want see and then create some levels in the dd-formula.

update: Kunde is one field of a global set "Adressen" (in my attachement) and on the left side you can see "test" of the "dd" from this field "Kunde"
Title: Re: Access Global Attributes as a Variable?
Post by: PandDLong on August 09, 2021, 10:33:57 PM

Thanks very much for the information.

I am sure I can find a different way to do what I wanted - your ideas are the right place to start.

I always appreciate this forum for the insights it provides.


Michael