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
 Forum for Origin C
 How to get the Origin version?
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

rainlane

China
22 Posts

Posted - 06/13/2017 :  04:49:34 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
Origin Ver. and Service Release (Select Help-->About Origin):
Operating System:Windows 7 X64
Origin: Origin 2017

How to get the Origin version using OringC ?
Is there any funtion to get it?

forum

Chris D

428 Posts

Posted - 06/13/2017 :  09:24:30 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hi,

Try this function:

string my_get_origin_version()
{
	double dd;
	LT_get_var("@V", &dd);
	string strVersion;
	strVersion.Format("%.2f", dd);
	return strVersion;
}


It will return the Origin version as a string in the format of:
9.00, 9.40, 9.41, 9.42 etc.

Thanks,
Chris Drozdowski
Originlab Technical Support
Go to Top of Page

Castiel

343 Posts

Posted - 06/15/2017 :  8:50:51 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
quote:
Originally posted by rainlane

Origin Ver. and Service Release (Select Help-->About Origin):
Operating System:Windows 7 X64
Origin: Origin 2017

How to get the Origin version using OringC ?
Is there any funtion to get it?

forum



int ver = _OC_VER;
printf("%x\n", ver);



     #####
    #### _\_  ________
    ##=-[.].]| \      
    #(    _\ |  |------|
     #   __| |  ||||||||
      \  _/  |  ||||||||
   .--'--'-. |  | ____ |
  / __      `|__|[o__o]|
_(____nm_______ /____\____ 
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