frank holland
28th March 2011, 15:34
Hi,

For generic items, you can define a generic item text that contains product variant features. After entering a product variant, and generating the pv-structure, the features in this text are replaced by their corresponding values.

I have a text that looks like this:

Line 1: Option1 [myoption1] pcs
Line 2: Option2 [myoption2] pcs

where the features [myoptionx] contain numbers.

If the feature values have different lenghts, e.g. "9" and "99", the word "pcs" is not at the same column position (not aligned):

Line 1: Option1 9 pcs
Line 2: Option2 99 pcs

What I would like to have is:

Line 1: Option1 9 pcs
Line 2: Option2 99 pcs

Is there a way to enforce the alignment of such texts, e.g. by using a tab?
Or is there a way to set a fix length for a feature value?

I tried using the edit$ function, but apparently, this is not supported...

Thanks,
Frank

croezen
27th April 2011, 17:52
u could use the len() function to calculate the length of the field.

example.

string bre
bre = str([breedte])
if len(bre) = 2 then
itemdata = "0" & bre
else
itemdata = bre
endif