Scroll

Multiple Resources Per Response Code

Multiple Resources Per Response Code

Follow
Summary Article on how to switch between multiple resources for a single question response. e.g. one brand code could have different images depending on which region the interviewing is taking place in.
Applies to Askia Design
Written for Script writers, developers
Keywords Resource; Image; Language; Version; Response; Substitution; Design; askiadesign; ResourceURL.

 

The .qex file containing the example discussed can be downloaded here.


 

In an interview situation we ask a respondent to select an image for a brand. Normally the resource (image file in this case) is set on the codes of the variable:

This allows you to set one resource per response but what if we have a situation where the images change depending on the language of interviewing i.e. the brand has a different logo in different regions?

This is easy to manage by linking responses together using a common 'Resource ID' in the resource properties. (Right click > Edit).

The difference is that you have to set the correct language / region per logo as you can see above.

As soon as you establish the language with routing, your resource will bet set to the correct one for the correct region. Here you can test the example .qex file to see the difference between selecting UK & US.

When selecting UK, you will see different images and resource names to the ones shown above for US.

The screen shots of resource properties are from Design 5.3.5.3. From Design 5.4.2.0 onwards you can also change resources based on your questionnaire version.

Finally, it's worth noting that linking resources by an ID will also effect the .ResourceURL keyword. It automatically updates to output the correct resource name depending on which language has been selected. (See condition setting to imagename in the example .qex).

 

Have more questions? Submit a request

Comments