Z-Space Technologies, Inc.
Support Forums
Join | Logon
ITScriptNet Support Forums
 All Threads | New ThreadView:  Search:  
 Author  Thread: Configured Received file as CSV
CDalal
Posts: 7
Configured Received file as CSV
Posted: 01 Mar 11 11:07 AM
I have configured received file set as .CSV with no header.
When i download my data from stimulate, it skip one number in *.csv file.
Like if i start my start ticket number as 101 and goes to 115 when i download my data into file it start with 102 and goes to 116.
Can you let me know when is that happen?

Thanks

[Reply][Quote]
Bev Connor
Posts: 117
Re: Configured Received file as CSV
Posted: 01 Mar 11 4:43 PM
In your program, what is the script (copy for us please) which increments the ticket number?
Where does this script run in the program? (such as in AfterValidation or the OnClick of a button)?
What is the initialized value of the ticket number counter?
How many mobile devices will you be using?
In your program (and for testing purposes), if you have a variable that is used for the counter, you could place a Message function to view the value of the variable on each pass through the data collection. For example: Message(@variablename@, "").
[Reply][Quote]
CDalal
Posts: 7
Re: Configured Received file as CSV
Posted: 02 Mar 11 9:02 AM
Thanks for your reply,

Here is my script for increments the ticket number:

;increments ticket number

if(@totalticket@ <$total.Ttkt$)
$total.Ttkt$<>@totalticket@
$total.Tpart$<>@totalticket@
$total.TQty$<>@totalticket@
else
$total.Ttkt$=@totalticket@
$total.Tpart$=@totalticket@
$total.TQty$=@totalticket@
endif


$p1.ticket$=$login.tick$
$total.Ttkt$=$total.Ttkt$+$p1.ticket$
$total.Tpart$=$total.Tpart$+$p1.desc1$
$total.TQty$=round(($total.TQty$+$p1.qty$),4)
$login.tick$=$p1.ticket$+1
;endif


;Write pallet records, loops else saves and goes to location screen (lp)

IF (@counter@ < $mpallet.mp$)

FileAppend("GrdReceiver.txt",Pad($p1.ticket$,10) & Pad(@POVAR@,15) & Pad($p1.desc1$,15) & Pad($p1.desc2$,30) & Pad($p1.desc3$,6) & Pad($p1.Qty$,15) & Pad($p1.date$,15) & Pad($login.PlantCode$,10)& Pad($login.EmpNo$,15)& Pad($alias$,5)& ascCR & ascLF)

"Save"



ELSE
FileAppend("GrdReceiver.txt",Pad($p1.ticket$,10) & Pad(@POVAR@,15) & Pad($p1.desc1$,15) & Pad($p1.desc2$,30) & Pad($p1.desc3$,6) & Pad($p1.Qty$,15) & Pad($p1.date$,15) & Pad($login.PlantCode$,10)& Pad($login.EmpNo$,15)& Pad($alias$,5)& ascCR & ascLF)


;message("bcount:"&$total.Ttkt$, "messages", "ok",)
;right(pad($p1.ticket$),20)

"p1"

ENDIF

;Increment Counter
@counter@ = @counter@ + 1

>>>>>>>>>>>>>>>>>>>>>>>>>>>

Script run as "Next Prompt"

I am using just one mobile devise at this moments.

[Reply][Quote]
CDalal
Posts: 7
Re: Configured Received file as CSV
Posted: 02 Mar 11 9:03 AM
Thanks in advance...
[Reply][Quote]
CDalal
Posts: 7
Re: Configured Received file as CSV
Posted: 02 Mar 11 9:16 AM
Ticket ..as default response

@rtkt@=$login.tick$
@rtkt@


@totalticket@=0


I have to put the starting ticket number on my logon screen and it copied to scanning screen and then once i hit enter it will increment to next number.
I am getting right series on my scanner gun but when it write to .csv file it skip the first number and start with the second. so ticket number 1 date will show on ticket number 2
[Reply][Quote]
Bev Connor
Posts: 117
Re: Configured Received file as CSV
Posted: 02 Mar 11 11:52 AM
When incrementing a number in your program, the best approach would be to place the incrementing script into the OnClick event of a button, or in the AfterValidation of the prompt where the record data is saved; and be sure to initialize any variables at the start of the module or in the Start Program Event (from the designer menu row, go to Program > Program Events >Program Start button).
When the incrementing script is placed in the Next Prompt function button, the record is saved before the counter has incremented.
[Reply][Quote]
 Page 1 of 1 
 
Website (C) 2004-2008 Z-Space Technologies, Inc. All Rights Reserved.
All messages posted here are the sole responsiblity of the poster. Z-Space Technologies, Inc. is not responsible for the content of messages. Messages do not reflect the official positions or policies of Z-Space Technologies, Inc.