Normal Topic Error message I dont' understand. (Read 520 times)
NHUser
Full Member
***
Offline



Posts: 320
Location: Amherst, NH
Joined: Aug 2nd, 2010
Error message I dont' understand.
Apr 11th, 2017 at 8:43pm
Print Post Print Post  
I'm using the code below to create a .txt file of data from my application.  In the programming below, I'm showing two @SpecCommand(SPEC_OPERATION_RUN, SPEC_TYPE_EXPORT) statements for clarity to explain my problem.

I have the exact same programming (cut and past is wonderful!) but when I used the @SpecCommand(SPEC_OPERATION_RUN, SPEC_TYPE_EXPORT) statement to write to the SAMPLES.txt, it easily creates the file.  BUT, when i run the same command but try to write to the VENDOREVAL.txt file, I get a message saying "ASCII Export failed to create the file..."

Any idea what might be causing one file not to write, while the other works fine?

Any help is greatly appreciated!!

NHUser

#include "sbasic_include.sbas"

var vRt as String

/*
Arguments:
filename
custom seperator character
custom delimiter character
tabbed
use custom sep
no sep
ignore fixed
all
none
use custom delim
header
*/

     vRt = @SpecCommand(SPEC_OPERATION_LOAD, SPEC_TYPE_EXPORT, "All Data")
     vRt = @SpecCommand(SPEC_OPERATION_RUN, SPEC_TYPE_EXPORT, "D:\apps\sesame2\data\VendorEval.txt", ",", """", "0", "1", "0", "0", "0", "0", "1", "0") 


     vRt = @SpecCommand(SPEC_OPERATION_RUN, SPEC_TYPE_EXPORT, "D:\apps\sesame2\data\samples.txt", ",", """", "0", "1", "0", "0", "0", "0", "1", "0") 


     @MsgBox("All the data has been exported to the VendorEval.txt file.","","")
  
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: Error message I dont' understand.
Reply #1 - Apr 11th, 2017 at 8:51pm
Print Post Print Post  
Hi Paul,

Is VendorEval.txt set to be read-only or possibly in use by another program?

One other thing that may cause it is the user account that Sesame is running under not having Write permissions to that txt file.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged