100% found this document useful (1 vote)
945 views

NXopen Interview 4-5

In C#, the entry point for both internal and external applications is the Main() method. In C/C++, the entry point for internal applications is Ufusr, while for external applications it is Main(). Polymorphism refers to a base class object behaving differently based on the derived class object assigned to it. Static methods belong to a class and are called by the class name, while non-static methods belong to an object and require creating an instance of the class to call them. Tag is an unsigned integer data type used in NX to allocate a unique ID to each entity in a model.

Uploaded by

Ravi Kumar
Copyright
© © All Rights Reserved
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
945 views

NXopen Interview 4-5

In C#, the entry point for both internal and external applications is the Main() method. In C/C++, the entry point for internal applications is Ufusr, while for external applications it is Main(). Polymorphism refers to a base class object behaving differently based on the derived class object assigned to it. Static methods belong to a class and are called by the class name, while non-static methods belong to an object and require creating an instance of the class to call them. Tag is an unsigned integer data type used in NX to allocate a unique ID to each entity in a model.

Uploaded by

Ravi Kumar
Copyright
© © All Rights Reserved
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
You are on page 1/ 5

68.

What are the entry points for internal and external applications in
C# and C/C++?

Ans. In C#:-

The entry Point is Main() for both internal and external applications.

In C/C++:-

For internal application the entry point is Ufusr.

For external application the entry point is Main().

60. What is polymorphism?

Ans. A base class object behaving differently based on derived class


object assigned.

61. What is the difference between static and non static?

Basically, static methods are belongs to class. So static methods are


called by class name.

Non static methods are belongs to object. So we need to create an


object for the class. By using that object we can call the non static
methods.

38. What is tag?

Ans.

1. Tag is an unsigned integer data type.


2. Whenever you open part file in NX, NX allocates an ID to each and
every entity in the model.

3. This Tag/ID will vary when you try to open the same file again.

30. What NX OPEN classes you have used?

Ans.
BlockFeatureBuilder,BodyFeature,Feature,FeatureCollection,SphereBuil
der,BlockFeatureBuilderClass,Part,PartCollection,Session,LayerManager,
DraftingView,DraftingViewCollection,DarwingSheet,DrawingSheetCollec
tion,etc.

25. Inter part expressions

Ans. Inter part expressions are expressions that you link from one part
to another. You can use inter part expressions to model.

Inter part expressions may be created between any two part files. The
part files need not to be components of an assembly.

There are two types of inter part expressions:

· Referencing expressions: expressions that take their value from an


expression in another part.

· Overriding expressions: expressions that set the value of an


expression in another part.

20. How to load and display your Block UI Styler dialog in NX using
API’s provide in NXOpen.Block styler namespace?
Ans.

Callbacks in Block Ui Styler :-

Constructor

Show ()

Initialize ()_________method

Dialogshown()_____method

Apply ()___________method

Ok ()_____________method

Update ()__________method

54. What is the purpose of update call back?

Ans. Whenever you do any activity on the block then it will go to the
update call back. There corresponding block call backs will be executed.

33. Why signing is required?

Ans. Every company will not have developer licence or author licence.
Whenever developer develops a tool need to be signed and give it to
the end-user. So then the user may not require a licence.

Application will load faster because nx will immediately recognise that it


has been signed.
The syslog will not be cluttered with the output from the multiple
checks that nx will do to determine whether it can load and run the
program.

34. What are the steps for signing process?

Ans. A resource file must be added to the project file. The resource
must be compiled and linked with the executable.

Run the signing utility to add an encrypted string to the executable.

The .Net resource file is found in <NX install directory>\UGOPEN\

The .Net signing utility is found in <NX install directory>\NXBIN\

42. What is typecasting in C?

Ans. Type casting is a way to convert the variable from one data type to
another data type .

Syntax :- (type)expression.

Ex :-

Main()

int sum = 17, count = 5;

double mean;

mean = (double)sum/count;

printf(“value of mean:%f \n”,mean);


}

* Two types:-1. Implicit – performed by compiler automatically.

2. Explicit – performed by using cast operator.

31. How do you do exceptional handling in NXOpen and UFunc ?

Ans: In NXOpen by using try catch,

In the try block we will write our complete code so while executing if
any error exists in the try block then catch block will be executed.

UFUNC:

In UF_FUNC almost all “API” will return an integer that is an error


number. This error number will convert to error message by using
UF_GET_fail_message.That message will print it in a syslog/log file.

67. how can print the errors?

Ans.

In Nxopen:-

We can print the errors By using LogFile class.

In UFUNC:-

We can print the errors By using UF_print_syslog API.

You might also like