Baanboard.com

Go Back   Baanboard.com > Forum > Baan Quick Support: Functional & Technical > Tools Development

User login

Frontpage Sponsor

Main

Poll
For ERP LN feature pack upgrade, what method of install are you using?
Installation Wizard into existing VRC
37%
Installation Wizard into new VRC
39%
Manual into existing VRC
3%
Manual into new VRC
21%
Total votes: 38

Baanboard at LinkedIn


Reference Content

Reply
 
Thread Tools Display Modes
  #1  
Old 3rd August 2017, 14:49
pralash pralash is offline
Senior Member
 
Join Date: Feb 2017
Posts: 130
pralash is on a distinguished road
Baan: 9.0 - DB: SQL Server - OS: Windows 2012R2
Is there any header file need to write a string into the file?

Hi,
I'm fresher to LN. I want to be right a string into the file. But I can't do it.
I think is there any header file is needed to this operation, I have mentioned my script below.

Thanks
Pralash...

Code:
function void file.creation.for.string.to.text.domain.conversion(string tmp.string)
{

    domain     tcmcs.long ft

|    #include <bic_text>

    file.tmp = creat.tmp.file$(bse.tmp.dir$() ) |create temp file Aug 3
    ft = seq.open(file.tmp,"w") |open file with write method
    |retn = seq.puts(tmp.string,ft) |tmp.string is your input text
    retn = seq.puts("senthil",ft) |tmp.string is your input text
    seq.close(ft)
}

Last edited by bhushanchanda : 3rd August 2017 at 14:56. Reason: added code tags!
Reply With Quote
  #2  
Old 3rd August 2017, 14:59
bhushanchanda's Avatar
bhushanchanda bhushanchanda is offline
Guru
 
Join Date: Sep 2012
Location: India
Posts: 2,322
bhushanchanda has a spectacular aura aboutbhushanchanda has a spectacular aura aboutbhushanchanda has a spectacular aura about
Baan: LN FP 1-9, 10.4, a little bit of Baan IV - DB: SQL Server 2008, Oracle - OS: Windows Server 2008 R2, Unix
Hi,

What error are you getting on compiling the script?

Couple of observations -

1. Check if "file.tmp" variable is defined
2. string tmp.string should be something like string tmp.string(1024)

You should not need any includes to use any of these functions.

Also, moved the thread to correct forum - Tools Development.
__________________
Regards,

Bhushan

Unless you try to do something beyond what you have already mastered, you will never grow!
Reply With Quote
Sponsored Links
  #3  
Old 3rd August 2017, 15:37
pralash pralash is offline
Senior Member
 
Join Date: Feb 2017
Posts: 130
pralash is on a distinguished road
Baan: 9.0 - DB: SQL Server - OS: Windows 2012R2
Hi,
Script is compiles successfully...
As you suggested, I already declared tmp.file and tmp.string....
But the files are created in c:\erpln\temp path... but the file doesn't contain
the writing information.

Can you please help to fix this...
Thanks,
Pralash
Reply With Quote
  #4  
Old 3rd August 2017, 16:17
bdittmar's Avatar
bdittmar bdittmar is offline
Guru
 
Join Date: Apr 2002
Location: Germany, 50.584097,8.544078
Posts: 1,653
bdittmar will become famous soon enough
Baan: 2.2/3.1/4c4/LN6.1 FP6/FP9/HiDox - DB: tbase, ms-sql7, oracle10gV1, 11g - OS: HP-UX, W2K3, SLES
Create asci file

Hello,
just an example.
Code:
|DECLARATION:

extern	string	l_datensatz(500)
extern	long	fpl, errl			|Filepointer



|Open labelfile for writing
	fpl = seq.open(<your file>, "w")


|Write 1st line with userinformation
	l_datensatz = "User:"&logname$
	errl = seq.puts(l_datensatz, fpl)

|Write 2nd line with Sentinel labelname
	l_datensatz = "LAB_NAME ="&"BGL_PR00087.lab"
	errl = seq.puts(l_datensatz, fpl)

|Built an empty line
	l_datensatz = ""
	errl = seq.puts(l_datensatz, fpl)

|Built the Header Line (variable names)
	l_datensatz =
	"ART_NR;REV;Bezeich;KW;Jahr;SFC;BCODE;count"
	errl = seq.puts(l_datensatz, fpl)

|Close the dataset file
	errl = seq.close(fpl)
Regards
__________________
//Bernd
Reply With Quote
  #5  
Old 3rd August 2017, 16:54
bhushanchanda's Avatar
bhushanchanda bhushanchanda is offline
Guru
 
Join Date: Sep 2012
Location: India
Posts: 2,322
bhushanchanda has a spectacular aura aboutbhushanchanda has a spectacular aura aboutbhushanchanda has a spectacular aura about
Baan: LN FP 1-9, 10.4, a little bit of Baan IV - DB: SQL Server 2008, Oracle - OS: Windows Server 2008 R2, Unix
Quote:
Originally Posted by pralash View Post
Hi,
Script is compiles successfully...
As you suggested, I already declared tmp.file and tmp.string....
But the files are created in c:\erpln\temp path... but the file doesn't contain
the writing information.

Can you please help to fix this...
Thanks,
Pralash
Pralash,

Can you post your complete code? How are you declaring tmp.file?
__________________
Regards,

Bhushan

Unless you try to do something beyond what you have already mastered, you will never grow!
Reply With Quote
  #6  
Old 10th August 2017, 14:01
pralash pralash is offline
Senior Member
 
Join Date: Feb 2017
Posts: 130
pralash is on a distinguished road
Baan: 9.0 - DB: SQL Server - OS: Windows 2012R2
I have fixed the issue....
Thanks for your information...
Regards,
Pralash
Reply With Quote
  #7  
Old 10th August 2017, 14:55
bhushanchanda's Avatar
bhushanchanda bhushanchanda is offline
Guru
 
Join Date: Sep 2012
Location: India
Posts: 2,322
bhushanchanda has a spectacular aura aboutbhushanchanda has a spectacular aura aboutbhushanchanda has a spectacular aura about
Baan: LN FP 1-9, 10.4, a little bit of Baan IV - DB: SQL Server 2008, Oracle - OS: Windows Server 2008 R2, Unix
Glad that you got it solved.

Please share the problem and the solution you came up with. It will help others or may be will help you in future.
__________________
Regards,

Bhushan

Unless you try to do something beyond what you have already mastered, you will never grow!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
MB string comparison manish_patel Tools Development 3 27th October 2015 22:12
bshell received SIGTERM manojsharma Tools Development 11 5th June 2008 10:22
Get values for Audited Field Hiba_t Tools Development 7 15th February 2007 10:26
Baan & Connectware Driver Hangs Rajasekhar Tools Administration & Installation 2 18th February 2004 22:32
File Browser Bogdan Tools Development 52 7th January 2004 09:17


All times are GMT +2. The time now is 08:31.


©2001-2017 - Baanboard.com - Baanforums.com