Book a Demo

Author Topic: C# Using Statements  (Read 3923 times)

techi

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
C# Using Statements
« on: June 07, 2012, 01:16:04 am »
The current C# code generation doesnt provide using statements, is there any way those statements can be generated with the code?

Also the Field naming format is not current, is there any thing to apply C# 4 naming conventions?

PaulV

  • EA User
  • **
  • Posts: 27
  • Karma: +1/-1
    • View Profile
Re: C# Using Statements
« Reply #1 on: June 07, 2012, 01:29:15 am »
Quote
The current C# code generation doesnt provide using statements, is there any way those statements can be generated with the code?

You can select the item for which the code is to be generated (e.g., a class element) in the project browser, Press F11 (or local menu / Generate code...). In the dialog appeared there is "Import(s) / Header(s)" input field. Type into all statements that you need.

Quote
Also the Field naming format is not current, is there any thing to apply C# 4 naming conventions?

The same dialog, button Advanced?
« Last Edit: June 07, 2012, 01:30:44 am by PaulV »

techi

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Re: C# Using Statements
« Reply #2 on: June 07, 2012, 04:31:34 pm »
You mean for each class i will have to do that? thats cumbersom if I have to generate 50 odd classes? :-[

PaulV

  • EA User
  • **
  • Posts: 27
  • Karma: +1/-1
    • View Profile
Re: C# Using Statements
« Reply #3 on: June 11, 2012, 05:06:24 pm »
Quote
You mean for each class i will have to do that? thats cumbersom if I have to generate 50 odd classes? :-[
For each c# file; you can tell EA to generate one c# file for more than one class (though this is some cumbersom too).

But you should write code for each class; a description for each class, each attribute/operation etc. That were more to do than copy/paste of some (few) #using lines ::)