Closed Looky1173 closed 11 years ago
Property | Value |
---|---|
Posted by | Bill Currey (wjcurrey) |
Date posted | Tue, 18 Dec 2012 15:38:41 GMT |
On Tue, Dec 18, 2012 at 6:59 AM, HongbiaoYang
Public bug reported:
Can't run the solution after download source code from the public SVN server. The Visual Studio reports an error of
"Error 8 'MSTS.CABViewControlUnits' does not contain a definition for 'METRESµSECµSEC' C:\Users\Hongbiao\Documents\Visual Studio 2008\Projects\openrail0.8\Source\RunActivity\RollingStock\MSTSLocomotive.cs 1652 54 RunActivity "
When trace back, the definition of the public enum variable CABViewControlUnits has some member like below: public enum CABViewControlUnits { ...... KM_PER_HOUR, MILES_PER_HOUR, METRES礢EC礢EC, METRES_SEC_SEC, KM礖OUR礖OUR, KM_HOUR_HOUR, KM礖OUR礢EC, KM_HOUR_SEC, METRES礢EC礖OUR, METRES_SEC_HOUR, MILES_HOUR_MIN, MILES_HOUR_HOUR, ...... }
It seems like some encoding problem.
** Affects: or Importance: Undecided Status: New
-- You received this bug notification because you are subscribed to Open Rails. Matching subscriptions: BillC https://bugs.launchpad.net/bugs/1091696
Title: Messy code in CABViewControlUnits
Status in Open Rails Tracker: New
Bug description: Can't run the solution after download source code from the public SVN server. The Visual Studio reports an error of
"Error 8 'MSTS.CABViewControlUnits' does not contain a definition for 'METRESµSECµSEC' C:\Users\Hongbiao\Documents\Visual Studio 2008\Projects\openrail0.8\Source\RunActivity\RollingStock\MSTSLocomotive.cs 1652 54 RunActivity "
When trace back, the definition of the public enum variable CABViewControlUnits has some member like below: public enum CABViewControlUnits { ...... KM_PER_HOUR, MILES_PER_HOUR, METRES礢EC礢EC, METRES_SEC_SEC, KM礖OUR礖OUR, KM_HOUR_HOUR, KM礖OUR礢EC, KM_HOUR_SEC, METRES礢EC礖OUR, METRES_SEC_HOUR, MILES_HOUR_MIN, MILES_HOUR_HOUR, ...... }
It seems like some encoding problem.
To manage notifications about this bug go to: https://bugs.launchpad.net/or/+bug/1091696/+subscriptions
Indeed it is an encoding problem, but has to do with localization. Below is the enum from the official SVN that developers use. Note that the public SVN is for reference purposes and can not be compiled. See http://www.elvastower.com/forums/index.php?/topic/20393-unable-to-build-from-source/page__pid__106016#entry106016
public enum CABViewControlUnits
{
NONE,
BAR,
PSI,
KILOPASCALS,
KGS_PER_SQUARE_CM,
AMPS,
VOLTS,
KILOVOLTS,
KM_PER_HOUR,
MILES_PER_HOUR,
METRESµSECµSEC,
METRES_SEC_SEC,
KMµHOURµHOUR,
KM_HOUR_HOUR,
KMµHOURµSEC,
KM_HOUR_SEC,
METRESµSECµHOUR,
METRES_SEC_HOUR,
MILES_HOUR_MIN,
MILES_HOUR_HOUR,
NEWTONS,
KILO_NEWTONS,
KILO_LBS,
METRES_PER_SEC,
LITRES,
GALLONS,
INCHES_OF_MERCURY,
MILI_AMPS,
RPM
}
Property | Value |
---|---|
Posted by | Bill Currey (wjcurrey) |
Date posted | Wed, 19 Dec 2012 16:11:53 GMT |
Additional commentary to the original poster. There was some confusion among the team members to if the open SVN source code could be compiled. See above link for details. There will provably be additional details in the future on how to go about doing this.
In your specific case there are Chinese characters in the Enum as shown above. Using English version of Visual Studio does not have this problem.
Property | Value |
---|---|
Posted by | HongbiaoYang (hongbiao-yang) |
Date posted | Wed, 19 Dec 2012 22:23:08 GMT |
My visual studio is English version, and the messy codes are not Chinese... Maybe it's because I installed Chinese language in the Windows 7 Operation System. I have replaced the messy codes with the correct one your provide in the last email, and looks like this error is gone, although the codes still can't compile, and I will respect the OR team's decision.
Thank you!
On Wed, Dec 19, 2012 at 11:11 AM, Bill Currey
Additional commentary to the original poster. There was some confusion among the team members to if the open SVN source code could be compiled. See above link for details. There will provably be additional details in the future on how to go about doing this.
In your specific case there are Chinese characters in the Enum as shown above. Using English version of Visual Studio does not have this problem.
-- You received this bug notification because you are subscribed to the bug report. https://bugs.launchpad.net/bugs/1091696
Title: Messy code in CABViewControlUnits
Status in Open Rails Tracker: Invalid
Bug description: Can't run the solution after download source code from the public SVN server. The Visual Studio reports an error of
"Error 8 'MSTS.CABViewControlUnits' does not contain a definition for 'METRESµSECµSEC' C:\Users\Hongbiao\Documents\Visual Studio 2008\Projects\openrail0.8\Source\RunActivity\RollingStock\MSTSLocomotive.cs 1652 54 RunActivity "
When trace back, the definition of the public enum variable CABViewControlUnits has some member like below: public enum CABViewControlUnits { ...... KM_PER_HOUR, MILES_PER_HOUR, METRES礢EC礢EC, METRES_SEC_SEC, KM礖OUR礖OUR, KM_HOUR_HOUR, KM礖OUR礢EC, KM_HOUR_SEC, METRES礢EC礖OUR, METRES_SEC_HOUR, MILES_HOUR_MIN, MILES_HOUR_HOUR, ...... }
It seems like some encoding problem.
To manage notifications about this bug go to: https://bugs.launchpad.net/or/+bug/1091696/+subscriptions
-- Hongbiao Yang (Bill) Graduate Research Assistant Industrial and Information Engineering University Of Tennessee Office 308 Knoxville Tennessee 37996 Phone: (865)-246-8741
Property | Value |
---|---|
Posted by | Bill Currey (wjcurrey) |
Date posted | Thu, 20 Dec 2012 00:40:01 GMT |
"Maybe it's because I installed Chinese language in the Windows 7 Operation System."
That the most likely explanation.
What other compilation errors are you encountering ? In addition do you have XNA Game studio installed? Posted below is a snippet of code from MSTSLocomotive.cs at ~= line # 1697 using case CABViewControlUnits.METRESµSECµSEC .... etc. You may want to check there to see if there is a similar problem to the one you had above
case CABViewControlTypes.ACCELEROMETER:
{
switch(cvc.Units)
{
case CABViewControlUnits.METRES_SEC_SEC:
case CABViewControlUnits.METRESµSECµSEC:
data = this.AccelerationMpSS;
break;
case CABViewControlUnits.METRES_SEC_HOUR:
case CABViewControlUnits.METRESµSECµHOUR:
data = this.AccelerationMpSS / 3600.0f;
break;
case CABViewControlUnits.KM_HOUR_SEC:
case CABViewControlUnits.KMµHOURµSEC:
data = this.AccelerationMpSS / 3.6f;
break;
case CABViewControlUnits.KM_HOUR_HOUR:
case CABViewControlUnits.KMµHOURµHOUR:
data = this.AccelerationMpSS / 3600.0f / 3.6f;
break;
// TODO needs dimensional analysis for conversion factor
case CABViewControlUnits.MILES_HOUR_MIN:
data = this.AccelerationMpSS / 60.0f;
break;
// TODO needs dimensional analysis for conversion factor
case CABViewControlUnits.MILES_HOUR_HOUR:
//
data = this.AccelerationMpSS / 3600.0f / 3.6f;
break;
default:
data = this.AccelerationMpSS;
break;
}
break;
}
Property | Value |
---|---|
Posted by | HongbiaoYang (hongbiao-yang) |
Date posted | Thu, 20 Dec 2012 15:12:26 GMT |
So you use Greek letter in the variable name? Like "CABViewControlUnits.METRESµSECµSEC", the character "µ", is that the original character in the code, or it's the messed up codes?
Thank you!
On Wed, Dec 19, 2012 at 7:40 PM, Bill Currey
CABViewControlUnits.METRES_SEC_SEC:
-- Hongbiao Yang (Bill) Graduate Research Assistant Industrial and Information Engineering University Of Tennessee Office 308 Knoxville Tennessee 37996 Phone: (865)-246-8741
Property | Value |
---|---|
Posted by | Bill Currey (wjcurrey) |
Date posted | Thu, 20 Dec 2012 16:26:26 GMT |
So you use Greek letter in the variable name? Like "CABViewControlUnits.METRESµSECµSEC", the character "µ", is that the original character in the code, or it's the messed up codes?
This is original source code from way back ; I don't personally but there is some evidence that European versions of MSTS do in the .CVF files. The code is not messed up. See my post today on compiling OR on a virtual machine.
Property | Value |
---|---|
Posted by | HongbiaoYang (hongbiao-yang) |
Date posted | Fri, 01 Mar 2013 20:13:45 GMT |
I'd like to add you to my professional network on LinkedIn.
hongbiao yang Graduate Research Assistant at University of Tennessee Xiamen, Fujian, China
Confirm that you know hongbiao yang: https://www.linkedin.com/e/-pxmq4c-hdrs5cew-5o/isd/11385513646/p-ispTsN/?hs=false&tok=1A61IpEFftqBE1
-- You are receiving Invitation to Connect emails. Click to unsubscribe: http://www.linkedin.com/e/-pxmq4c-hdrs5cew-5o/nJ1Er-KMWuo03VITZEqQqbyYcd041pwwpyJxDh73/goo/1091696%40bugs%2Elaunchpad%2Enet/20061/I3765107905_1/?hs=false&tok=2wXFo6kWftqBE1
(c) 2012 LinkedIn Corporation. 2029 Stierlin Ct, Mountain View, CA 94043, USA.
Imported from https://bugs.launchpad.net/bugs/1091696
Can't run the solution after download source code from the public SVN server. The Visual Studio reports an error of
"Error 8 'MSTS.CABViewControlUnits' does not contain a definition for 'METRESµSECµSEC' C:\Users\Hongbiao\Documents\Visual Studio 2008\Projects\openrail0.8\Source\RunActivity\RollingStock\MSTSLocomotive.cs 1652 54 RunActivity "
When trace back, the definition of the public enum variable CABViewControlUnits has some member like below: public enum CABViewControlUnits { ...... KM_PER_HOUR, MILES_PER_HOUR, METRES礢EC礢EC, METRES_SEC_SEC, KM礖OUR礖OUR, KM_HOUR_HOUR, KM礖OUR礢EC, KM_HOUR_SEC, METRES礢EC礖OUR, METRES_SEC_HOUR, MILES_HOUR_MIN, MILES_HOUR_HOUR, ...... }
It seems like some encoding problem.