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
 Origin Forum
 simple ascimp question
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

regal

USA
Posts

Posted - 03/28/2007 :  9:49:08 PM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Version (Select Help-->About Origin): 7
Operating System: XP

I am just starting to use Origin c and am trying to import ascii with via "ascimp". I try a code like the one below, and get the following erorr message when compiling: "Error, Member function Worksheet::ImportASCII not defined or does not have matching prototype". I don't know how to fix this error. It would also be useful for me to know where the full documentation is on the ImportASCII() function. I can't find much other than what is on the forum and a brief reference in the programming help associated with Origin 7.

Thanks much


void test()
{
string strFile = GetOpenBox("*.els");
if( strFile.IsEmpty() )
{
out_str("No file was selected!");
return;
}

Worksheet wks;
wks.Create("EL.OTW");
ASCIMP ascimp;
wks.GetASCIMP(ascimp);
// you can change any settings here if necessary
BOOL bRet = wks.ImportASCII(strFile, ascimp);
if( !bRet )
{
out_str("Failed to import file!");
// Destroy newly created worksheet
wks.Destroy();
return;
}
}

Mike Buess

USA
3037 Posts

Posted - 03/28/2007 :  10:06:38 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Your function compiles fine in 7.0SR4 so you just need to update. Run Help > Check for Updates and download/install whatever is found. Repeat until no updates are found. Alternatively, download the patch(es) directly from OriginLab's web site.
http://www.originlab.com/index.aspx?s=9&lm=76

Besides the Classes > Internal Objects > Worksheet > ImportASCII topic in programming guide the only material I know of is about the ASCIMP structure in OC_types.h. A couple examples also exist in the Import/Export category here.
http://www.originlab.com/index.aspx?s=8&lm=243

Mike Buess
Origin WebRing Member

Edited by - Mike Buess on 03/29/2007 10:37:34 AM
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