The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum for Programming
 LabTalk Forum
 importing data as XY XY format through labtalk
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

akash8393

India
7 Posts

Posted - 02/07/2018 :  2:26:59 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver.9.3 and Service Release 2016 (Select Help-->About Origin):
Operating System: windows 10

How do I import dat file as xy xy format in origin through labtalk

yuki_wu

896 Posts

Posted - 02/07/2018 :  9:27:55 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,

Try this:
impASC fname:="C:\test.dat" options.Cols.ColDesign:="(XY)";

More info about impASC X-Function, please read:
https://www.originlab.com/doc/X-Function/ref/impASC

Regards,
Yuki
OriginLab

Edited by - yuki_wu on 02/08/2018 02:26:39 AM
Go to Top of Page

akash8393

India
7 Posts

Posted - 02/08/2018 :  01:16:29 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
I was able to import data but the designation of the columns doesn't change from XYYY to XY XY XY
Go to Top of Page

yuki_wu

896 Posts

Posted - 02/08/2018 :  02:27:49 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,

Did you specify the Column Designations by Import Option, like the example above?

Regards,
Yuki
OriginLab
Go to Top of Page

akash8393

India
7 Posts

Posted - 02/08/2018 :  03:26:20 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks for the reply Yuki.
I've been using the below code to import multiple ASCII from a folder. My column designations stays XYYY after importing the data.
path$ = "F:\data";
findfiles ext:="Book2*.txt";
impASC;
options.Cols.ColDesign:="(XY)"
Go to Top of Page

Hideo Fujii

USA
1582 Posts

Posted - 02/12/2018 :  4:26:53 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi akash8393,

I think that specifying options.... after running impASC is too late. You can try:
impASC options.Cols.ColDesign:="(XY)";
Does it work?

--Hideo Fujii
OriginLab
Go to Top of Page

akash8393

India
7 Posts

Posted - 02/16/2018 :  04:36:56 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thanks a lot. It does work.
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000