Options

add prefix

rsreddyrsreddy Member Posts: 15
Hi all

how to add prefix to itemno in itemcard.

eg:itemno......1001
1002...

expected:new1001


pls help me...

Comments

  • Options
    lvanvugtlvanvugt Member Posts: 774
    By default, i.e. when a code is assigned to an item when it is created by the user?
    Or as a fix to already existing item numbers?
    Luc van Vugt, fluxxus.nl
    Never stop learning
    Van Vugt's dynamiXs
    Dutch Dynamics Community
  • Options
    rsreddyrsreddy Member Posts: 15
    thank u for responding
    its...
    as a fix to already existing item numbers?
  • Options
    lvanvugtlvanvugt Member Posts: 774
    So how about:
    Str1 := '1001';
    Str2 := COPYSTR(STRSUBSTNO('%1%2',NEWTXT,Str1),1,MAXSTRLEN(Str2));
    
    MESSAGE('Str1 = %1\Str2 = %2',Str1,Str2);
    
    With Str1 and Str2 of data type Text and NEWTXT being a text constant with content new
    Luc van Vugt, fluxxus.nl
    Never stop learning
    Van Vugt's dynamiXs
    Dutch Dynamics Community
  • Options
    rsreddyrsreddy Member Posts: 15
    Thank u..Luc van Vugt
Sign In or Register to comment.