This topic is locked

Custom Labels

8/5/2014 2:30:39 PM
ASPRunnerPro General questions
J
JimSmiley author

Is it possible to have a multi-line and/or multi-color label?
My current label looks like this:
My Product 250/Case P/N 12345
I would like the generated label to read:
My Product

250/Case

P/N 12345 (This line would be colored Red)
Regards;
JRS

mperry622 8/5/2014



Is it possible to have a multi-line and/or multi-color label?
My current label looks like this:
My Product 250/Case P/N 12345
I would like the generated label to read:
My Product

250/Case

P/N 12345 (This line would be colored Red)
Regards;
JRS


are those three fields separate do they get pulled from three areas or one? I have a spot where i take the file name and add a url to the beginning and it makes it a clickable link...
Product +

  • Quantity +
  • PartNumber
    You would have to use an event after record processed to match the P/N line and change the format to red but it does seem doable.. let me know the answer to first question and ill help where i can.

J
JimSmiley author 8/5/2014

Thanks for the response.
All info is coming from the "Label" column of the "Fields" page.

mperry622 8/5/2014



Thanks for the response.
All info is coming from the "Label" column of the "Fields" page.


Darn, I was hoping it was three fields combined... Have you tried putting in some LINE breaks
into the label to see if it seperates it.. with it getting pulled from one field makes it hard to format it ... wish i could have helped more.

J
JimSmiley author 8/5/2014

I haven't found a way to add a "
" or "/r" that works. I can make this happen by manually breaking the text down into 3 separate labels but I was hoping to make ASPRunner generate the labels for me.

Sergey Kornilov admin 8/6/2014

Unfortunately we do not have a built-in option for multi-line labels. Your only option is to remove the standard label in Visual Editor and insert your own text there. You can make it multi-line as well as multi-color.

J
JimSmiley author 8/6/2014

That's what I thought but wanted to confirm.
Thanks for the info.

G
gonzalosb 8/7/2014

use the following code to separate on each space as "
":
replace(data("YourData")," ","
")
every space in the line will be replace as ENTER or
you need to use the space type as NOTE so you can have multy line effect

Add an extra
if you wan an extra space between lines
and PLEASE let me know if works for you...

J
JimSmiley author 8/7/2014



use the following code to separate on each space as "
":
replace(data("YourData")," ","
")
every space in the line will be replace as ENTER or
you need to use the space type as NOTE so you can have multy line effect

Add an extra
if you wan an extra space between lines
and PLEASE let me know if works for you...


Never could figure out how to implement your code. My current code is:
{BEGIN PO_label}

<P align="right">

{$label 2014OrderInfo PO}

</P>

{END PONumber_label}
Which yields a label that reads:
Purchase Order
What I wanted was:
Purchase

Order
Thanks for the response. Sorry I couldn't figure out how to make your code work.

G
gonzalosb 8/7/2014



Never could figure out how to implement your code. My current code is:
{BEGIN PO_label}

<P align="right">

{$label 2014OrderInfo PO}

</P>

{END PONumber_label}
Which yields a label that reads:
Purchase Order
What I wanted was:
Purchase

Order
Thanks for the response. Sorry I couldn't figure out how to make your code work.


before process or before display (one of those) :

Label=replace(data("label2014OrderInfoPO")," ","
")
and your code replace:

{$label 2014OrderInfo PO}
with:

{$Label}
let see what happen

i use this with field data, never tried with Labels

J
JimSmiley author 8/7/2014



before process or before display (one of those) :

Label=replace(data("label2014OrderInfoPO")," ","
")
and your code replace:

{$label 2014OrderInfo PO}
with:

{$Label}
let see what happen

i use this with field data, never tried with Labels


No Joy!
Microsoft VBScript runtime error '800a000d'
Type mismatch: 'data'/2014OrderInfo_add.asp, line 0

G
gonzalosb 8/7/2014

ok, got it.

go to section "Misc" on top open "label editor" next to languages
look for the label and modify the result as "Purchase </br>Order"

DONE!!!

that will do it..

J
JimSmiley author 8/7/2014



ok, got it.

go to section "Misc" on top open "label editor" next to languages
look for the label and modify the result as "Purchase </br>Order"

DONE!!!

that will do it..


Didn't work for me. Result was a label that reads "Purchase </br>Order"

G
gonzalosb 8/8/2014

what version of ASPR you have?

it works on 7.2 and 8.0
FYI the title "Purchase </br>Order" goes without ""
if you leave them on, you have that </br> result at the label title

J
JimSmiley author 8/8/2014



what version of ASPR you have?

it works on 7.2 and 8.0
FYI the title "Purchase </br>Order" goes without ""
if you leave them on, you have that </br> result at the label title


Version 8.1
This is what I have in the "English" field:
Purchase </br> Order </br> Number and the label reads Purchase </br> Order </br> Number

G
gonzalosb 8/8/2014

let see if this is what you need:



if it is, to do it:


if doesn't work go to "visual editor", double click on the menu bar and reset to defaults and retry step 2
if still not working try to create a new project fresh from scratch and see what happen

J
JimSmiley author 8/12/2014

Still same result. It looks correct in the "Style" tab but reverts to "Purchase </br> Order </br> Number" in the "Editor" tab. Creating new project doesn't have any effect.
Since Admin is saying it isn't possible, I've moved on to other matters.

G
gonzalosb 8/12/2014

Wow, incredible, but as you see works perfect for me even i see it generated on the browser

Sorry that doesn't for you.

just in case if wan to try one last time:

Leve a space before </br> .if you dont it doesnt work.