Make JNI String and jsize global

How can I make a string and an int global?
I want to make jnitstr and strsize, ie the the string data and the string size global and accessiblee outside JNI methods, ie in C functions.
const jbyte *jnistr;
     jsize strsize;
     jnistr = (*env)->GetStringUTFChars(env,prompt,NULL);
     if(jnistr==NULL){
          return;
     strsize = (*env)->GetStringLength(env,prompt);
Thank You,

Thanks...
I just declared a char array outside all function definitions char buf[BUFSIZ];
and when I am using it in a functions, I used this extern char buf[BUFSIZ];
If I want to access the elements of this array, which is being populated in some other function...,
then how can I do it...
I am returning this array to a java method.
     for(i=0;i<37;i++){
          (*env)->SetObjectArrayElement(
               env,ret,i,(*env)->NewStringUTF(env,buf));     
          printf(buf[i]);
When I declare the elements like buf[i], then I am getting an error on compilation.

Similar Messages

  • MAKE TO ORDER AND VARAINT CONFIGURATION

    Hi firends,
    What is the difference between MAKE TO ORDER and  VARAINT CONFIGURATION   PROCESS, in which scenarios we are using both topics. Can any one explain about steps for make to order and variant configuration. i need complete process.

    PLS REFER LIN BELOW
    Make-to-Order (MTO)
    Purpose
    The planning strategies explained in this section are designed for the production of a material for a specific individual sales order. In other words, you do not want to produce finished products until you receive a sales order. This means that make-to-order strategies always support a very close customer-vendor relationship, because your sales orders are closely linked to production.
    The same relationship exists between the sales order and production that exists in a make-to-order environment. Make-to-order is also used in the following environments.
    Production using variant configuration
    Assemble-to-order
    Prerequisites
    Choose a make-to-order strategy, if:
    The materials are segregated. In other words, they are uniquely assigned to specific sales orders.
    Costs must be tracked at sales order level and not on material level.
    Make-to-order strategies should always be combined with lot-size key EX (lot-for-lot. Rounding values should not be used. If you maintain rounding values, they have no effect due to the make-to-order properties of these strategies.
    Process Flow
    There are extensive options that enable you to procure components especially for specific sales order items.
    You may, however, want to use a different planning strategy to procure components without sales orders. This allows you to keep your replenishment lead time to a minimum. You can do this by:
    Planning on the basis of the finished product (see Planning Without Final Assembly (50) or Planning with a Planning Material (60))
    Planning at component level (see Strategies for Planning Components)
    Using consumption-based or Kanban-controlled components
    Customer stock can exist on any BOM level. See Stockkeeping at Different BOM Levels for more information.
    Because production is closely linked to sales orders, this results in a customer section in the stock/requirements list.
    Unplanned goods receipts (such as returns) cannot, as a rule, be used for other sales orders, even if they are in working order, unless they are adapted to meet a customer's needs.
    In the basic make-to-order strategy, Make-to-Order Production (20), no specific product structures are required. This means that it does not matter if the material has a BOM or not. The material can be produced in-house, or it can be procured externally. No planning is involved in this strategy.
    Planning Without Final Assembly (50) and Planning with a Planning Material (60) do require a specific product structure (i.e. a BOM, which means materials are always produced in-house). These planning strategies assume that you want to plan procurement (production or purchasing) of your components by planning the finished products. This means that you need to have a fairly stable demand for your finished products. If, however, you can plan more easily at component level than at finished product level, see Strategies for Planning Components.
    Make to order production
    1. Make to order production means that the materials (finished products) are not stored in the warehouse but produced especially for a particular sales order or a sales order item. An individual customer requirement is generated from the sales order item and transferred to materials planning (MM/PP). You can use materials planning to plan requirements. Once this has been done, production is carried out. After the product has been manufactured, you post it by goods receipt to sales orders stock specifically for this sales order item. As soon as the delivery is due, you can enter the delivery in SD and post goods issue which reduces the sales order stock and then a billing document can be entered.
    2. The item category in the sales document is found using the sale document type and the item category group from the material master found on the tab page sales org 2 i.e.
    a. sales document type – OR
    b. item category group – 0001
    c. item category - TAK
    3. MTO without assembly processing – the requirement quantity (planned independent requirements), delivery date and configuration specifications are transferred from the sales order to materials planning as an individual customer requirement. A planned order is generated using a planning run where the bills of material are exploded and dependant requirements (i.e. multi-level BOM) for the assemblies and components are generated. As soon as the production starts, a production order is created from the planned order. The system returns the confirmed quantity and delivery date from the production order to the sales order.
    4. MTO with assembly processing – in this case the individual components for the final product have already been produced. You only need to assemble the components according to the customer’s wishes. In this process, you only need a one level BOM and generation of dependent requirements is not necessary. In this case no planning run is generated and a production order is created directly from the sales order. The system returns the confirmed quantity and the delivery date from the production order to the schedule lines in the sales order. Any changes made to the confirmed schedule lines or the delivery date is immediately visible in the sales order and/or in the production order.
    5. After production department has finished making the material, goods receipt is posted in the sales order stock i.e. special stock which can only be used for a specific sales order. After posting goods issue for outbound delivery, the sales order stock is reduced accordingly.
    6. Make-to-order production is a process in which a product is individually manufactured for a particular customer. In contrast to mass production for an unspecified market where a material is manufactured many times, in make-to-order production a material is created only once though the same or a similar production process might be repeated at a later time.
    7. You can use make-to-order production: (a) For branches of industry or products where a small quantity of products with a large number of different characteristics are manufactured (b) When a product has to be assembled particularly for a sales order.
    8. Stock keeping is not usually carried out for products that are made to order. In companies using make-to-order production, the demand program only determines the production area, in which various variant types are produced. Depending on how you track the costs associated with make-to-order production, there are two ways to process make-to-order items during sales order processing.
    (a) Make to order using sales order
    (b) Make to order using project system (not relevant for SD application)
    9. for make to order production using the sales order, all costs and revenues involved for an order item are held collectively at that item. A particular rule is used that can be changed manually to transfer costs to profitability analysis.
    10. make to order production is largely a production planning configuration. It is also controlled by the requirements type, which is determined by three things
    the strategy group (MRP 3) in MMR
    the MRP group (MRP1) in MMR
    the item category and MRP type (MRP 1)
    11. Make-to-order production is controlled by the requirements type. The requirements type is determined on the basis of the MRP group (MRP1) and the strategy group (MRP3) in the material master record. In addition, a plant must be assigned for make-to-order items in the sales order.
    VARIENT CONFIGURATION
    Variant configuration is for manufacturing complex products in which customer determines the features of the product. Objective of variant configuration is to react quickly to customers' requirements.
    Here it needs not to create separate material for each variant of a product. When companies introduce variant configuration this often goes beyond a business process re-engineering project.
    1 Variant configuration offers an opportunity to restructure product structures for which then processes are defined. This has a direct impact to the core areas such as marketing and product data management.
    2 Advantages of VC
    · No need to Create separate material master for each variant combination.
    · Super BOM and Super Routing is enough for representing all possible Variants and Operations.
    · Able to react more flexible to customer demands.
    · Increase Information exchange between sales, engineering and production.
    3 What is Configurable Material?
    · A material with different features or characteristics and options is known as configurable material. Example: PC, Car.
    · Configurable materials are either created in a material type that allows the configuration (n the standard system, the material type KMAT) or they are given the indicator Configurable in the material master record.
    4 Master Data used for VC
    Following Objects are used as Master data for Variant configuration.
    1. Super BOM
    2. Super Routing
    3. Characteristic
    4. Class
    5. Object Dependencies
    6. Configuration Profile
    7. SD Condition records
    4.1 Super BOM
    Super BOM Contains all the components for producing configurable product. It contains both variant as well as non-variant parts required for producing configurable product.
    4.1.1 Super BOM configuration
    Super BOM can be created either one of the following methods.
    · Create BOM with class Item of 200-class type that contains all characteristic of a configurable material.
    · Create BOM with all possible materials as its components. Then assign /define dependencies to each component.
    The different between these two methods is
    · BOM with class item, no need to assign or define object dependencies. Instead of that each material is classified in material master itself using class 200.
    · For both cases all characteristics are assigned to class 300 which is again assigned to KMAT material in order to trigger configuration in configuration profile.
    4.1.2 Super BOM with Class Item
    Class items used to control the selection of variant parts in a BOM. Variant parts are classified in a class, and the class is entered in the BOM as a class item. When you configure the material, the class is replaced by a suitable variant part.
    4.1.3 Advantages of using Class Item in BOM
    · Only one item for the class is enough, instead of several items for the individual variant parts.
    · No need to create and assign selection conditions.
    · Able to classify additional objects in the class at any time, without having to change the BOM.
    4.1.4 Steps involved in super BOM with Class
    – Define all Characteristics and its Values assign it to Class with type 200.
    – Assign characteristic Values to materials by Classification material
    – Assign class 200 with material instead of assigning all BOM items.
    – Create and Assign class 300 (with same characteristics) with configurable product using configuration profile.
    4.1.5 Super BOM with Material Components
    This bill of material (BOM) of a configurable material contains all the components that are required to manufacture the material. The BOM contains components that are only used in specific variants (variant parts), as well as components that are used in all variants (non-variable parts).
    4.1.6 Steps involved in super BOM with Material Components
    – Define all Characteristics and its values assign it to Class with type 300.
    – Assign Class with configurable material in Configuration profile.
    – BOM is created with all variant and non-variant items.
    – Define interdependency between objects (Characteristic, BOM item, Routing Operation etc…) by using Object Dependencies.
    – Assign class 300 with configurable product using configuration profile.
    4.2 Super Routing
    A configurable routing describes the production process for all variants of a product. Instead of creating a routing for each variant of a product, you can create operations for one routing, or a "super" routing.
    It is possible to maintain Object dependencies for following in super routing:
    · Sequences
    · Operations/sub-operations
    · Production resource/tool assignments
    The routing is configured by system, when order is created for KMAT material.
    4.3 Characteristic
    Characteristic is used to define the features of a configurable material. To enable to use characteristics to configure a material, assign the material to a class of class type 300. The customer can choose from among different options for each characteristic.
    · Characteristics describe the properties of objects. The values of a characteristic specify these properties.
    · Value assignment to characteristic may be single value or multiple value with required entry or restrict able entry.
    · In characteristic it is also possible to use table name and its field name in order to change the Object quantity or values. I.e. BOM item quantity or Operation time, which is known as ‘reference characteristic’.
    · In Restriction screen allowed Class types are entered i.e. for what are the class this characteristic may used. In general for Variant configuration class 200 and 300 are used.
    · It is also possible to assign Dependency to characteristic values maintained in Characteristic.
    4.4 Variant Class
    · In Variant configuration, Class is used to hold the characteristics that describe about configurable material. Class type to determine which object types can be classified.
    · Class is used in variant configuration if the class has a class type that supports variant configuration. In Customizing for Classification, the Variant class type indicator must be set for the class type. In the standard system, this is class type 300.
    4.5 Dependencies
    · Dependencies restricts the combinations of options i.e. characteristic that are not allowed. It also select exactly the right BOM components and operations to produce a variant.
    · It also describe the interdependencies between characteristics and characteristic values
    · It control which components are selected from a bill of material (BOM) and which operations are selected from a task list
    · It also changes the values of fields in BOM items and operations during configuration.
    4.5.1 Global and Local Dependencies
    Global dependencies have the following properties:
    · They are independent of any object.
    · They are identified by a name that you assign, and are maintained and managed centrally.
    · If you change a global dependency, the change affects all the objects where the dependency is used
    Local dependencies have the following properties:
    · They are only available to the object for which you create them
    · You cannot use the central maintenance functions on these dependencies, and you cannot allocate them to other objects
    · They are identified by a number assigned by the system, not an external name
    Local dependencies are only used where certain dependency will not be needed elsewhere
    The differences between global and local dependencies are as follows:
    · Global dependencies are created centrally and can be assigned to several objects.
    · Local dependencies are created for one object and can only be used with this object
    4.5.2 Declarative and Procedural Dependency
    · In Declarative dependencies the result are explained logically
    · Declarative dependencies are easier to trace than procedural dependencies, because the point in time when the dependency is processed and the sequence in which the dependencies are processed are not relevant.
    · Example for Declarative dependency:
    - Constraint
    - Actions
    - Preconditions (provided that they contain no non-declarative expressions)
    - Selection conditions (provided that they contain no non-declarative expressions)
    · In Procedural Dependency result depends on the processing sequence and the point in time when the dependency is processed.
    - Procedures
    - Preconditions (only if they contain non-declarative expressions)
    - Selection conditions (only if they contain non-declarative expressions)
    4.5.3 Dependencies Types
    The SAP System supports the following types of dependencies:
    · Preconditions
    · Selection conditions
    · Procedures
    · Actions (obsolete)
    · Constraints
    4.5.4 Preconditions
    Preconditions can be allocated to the following objects:
    · A characteristic that you want to hide
    · A characteristic value that you want to hide
    Preconditions are used to hide characteristics and characteristic values that are not allowed and thereby ensure that the configuration of an object is consistent. In the precondition, it is also possible define the circumstances under which a characteristic or value is hidden.
    A precondition is fulfilled if the condition you enter is either true or not violated.
    4.5.5 Selection Conditions
    Selection conditions used to ensure that all the objects relevant to a variant are selected:
    · Selection conditions determine which variants require a specific component or operation
    · Selection conditions determine when it is mandatory to assign a value to a characteristic
    Selection conditions may allocate to the following objects:
    · Characteristics
    · BOM items
    · Operations in task lists
    · Sub-operations
    · Sequences of operations
    · Production resources/tools (PRTs)
    A selection condition is fulfilled if the condition in it is unambiguously true.
    4.5.6 Procedure
    Procedures can be assigned to the following objects:
    · The characteristic value that triggers the procedure
    · The characteristic that triggers the procedure
    · The configuration profile of the configurable object
    Procedure is used for following purposes.
    · A procedure is used to infer a value for a characteristic, you enter the variable $SELF before the characteristic.
    · Procedures can overwrite values that are set by other procedures.
    · Procedures are always used for pricing (see Variant Conditions).
    Processing Sequences of Procedure
    If an object has more than one procedure, a processing sequence is used to define the point when the procedure is processed.
    4.5.7 Action
    Actions are used to infer characteristic values. An action is processed as soon as the characteristic to which it is assigned has a value. It is not possible to overwrite the characteristic values that are set by an action.
    The following Objects can assign to action:
    · The characteristic value that triggers the action
    · The characteristic that triggers the action
    · The configuration profile of the configurable object
    · Configuration profile
    · BOM items – to change the quantity
    · Operations in task lists – to change the standard values
    Since Action is lead to serious system performance problems, it is replaced by Procedure and Constraint.
    4.5.8 Constraint
    This dependency type is mainly for intensively interactive configuration tasks and for configuration tasks in which you need to take into account the dependencies between the characteristics of several objects. The main purpose of a constraint is to monitor the consistency of a configuration.
    Constraints have the following distinguishing features:
    · Constraints are used to describe the dependencies between completely different objects and their characteristics.
    · Constraints are used to store information on which conditions must be fulfilled if the configuration is to be consistent.
    · Constraints are not directly allocated to individual objects. They are grouped together to form dependency nets and allocated to a configurable material in the configuration profile.
    · In constraints, you enter objects in their general form of expression, without using $SELF, $ROOT, or $PARENT to identify objects. As a rule, you refer to objects in constraints by entering the class to which the objects are allocated.
    · Constraints are declarative dependencies. The processing sequence of constraints and the point in time when constraints are processed is not relevant.
    · Constraints are not processed in a specific order. You cannot determine when a specific constraint is used.
    In any processing situation, a constraint is only processed once. If a value that is relevant to the constraint is changed, the constraint is triggered again.
    4.5.8.1 Structure of Constraints
    There are four sections in a constraint. Each part is identified by a keyword. A colon follows the keyword. Each section ends with a period.
    OBJECTS:
    In this section, you enter the objects that are relevant to the constraint. You must enter the relevant objects in all constraints. You can also define variables for objects or characteristics.
    CONDITION:
    The condition entered here must be fulfilled in order for the constraint to be used. You do not need to enter a condition in a constraint. You can leave out the keyword CONDITION: if required. However, if you enter the keyword you must enter a condition.
    RESTRICTIONS:
    In this section, you enter the relation that must exist between the objects and characteristics if the configuration is to be consistent. You must enter a restriction in a constraint.
    INFERENCES:
    In this section, you enter the characteristics for which characteristic values are to be inferred. The main purpose of constraints is to check the consistency of a configuration. Usually, values are only inferred if you make an entry in this section.
    For reasons of performance, only use constraints to infer values if it is really necessary. Constraints are grouped together to form dependency nets. The dependency net is allocated to a configurable material in the configuration profile.
    4.5.9 Dependency Net:
    Constraints are grouped together in dependency nets. For this reason, the variant configuration menu does not support a function for creating constraints directly. So that only constraints are defined within a dependency net.
    5 Configuration Profile
    The configuration profile for a material controls the configuration process in sales order. Configurable profile also used to define central settings for configuring the object. Using this profile it is possible to hide some of the characteristic value defined during characteristic creation. We can assign any number profile for a configurable material in which selection is based on either priority or manual selection during configuration.
    By defining a filter in the configuration profile, possible to determine the scope of the BOM items to improve system performance when exploding the BOM. The filter is active in high-level configuration, in result-oriented BOMs, and in SET processing.
    5.1 Filters in Configurable Profile
    Following objects can be used as filter:
    · Object type
    Class, material, document, text
    In the standard system, all object types are selected and therefore exploded in the configuration. Deselect the object types that you do not want to be displayed.
    · Item category, for example, stock or non-stock item
    All item categories in the configuration are exploded in the standard system. Remove the selection for the item categories you do not want to be displayed.
    · Item status
    You maintain the status of a BOM item in maintain BOM dependent on its usage.
    All items are displayed regardless of their item status in the standard system. However, only the items with this status are displayed when you select specific item statuses. Items are not displayed that do not have the selected status.
    · Sort string
    You can assign sort strings for BOM items in maintain BOM. You can restrict the display of the BOM items by using these sort strings.
    Only items that carry sort strings are checked and only those that match are displayed. Items that have no sort string are always displayed.
    5.2 Component availability in the configuration profile
    The availability check is just a snapshot, telling that whether the materials required are in stock at this moment. Several users can access the same material at once. This means that supply problems can sometimes be overlooked.
    Example: Only 2 pieces of a material are in stock, but the material is used in 3 BOMs. The availability check does not detect a supply problem. The availability check for all 3 BOMs shows 2 pieces in stock.
    5.3 Process Overview
    There are different processes for configurable materials in sales documents. These processes can be defined on the Configuration initial screen tab in the configuration profile, by choosing the Configuration parameter tab.
    The Process are described in the following scenarios:
    Planned/Production orders
    This processing type is used to describe variant products whose configurable materials are assembled using planned and production orders. The bill of material (BOM) can have single-level, multi-level, or no explosion.
    Sales Order (SET)
    This processing type is used to describe variant products that comprise salable configurable materials. These products are supplied together, but are not assembled in a production order. Only sales-relevant BOM items are exploded in the sales order.
    Order BOM.
    You use this processing type if you want to make customer-specific changes to the BOM of a material that you configure in the sales order. In the sales order, you assign values to the characteristics of the header material, but the BOM is not exploded in the sales order.
    6 Material Variant and Planning Material
    6.1 Material Variant
    · Material Variant is an material that can arises from individual Configuration of a configurable product and can be kept in stock
    · For variants that are required frequently, we can create material variants, which can be produced without a sales order and kept in stock. When a sales order is received, it is possible to check whether the variant required is in stock, so that it can deliver immediately.
    · For material variants, a separate material master record is created with a material type that is kept in stock.
    · Separate BOM and routing for a material variant, or you can link the material variant to the BOM and routing of the configurable material. The correct BOM items and operations are determined from the characteristic values assigned to the variant.
    6.2 Planning Material
    · Planning Material is a material, which contains all the non-variant parts.
    · By using planning material all non-variants are procured / produced before sales order.
    · It is also possible for Planing the Planning Materials without reference to any sales requirement.
    · Planning material is planned separately using strategy 65 and produced before sales order creation.
    7 Planing in VC
    The following strategies are used for planning configurable materials and its variant parts.
    Make to Order production of Variants
    – Make to Order for Material Variant. - 26
    – Planning Variants without final Assembly- 55
    – Planning Variants with planning Material - 65
    – Make to order with configurable material.- 25
    – Characteristic Planning with dependent requirement - 56 and
    – Assembly Processing with Characteristic Planning - 89
    8 Variant Configuration: (Object Diagram)
    9 Variant Pricing and Surcharges
    9.1 Sales BOM
    A bill of material (BOM) describes the different components that together create a product. A BOM for a bicycle, for example, consists of all the parts that make up the bicycle: the frame, the saddle, wheels, and so on.
    When you enter the material number of a bill of materials that is relevant for sales order processing, the system displays the material that describes the whole bill of materials as a main item. The individual components are displayed as lower-level items.
    There are two ways to process a bill of materials in Sales. Once you have entered a bill of material in a sales order, the system runs pricing, inventory control, and delivery processing at: Main item level if the material is assembled, or - Component level if the material is not assembled.
    9.2 Processing at Main Item Level (ERLA)
    If you want the system to carry out pricing, inventory control, and delivery processing at main item level, enter ERLA in the Item category group field of the Sales: sales org. 2 screen in the material master record of the finished product. This means that the components only function as text items and are not relevant for delivery.
    9.3 Processing at Component Level (LUMF)
    If you want the system to carry out pricing, inventory control, and delivery processing at the component level, enter LUMF in the Item category group field of the Sales: sales org. 2 screen in the material master record of the finished product. In this case, only the components are relevant for delivery. During processing the system automatically creates a delivery group. The latest delivery date among all the components becomes the delivery date for the entire delivery group.
    10 Configuration of VC
    10.1 Production Planning and Control
    10.1.1 Creating Material
    Use
    The purpose of this activity is to create the material masters for the materials required in this scenario.
    Procedure
    Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Materials Management ® Material Master ® Material ® Create (General) ® Immediately
    Transaction Code MM01
    In Material Master of KMAT material following settings are maintained:
    · Configurable material indicator in Basic Data must set.
    · MRP type is PD.
    · Lot size – EX ( Lot for lot size)
    · Availability check – 02
    · Planning Strategy 25 is entered in MRP 3 screen view.
    · Item category group 0002 or 0004 is to be given in sales view.
    10.1.2 Creating Bill of Material
    Purpose:
    · The purpose of this activity is to create bills of material (BOMs) for the configurable material which is known as ‘super BOM’
    · Super BOM comprise all the variant as well as non-variant parts required for producing configurable material.
    Procedure
    1. Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Production ® Master Data ® Bills of Material ® Bill of Material ® Material BOM ® Create
    Transaction Code CS01
    · The Create Material BOM: initial screen appears. On this screen, data that identifies the bill of material are maintained as well effectivity data.
    · In the Material field, the configurable material for which super BOM need to create is entered.
    · Plant and BOM usage is entered. In general BOM usage 1 for production and 3 is for Universal.
    · In Component screen list of variant and non-variant parts are entered along with that quantity is entered based on Base qty. of the configurable material.
    · It is also possible to enter a class as a BOM component with item category ‘class Item’. This class must hold all characteristics and also classified with each material.
    · Class type 200 and 300 can be used as a class item.
    Following Procedure is followed for assigning class with BOM as a class Item.
    · Enter the item category for class items in BOM.
    · Make entries in the fields that identify the class
    – Class types
    – Class
    · Enter the quantity.
    - Enter a unit of measure if appropriate.
    - The system determines the unit of measure from the additional data of the class.
    - If a unit of measure without a dimension is maintained in the additional data of the class, you cannot change this unit.
    10.1.3 Creating Characteristic
    Purpose:
    · Characteristic is created with possible values.
    · It is also possible to use table name and its field name in order to change the Object quantity or values. Ie BOM item quantity or Operation time. This is known as ‘Reference characteristic’.
    · For changing BOM quantity Characteristic is created with table name STOP-MENGE is used.
    · For Variant pricing purpose SDCOM-VKOND is used.
    · Characteristics allow describing and distinguishing between objects, such as length, color, or weight within the classification system.
    Procedure
    SAP Menu Logistic->Centralfunction->Environment->classification->Chracteristics
    Transaction Code CT04
    · From the classification menu, choose Characteristics.
    · Enter data on the initial screen.
    · In the Characteristic field, enter a name for new characteristic
    · Enter a change number if you want to create the characteristic using engineering change management.
    · To do this, choose processing type Create characteristic.
    · You can also copy the data of an existing characteristic. Use the pushbutton Create by copying. Enter the name of a characteristic you want to copy.
    · Confirm the entries.
    · On the Basic data tab page enter the most important control data for the characteristic.
    · You must maintain the basic data for all characteristics. All other screens are optional.
    · In the formatting data for value assignment, whether a characteristic is single-value, multiple-value, or retractable is defined. It is not possible change the value assignment indicator once it has set. It applies wherever the characteristic is used.
    · The data type of the characteristic determines which values can be entered for the characteristic. I can any one of the following
    - Characters
    - Numeric
    - Time format/Date format
    - Currency format and
    - User defined data type.
    · For numeric characteristic it need to maintain that whether interval values to a numeric characteristic, or only individual values need to be maintain in Basic Data screen itself.
    · Languages in which characteristic want to describe are entered.
    · Choose the tab page Values.
    · Enter values in the entry fields. Enter each value in a separate field.
    · The values must match the format that you defined on the Basic Data screen. You can enter up to the number of characters that you defined in the format.
    · If your characteristic is an alphanumeric characteristic, enter a language-dependent value description. You can enter up to 30 characters.
    · It is not possible to enter a language-dependent description for numeric values
    · It is also possible to define one value as a default value. This value then appears as a default in characteristic value assignment functions
    · Additional value indicator determines that whether values that are not defined as allowed values can be assigned to a characteristic
    · The following value check strategies are available in value maintenance screen.
    - Allowed Values:
    - Check Tables
    - Function module
    - Catalog character
    · Allowed values permits only values defined in characteristics maintenance are used to check a characteristic value
    · Check table permits only values entered in characteristics maintenance is used to check a value
    · Function module entered is used to check characteristic values.
    · Value catalog entered is used to check characteristic values
    · Documents, such as drawings or photographs, with characteristics can be linked in additional data screen. Before link a document to a characteristic, it must create a document info record in the document management system.
    · In this screen it also possible to restrict or hidden or displaying only allowed values to characteristic.
    · It is possible to that characteristic can be only assigned to particular class type by assigning type in restriction screen.
    · To change a characteristic selects the pushbutton Change in characteristics after entering the characteristic. To display the characteristic chooses the pushbutton Display.
    10.1.4 Creating Class:
    Purpose:
    · A class is used to hold the characteristics that describe a configurable material. By linking the class to the configurable material, you allow the material to be configured using the characteristics of the class.
    Procedure
    SAP Menu Logistic->Central function->Environment->classification->Class
    Transaction Code CL01
    · Class holds all characteristics describe configurable material.
    · Class with class type 300 is used in configuration profile.
    · On basic Data screen class description, its status is entered. Status determines:
    · whether a class can be maintained
    · whether objects can be allocated to a class
    · whether the class can be used for selecting objects
    · Class group is used to group together related classes and also for finding classes quickly via a matchcode.
    · ‘Same Classification ‘indicator determines whether system check for identical characteristic values. In this case, where several objects are assigned that have the same values for all characteristics to the same class. Depends upon indicator system give warning or error message or no message.
    · Keyword string is used for finding a class via matchcode.The description entered on the basic data screen serves as the first keyword
    · On characteristic screen list characteristic which has to attach with configurable material is entered.
    · Using document tab screen it is possible to assign documents related to configurable object.
    · On additional data screen whether or not this class can be used as a class component in bills of material. If it is yes then Unit of measure in which stocks of the material are managed. The system converts all the quantities you enter in other units of measure (alternative units of measure) to the base unit of measure and resulting item category which will replace this class item in BOM (i.e. Stock, Non-stock item etc…).
    10.1.5 Creating Dependency
    Purpose
    Dependency describes the interdependencies between characteristics and characteristic values and it controls which components to be selected from a bill of material (BOM) and which operations to be selected from a task list. It also changes the field values in BOM items and operations during configuration.
    Procedure
    SAP Menu Logistic->Central function->Variant Configuration->dependency->Single Dependency->Create Dependency
    Transaction Code CU01
    · From the variant configuration menu, choose Dependency -> Single dependency-> Create
    · In initial screen name of the dependency is entered. If dependency need to create for a specific date, enter a change number. It is also possible to create dependency by copying from existing dependency.
    · On basic data screen the following data are required to enter
    - A language-dependent description for the dependency
    - Also possible to enter descriptions in different languages by choosing Descriptions.
    - Long texts for the dependency, choose Extras -> Documentation.
    - In the standard R/3 System, the status ‘In preparation’ when a dependency is created first time. The status is set to ‘Released’ when the source code is syntactically correct.
    - Finally suitable dependency type is selected.
    · In Dependency editor the source code for the dependency is entered. Once the source code is syntactically correct, the source code is saved.
    · Now the status of the dependency is turns to ‘Released’. Save the Dependency and exit.
    10.1.6 Changing Bill of Material (Assign Dependencies)
    Purpose:
    By assigning dependencies to BOM components, it is possible to restrict the selection of irrelevant variant parts.i.e correct BOM components are get selected at result of configuration. It is also possible to change the component quantity depends upon characteristic value changed.
    Procedure
    1. Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Production ® Master Data ® Bills of Material ® Bill of Material ® Material BOM ® Change
    Transaction Code CS02
    · Dependencies are assigned with respect to characteristic for each variant part.
    · Dependencies are created either locally within object or globally which can be assigned to any objects.
    · In BOM General Item overview screen choose the component in which dependency need to assign and choose menu path Extras -> Dependency -> assignment of dependency for assignment.
    · It also possible to enter dependency directly in BOM itself by choosing Extras -> Dependency -> dependency editor.
    10.1.7 Creating Configuration Profile
    Purpose
    · Configuration profile used for assigning configurable material with variant class (300) and also used to maintain some central settings.
    · It is possible to assign more than one configurable profile for one KMAT material.
    · The selection of profile depends upon either by priority or by manual selection.
    · It is also possible to assign dependencies to configurable profile.
    · Class with type 300, which hold the entire characteristics of KMAT material, are assigned to each profile
    Procedure:
    Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Production ® Master Data ® Material Master ® Environment ® Configuration Profile ® Create
    Transaction Code CU41
    · From the Variant Configuration menu, choose Configuration profile->Create.
    · A dialog box will be displayed. The object name is entered. Confirm your entries.
    · On profile overview screen the following data need to be entered.
    · Profile name and the class type of classes used for configuration. In Customizing for the Classification System, the class type must be defined as a variant class type.
    · Choose Goto -> Class assignments or the ‘Class assignment ’ pushbutton to assign the object to a class.
    · In the classification screen, names of the classes are entered.
    · It is possible to restrict allowed characteristic values for the configurable object if required.
    · Release of profile is possible only if configurable object is assigned to a class. To go to the detail screen, where you define further settings, choose the Profile detail pushbutton or double-click on the profile.
    10.1.7.1 Optional Settings on the Profile Overview
    · Organizational Areas
    You can specify organizational areas for configuration. If you restrict a profile to specific organizational areas, you only see the characteristics that are relevant to your area when you configure the object.
    You can change how characteristics are displayed according to organizational area for your user on the value assignment screen.
    · Priority of Configuration Profiles
    You can create several configuration profiles for a configurable material. The profile with the lowest number has the highest priority.
    If you define several profiles for an object, you see a dialog box for selecting a profile when you start configuration. The profile with the highest priority is at the top of the list.
    The priority is also relevant if you use Application Link Enabling (ALE) or intermediate documents (IDocs) to run configuration, rather than dialog mode. In this case, the profile with the highest priority is selected for the object. Profiles that have no priority are at the top of the list, because they automatically have priority 0.
    10.1.7.2 Profile Detail
    · Configuration Profiles for Materials
    The configuration profile has several screens. Depending on what you enter for the BOM explosion and configuration process, fields are shown or hidden.
    The parameters you maintain for a material apply to the material as a header material in a BOM structure. You cannot define separate settings for use of a configurable material as an assembly in a BOM.
    - By choosing the Assignments pushbutton, you can assign dependencies to the configuration profile. You also see this pushbutton on the basic data tab, once at least one dependency is assigned.
    · Basic Data Tab
    - In the basic data, click on the profile overview data.
    - If configuration process need to starts with a Start logo, documents are assigned such, as a graphic showing the product you want to configure, to the variant class.
    - Configuration Initial Screen Tab
    · Configuration parameters
    - The parameters for BOM explosion and the configuration process in the sales order are specified here.
    - BOM application must be entered, if BOM explosion ‘None’ is selected rather than single and multi level explosion is selected.
    - By entering a level of detail for a multi-level configuration, system performance will be improved.
    - It is also possible to define a filter and set the indicator for an availability check on assemblies.
    10.1.8 Changing Configuration Profile: Add User Interface Settings
    Purpose
    Settings for the configuration editor in user interface.
    - An interface design is used to group characteristics together on the value assignment screen.
    - Here it also possible to define object-specific settings for functions in the configuration editor. These settings are defaults for configuration, and can be overwritten for your user in the configuration editor.
    - For all configuration parameters except BOM explosion ‘None’, manually select the screens for the configuration editor and define which screen configuration starts with. The start screen must be one of the allowed screens.
    - The indicator for the configuration browser independently of the other start screens can be selected, because the browser is an additional screen section.
    Configuration Profiles for Objects Other than Materials
    - Object-specific settings for displaying characteristics and characteristic values in the configuration editor can be defined. These settings are defaults for configuration, and can be overwritten for your user in the configuration editor.
    Procedure
    Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Production ® Master Data ® Material Master ® Environment ® Configuration Profile ® Change
    Transaction Code CU42
    10.1.9 Configuration Simulation
    Purpose:
    · Configuration simulation is used to check the configuration model. In the configuration simulation, the whether or not Object structure is created correctly and dependencies are working fine is checked.
    · Simulation of Sales/Engineering
    - The configuration parameters in the configuration profile apply. Whether the configuration is simulated from the sales point of view or the engineering point of view is defined.
    - If select Sales & distribution is selected the configuration in a sales document will be simulated (sales order or quotation), so the BOM explosion depends on the settings in the configuration profile.
    - If Engineering is selected, the configuration in order BOM processing will be simulated. The configuration and BOM explosion depend on the configuration parameters in the same way as when maintaining an order BOM. For example, we cannot configure the header material, because the configuration is copied from the sales order.
    · Simulation of a Planned Order
    - On the characteristic value assignment screen, we can choose Planned order to display the components that are determined in material requirements planning (MRP) according to the characteristic values assigned. This is especially relevant to assemblies whose BOMs are exploded in MRP, not in Sales & distribution (for example, assemblies with the BOM explosion setting None in their configuration profile).
    Procedure:
    SAP R/3 menu Logistics ® Production ® Master Data ® Bills of Material ® Environment ® Variant Configuration ® Environment ® Configuration Simulation
    Transaction Code CU50
    · On the initial screen of the configuration simulation, select BOM to display the entire structure on the result screen.
    · If you have created more than one configuration profile for a material, you see a dialog box. Select a profile and choose Continue. If you want to call detailed information on the profile, choose Profile Detail or double-click on the profile.
    · To display the task list of an assembly on the result screen, select the assembly and choose View ® Objects ® Task list.
    · You see the operations or activities in the task list that was selected for the assembly during configuration.
    · Operations that have been changed by dependencies have an information icon next to them. You can display changes by choosing Information.
    · To return to the BOM explosion, choose View ® Objects ® BOM
    10.2 Sales and Distribution
    10.2.1 Creating Condition Records - VA00
    Purpose:
    The purpose of this activity is to create condition records for VA00.
    Procedure
    1. Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Sales and Distribution ® Master Data ® Conditions ® Select Using Condition Type ® Create
    Transaction Code VK11
    · Create price for each value of the characteristics by select using condition type VA00.
    · Create the Price for the condition type that represents these types of the standard-delivered condition type for this functionality is “VA00.”
    · Condition type VA00 requires as key fields the sales Organization, distribution channel, and material number of the configurable.
    · Condition type PR00 used to maintain base price of the configurable material.
    · Using VA01it is also possible to maintain Surcharges and discounts.
    10.2.2 Condition records for Variant Price and Surcharges
    Purpose
    Condition records allow you to store and retrieve pricing data in the system. All the pricing elements of your daily business - the prices, discounts, and surcharges for freight and taxes - that you want to use for automatic pricing must be stored in the system as condition records. You can define as many condition records as you want for the different pricing elements for any validity period.
    You create condition records for all the pricing elements that the system takes into account during automatic pricing. During document processing, the system transfers data from the condition records and determines the amounts for individual pricing elements (prices, discounts and surcharges) and the final amount for the sales document
    Procedure
    10.2.2.1 Create a characteristic for the Pricing
    - Create Pricing characteristic like CAR_Pricing and go to additional data tab give SDCOM table name VKOND field name.
    SAP Menu Logistic->Centralfunction->Environment->classification->Chracteristics
    Transaction Code CT04
    10.2.2.2 Assign the characteristic to the class
    Assign given characteristics to class, In variant configuration, a class is used to hold the characteristics that describe a configurable material. By linking the class to the configurable material, it allows the material to be configured using the characteristics of the class. In the standard R/3 System, the class type for configurable material is 300.
    SAP Menu Logistic->Central function->Environment->classification->Class
    Transaction Code CL01
    10.2.2.3 Create a dependency that triggers the price
    A Dependency is a rule that defines how the different options and option values, represented by characteristics and characteristic values, relate to one another. To create a dependency, follow the menu path
    SAP Menu Logistic->Central_function->VariantConfiguration->dependency->Single Dependency->Create Dependency
    Transaction Code CU01
    10.2.2.4 Assign the dependency to the characteristic value that triggers the price
    For example eCar2002, the value “V8” refers to the engine selected by the customer. Therefore, the dependency must be linked to the value “V8” of the characteristic that represents the engine type. To do this, go to the master data record of the characteristic CAR_ENGINE
    SAP Menu Logistic->Centralfunction->Environment->classification->Chracteristics
    Transaction Code CT04
    Go to the “Values” tab. From there, select the“V8” entry and use the menu path Extras Object dependencies Assignments, which brings you to the screenshot to the right; if you have created a global dependency, you can link it to the characteristic value.2 Once the dependency has been assigned, the information on this screen, such as the description (“Engine price”), will default to the information entered when you created the characteristic.
    10.2.2.5 Create variant price
    Create price for each value of the characteristics using condition type (or transaction VK11). Create the Price for the condition type that represents these types of the standard-delivered condition type for this functionality is “VA00.” Condition type VA00 requires as key fields the sales Organization, distribution channel, and material number of the configurable.
    In the same way using condition type VA01 is also used to maintain prices for surcharges and discounts.
    10.2.2.6 Creating the output condition records for sales
    Output types are used to represent various forms of output in the SAP system. Examples of output types in Sales and Distribution processing are order confirmations, freight lists, and invoices. You use the output type to control how the output should be transmitted, for example whether an order confirmation should be sent via EDI, or be printed
    10.2.3 Creating Output Condition Records: Sales
    Purpose:
    Output types are used to represent various forms of output in the SAP system. Examples of output types in Sales and Distribution processing are order confirmations, freight lists, and invoices. You use the output type to control how the output should be transmitted, for example whether an order confirmation should be sent via EDI, or be printed
    Procedure
    1. Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Sales and Distribution ® Master Data ® Output ® Sales Document ® Create
    Transaction Code VV11
    · Choose Edit >Key combination
    · Select the key combination for which condition records are to be created.
    · Choose Enter.
    · Enter the appropriate key for each condition record, according to the key combination you selected.
    · For transmission medium 1 (Print output) or 7, you can maintain the communication data. To do this, choose Communication.
    · Save the condition records.
    10.2.3.1 Creating Output Condition Records: Billing
    Purpose
    The purpose of this activity is to create output condition records for billing. Output types are used to represent various forms of output in the SAP system. Examples of output types in Sales and Distribution processing are order confirmations, freight lists, and invoices. You use the output type to control how the output should be transmitted, for example whether an order confirmation should be sent via EDI, or be printed
    Procedure
    1. Access the activity using one of the following navigation options:
    SAP Menu Logistics ® Sales and Distribution ® Master Data ® Output ® Billing Document ® Create
    Transaction Code VV31
    Enter an output type.
    · Choose Edit >Key combination
    · Select the key combination for which condition records are to be created.
    · Choose Enter.
    · Enter the appropriate key for each condition record, according to the key combination you selected.
    · For transmission medium 1 (Print output) or 7, you can maintain the communication data. To do this, choose Communication.
    · Save the condition records.
    10.2.4 Order BOM
    Purpose:
    Products that are made to order in plant engineering and construction and mechanical engineering are generally very complex and are specific to one customer. For this reason, you cannot define a BOM entirely in advance. Once you have created your sales order, you need to make manual changes to the BOM by creating an order BOM especially for the sales order, without changing the original BOM.
    The sales order, sales order item, and material number identify an order BOM. In variant configuration, you can work with 2 types of order BOM. The difference is in the way they are saved.
    Knowledge based order BOM
    The order BOM is saved as a copy of the super BOM with manual changes and dependencies.
    Result Oriented BOM
    The configuration result is saved as an order BOM, with manual changes but without dependencies.
    Procedure (For knowledge based BOM)
    SAP Menu Logistics ® Production Planning ® Master Data ® Bills of Material -> Order BOM Maintain (Multi-Level)Transaction Code CU51
    · The Create Order BOM: initial screen appears.
    · Enter the sales order number, the order item, the material number and the BOM usage
    · If you want to use material BOM, or an existing order BOM to copy from, go to step 4. If you want to create an order BOM without a reference, click and go to step 7
    · You cannot use a configurable BOM as a reference
    · Click on copy order BOM or Click on copy material BOM
    · The Copy material BOM or Copy order BOM dialog box appears
    · Enter the data required and click . The item overview appears, for the bill of material you are using as a reference.
    · Enter new items and alter items if necessary. Entering items in order BOMs is similar to entering items in material BOMs. However, you
    Create a Material - KMAT type with Item category (002)
    Create Characteristics in CT04 - Zbike, where in values mention the Color of the bile like Red, Blue etc
    Create another characteristics in CT04 - ZPrice, where directly go the additional data tab and maintain the table SDCOM and field VKOND (ABAP Dictionary it will ask for)
    Assign these two characteristics to a Class in CL01 – Zbike class (Type 300) in characteristics tab page.
    Then go to CU41 Configuration profile select the material and enter the description click on the class assignment ie assign Zbikclass.
    Now go back to CT04 - enter Zbike -go to values- select Red- go to extras - Other Dependencies - Select Procedure enter in front 10 write - $self.ZPrice='Red' and save
    Now go back go to extras - Other Dependencies - assignments and assign relationship ( by default it will come just save)
    Now select Blue- go to extras - Other Dependencies - Editor - Select Procedure enter in front of 10 write - $self. ZPrice='Blue' and save
    Now go back go to extras - Other Dependencies - assignments and assign relationship ( by default it will come just save)
    Now go to VK11 - Enter VA00 (Condition)(For Std RVA001 Pricing Procedure) - enter variant Red and Blue give the rates accordingly and create the sales order.

  • Saving NSDatePicker to a string and saving that to NSUserDefaults...

    Saving NSDatePicker to a string and saving that to NSUserDefaults I have it saved to a string then I have code that should save it to NSUSerDefaults so that when the program starts it is saved as the string not null. Here is the code [CODE]#import "MainView.h"
    #import "DateView.h"
    @implementation MainView
    -(void)awakeFromNib
    [self removeFromSuperview];
    [self addSubview:dateView];
    [dateView setdateandtime];
    [dateView permsavedattime];
    @end [/CODE] [CODE]#import "DateView.h"
    #include "MainView.h"//Use #import this is to see if #include Works
    @implementation DateView
    -(IBAction)showuserdefaultdate
    [self userdefaultdate];
    //dateoutput.text =tddate;
    -(void)permsavedattime
    tddate=[prefs stringForKey:@"testing"];
    tdtime=[prefs stringForKey:@"timetesting"];
    dateoutput.text =[[NSString alloc] initWithFormat:@"%@",tddate];
    -(void)userdefaultdate
    prefs =[NSUserDefaults standardUserDefaults];
    [prefs setInteger:tddate forKey:@"testing"];
    [prefs setObject:tdtime forKey:@"timetesting"];
    -(void)setdateandtime
    [Today setDate:[NSDate date] animated:YES];
    //formatting date style
    dateformatter = [ [ NSDateFormatter alloc ] init ];
    [ dateformatter setDateStyle:NSDateFormatterLongStyle];
    [ dateformatter setTimeStyle:NSDateFormatterNoStyle ];//makes it so the time is not included
    //[ formatter setTimeStyle:NSDateFormatterLongStyle ];//set to anystyle besides
    //NoStyle if you dont want time included.
    [Time setDate:[NSDate date] animated:YES];
    //formatting date style
    timeformatter = [ [ NSDateFormatter alloc ] init ];
    [ timeformatter setDateStyle:NSDateFormatterNoStyle];//makes it so it doesn't get the date
    [ timeformatter setTimeStyle:NSDateFormatterShortStyle];//makes it so the time is just hour and minute and A.M. or P.M.
    //[ formatter setTimeStyle:NSDateFormatterLongStyle ];//set to anystyle besides
    //NoStyle if you dont want time included.
    -(IBAction)recieveDate
    tddate= [dateformatter stringFromDate:Today.date];//Asigning the date to the string
    dateoutput.text =tddate;
    -(IBAction)recievetime
    tdtime= [timeformatter stringFromDate:Time.date];//Asigning the date to the string
    timeoutput.text =tdtime;
    -(IBAction)canceltime
    [Time setDate:[NSDate date] animated:YES];
    tdtime= [timeformatter stringFromDate:Time.date];//Asigning the date to the string
    timeoutput.text =tdtime;
    -(IBAction)canceldate
    [Today setDate:[NSDate date] animated:YES];
    tddate= [dateformatter stringFromDate:Today.date];//Asigning the date to the string
    dateoutput.text =tddate;
    @end[/CODE] What am I missing? It keeps coming up Null I need it saved right so I can send it through email

    softwarespecial wrote:
    why can't I have the prefs saved in the .h
    You can save that address in an ivar if you want to, but there's no purpose to that. The standardUserDefaults object is a +shared class object+. It's like a dictionary object that's maintained for your program by the NSUserPreferences class. You can read from or write to it at any time for the duration of your program. So whenever you get the shared object's address [NSUserDefaults standardUserDefaults], you're just getting the address of that same object each time.
    In case the above doesn't make sense, I ran across a good explanation by Danneman in the last message on this page: [http://www.iphonedevsdk.com/forum/iphone-sdk-development/18716-set-settings-va riable-code.html].
    When I did that as you so wisely pointed out it didn't work but when I saved it at each point I needed it it works.
    When you change two things at once it's easy to forget the first and assume the second change solved the problem. Actually, I don't think saving prefs in your ivar had anything to do with your bug. What fixed it was getting a pointer to the shared std defaults object in this method:
    -(void)permsavedattime
    NSUserDefaults *prefs = [NSUserDefaults standardUserDefaults]; <-- get the shared object
    tddate=[prefs stringForKey:@"testing"];
    tdtime=[prefs stringForKey:@"timetesting"];
    dateoutput.text =[[NSString alloc] initWithFormat:@"%@",tddate];
    Without the first line of the above, I'm fairly sure that your prefs ivar was nil. I didn't see any code that initialized that ivar prior to the first time userdefaultdate ran. It looked to me like permsavedattime ran at start up, well before prefs was set in userdefaultdate. If you're interested in backtracking, restore the file to the way it was when you posted, then add a NSLog() like this:
    -(void)permsavedattime
    // NSUserDefaults *prefs = [NSUserDefaults standardUserDefaults]; <-- get the shared object
    NSLog(@"prefs=%@", prefs);
    tddate=[prefs stringForKey:@"testing"];
    tdtime=[prefs stringForKey:@"timetesting"];
    dateoutput.text =[[NSString alloc] initWithFormat:@"%@",tddate];
    I wish to save lets say five different things to NSUSerDefaults would I be able to do it all with my NSUserDefaults prefs or would I have to create a another one for some of them?
    You know the answer to your second question now, right? The important point is that you're never creating the shared object, you're just asking for its address whenever you need it.
    Btw, there's another user defaults method you should know about: The synchronize method writes the data to disk. You might want to do that when your app is ready to exit. E.g., in the app delegate:
    - (void)applicationWillTerminate:(UIApplication *)application {
    NSUserDefaults *prefs = [NSUserDefaults standardUserDefaults];
    [prefs synchronize];
    Although the docs suggest synchronize when the app is about to exit, I'm not sure it's necessary. I think the system might write the defaults out to disk anyway when the app terminates, but not sure about this. +User Defaults Programming Topics for Cocoa+ says:
    On Mac OS X v10.5 and later, in applications in which a run-loop is present, synchronize is automatically invoked at periodic intervals. Consequently, you might synchronize before exiting a process, but otherwise you shouldn’t need to.
    The above is in the iPhone edition, so I think it applies.
    It might also be a good idea to update the data and call resetStandardUserDefaults in didReceiveMemoryWarning. I'm not clear about the need for reset either though, since the system may do that for you as well. But on a memory warning, you would definitely want to update the user default data if some of it is stored in an object to be released. You can find out how your app behaves on a memory warning by selecting Hardware->Simulate Memory Warning from the iPhone Simulator menu.
    - Ray

  • I am making code to try to make a game and my problem is that my code......

    I am making code to try to make a game and my problem is that my code
    will not let it change the hit everytime so im getting the first guy to hit 1 then next hits 8 and so on and always repeats.
    Another problem is that I would like it to attack with out me telling it how much times to attack. I am using Object oriented programming.
    Here is the code for my objects:
    import java.lang.*;
    import java.io.*;
    import java.net.*;
    import java.util.*;
    import java.util.Random;
    import static java.lang.Math.*;
    import java.awt.*;
    import java.awt.color.*;
    class rockCrab {
         //Wounding formula
         double sL = 70;                                   // my Strength Level
         double bP = 1;                                   // bonus for prayer (is 1 times prayer bonus)
         double aB = 0;                                 // equipment stats
         double eS = (sL * bP) + 3;                         // effective strength
         double bD = floor(1.3 + (eS/10) + (aB/80) + ((eS*aB)/640));     // my base damage
         //Attack formula
         double aL = 50;                                   // my Attack Level
         double eD = 1;                                   // enemy's Defence
         double eA = aL / eD;                              // effective Attack
         double eB = 0;                                   // equipment bonus'
         double bA = ((eA/10) * (eB/10));                    // base attack
         //The hit formula
         double fA = random() * bA;
         double fH = random() * bD;
         double done = rint(fH - fA);
         //health formula
         double health = floor(10 + sL/10 * aL/10);
         rockCrab() {
         void attack() {
              health = floor(10 + sL/10 * aL/10);
              double done = rint(fH - fA);
              fA = random() * bA;
              fH = random() * bD;
              done = rint(fH - fA);
              System.out.println("Rockcrab hit" +done);
    import java.lang.*;
    import java.io.*;
    import java.net.*;
    import java.util.*;
    import java.util.Random;
    import static java.lang.Math.*;
    import java.awt.*;
    import java.awt.color.*;
    class self {
         //Wounding formula
         double sL = 1;                                   // my Strength Level
         double bP = 1;                                   // bonus for prayer (is 1 times prayer bonus)
         double aB = 0;                                 // equipment stats
         double eS = (sL * bP) + 3;                         // effective strength
         double bD = floor(1.3 + (eS/10) + (aB/80) + ((eS*aB)/640));     // my base damage
         //Attack formula
         double aL = 1;                                   // my Attack Level
         double eD = 1;                                   // enemy's Defence
         double eA = aL / eD;                              // effective Attack
         double eB = 0;                                   // equipment bonus'
         double bA = ((eA/10) * (eB/10));                    // base attack
         //The hit formula
         double fA = random() * bA;
         double fH = random() * bD;
         double done = rint(fH - fA);
         //health formula
         double health = floor(10 + sL/10 * aL/10);
         self() {
         void attack() {
              health = floor(10 + sL/10 * aL/10);
              fA = random() * bA;
              fH = random() * bD;
              done = rint(fH - fA);
              System.out.println("You hit" +done);
    }Here is the main code that writes what the objects do:
    class fight {
         public static void main(String[] args) {
              self instance1 = new self();
              rockCrab instance2 = new rockCrab();
              instance2.health = instance2.health - instance1.done;
              System.out.println("You hit: " +instance1.done);
              System.out.println("rockCrabs health: " + instance2.health);
              instance1.health = instance1.health - instance2.done;
              System.out.println("RockCrab hit: " +instance2.done);
              System.out.println("rockCrabs health: " + instance1.health);
              instance2.health = instance2.health - instance1.done;
              System.out.println("You hit: " +instance1.done);
              System.out.println("rockCrabs health: " + instance2.health);
              instance1.health = instance1.health - instance2.done;
              System.out.println("RockCrab hit: " +instance2.done);
              System.out.println("rockCrabs health: " + instance1.health);
              instance2.health = instance2.health - instance1.done;
              System.out.println("You hit: " +instance1.done);
              System.out.println("rockCrabs health: " + instance2.health);
              instance1.health = instance1.health - instance2.done;
              System.out.println("RockCrab hit: " +instance2.done);
              System.out.println("rockCrabs health: " + instance1.health);
              instance2.health = instance2.health - instance1.done;
              System.out.println("You hit: " +instance1.done);
              System.out.println("rockCrabs health: " + instance2.health);
              instance1.health = instance1.health - instance2.done;
              System.out.println("RockCrab hit: " +instance2.done);
              System.out.println("rockCrabs health: " + instance1.health);
    }when the code is run it says something like this:
    you hit 1
    RockCrabs health is 9
    RockCrab hit 7
    your health is 38
    you hit 1
    RockCrabs health is 8
    RockCrab hit 7
    your health is 31
    you hit 1
    RockCrabs health is 7
    RockCrab hit 7
    your health is 24
    you hit 1
    RockCrabs health is 6
    RockCrab hit 7
    your health is 17
    my point is whatever some one hits it always repeats that
    my expected output would have to be something like
    you hit 1
    RockCrabs health is 9
    RockCrab hit 9
    your health is 37
    you hit 3
    RockCrabs health is 6
    RockCrab hit 4
    your health is 33
    you hit 2
    RockCrabs health is 4
    RockCrab hit 7
    your health is 26
    you hit 3
    RockCrabs health is 1
    RockCrab hit 6
    your health is 20
    Edited by: rade134 on Jun 4, 2009 10:58 AM

    [_Crosspost_|http://forums.sun.com/thread.jspa?threadID=5390217] I'm locking.

  • Can I call a function from a dll in LabVIEW that returns:double*string and int.?

    I have a function from a dll that return a double* string and an integer. How can I call this function from LabVIEW? There is a possibility to work in LabVIEW with a double* string?

    pcbv wrote:
    > Hello all,<br><br>The header of the function is:
    >
    > "HRESULT WRAPIEnumerateDevices(WRAPI_NDIS_DEVICE **ppDeviceList, long *plItems);"
    >
    > where WRAPI_NDIS_DEVICE have this form:
    >
    > typedef struct WRAPI_NDIS_DEVICE<br>{<br>
    > WCHAR *pDeviceName;<br>
    > WCHAR *pDeviceDescription;<br><br>}
    > WRAPI_NDIS_DEVICE;<br><br>
    >
    > The function is from WRAPI.dll, used for communication with wireless card.
    > For my application I need to call in LabVIEW this function.
    Two difficulties I can see with this.
    First the application seems to allocate the array of references
    internally and return a pointer to that array. In that case there must
    be another function which then deallocates that array again.
    Then you would need to setup the function call to have a pointer to an
    int32 number for the deviceList parameter and another pointer to int32
    one for the plItems parameter.
    Then create another function in your DLL similar to this:
    HRESULT WRAPIEnumExtractDevice(WRAPI_NDIS_DEVICE *lpDeviceList, long i,
    CHAR lpszDeviceName, LONG lenDeviceName,
    CHAR lpszDeviceDesc, LONG lenDeviceDesc)
    if (!lpDeviceList)
    return ERROR_INV_PARAMETER;
    if (lpDeviceList[i].pDeviceName)
    WideCharToMultiByte(CP_ACP, 0,
    pDeviceList[i].pDeviceName, -1,
    lpszDeviceName, lenDeviceName,
    NULL, NULL);
    if (lpDeviceList[i].pDeviceName)
    WideCharToMultiByte(CP_ACP, 0,
    pDeviceList[i].pDeviceDescription, -1,
    lpszDeviceDesc, lenDeviceDesc,
    NULL, NULL);
    return NO_ERROR;
    Pass the int32 you got from the first parameter of the previous call as
    a simple int32 passed by value to this function (and make sure you don't
    call this function with a higher index than (plItems - 1) returned from
    the first function.
    Rolf Kalbermatter
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Strange problem in converting between XML to string and vice versa

    i have an application that needs to send an XML document
    over the wire. For this reason, I need to convert the
    doc into a String at the sending side and back to Doc
    at the receiving side. This document is stored in a "CLOB"
    column in a table in the database. I use XDK to retrieve
    this entire row (including the CLOB - hence this is an XML
    document which has a column that itself is an xml document in
    string format - this is just the clob read in by XDK).
    Thus the row looks like
    <ROWSET>
    <ROW>
    <col1> A <col1>
    <CLOB_COL> ..clob value of an xml doc..</CLOB_COL>
    </ROW>
    </ROWSET>
    When I convert this document into String and back, one of the "<"
    tags in the clob column document gets changed to "&lt;" and hence
    the parsing fails! I have used the latest label of the XDK build
    to get the latest parser jar but still i have the same problem.
    I am using the following routines for the conversion.
    /* for converting document to string */
    public static String convertToString(XMLDocument xml) throws
    IOException
    StringWriter sw = new StringWriter();
    PrintWriter pw = new PrintWriter(sw);
    xml.print(pw);
    String result = sw.toString();
    return result;
    /* for converting string to document */
    public static XMLDocument convertToXml(String xmlStr)
    throws
    IOException,SAXException
    ByteArrayInputStream inStream = new
    ByteArrayInputStream(xmlStr.getBytes());
    DOMParser parser = new DOMParser();
    parser.setPreserveWhitespace(false);
    parser.parse(inStream);
    return parser.getDocument();

    How do you get the XML document? Do you use XSU? You can use:
    String str = qry.getXMLString();
    to get the result XML document in String.
    XSU will escape all of the < and >. Or the the XML document in
    one of the column will make the result XML doc not well-formed.
    Not quite understand your problem. You can send me your test
    case.
    i have an application that needs to send an XML document
    over the wire. For this reason, I need to convert the
    doc into a String at the sending side and back to Doc
    at the receiving side. This document is stored in a "CLOB"
    column in a table in the database. I use XDK to retrieve
    this entire row (including the CLOB - hence this is an XML
    document which has a column that itself is an xml document in
    string format - this is just the clob read in by XDK).
    Thus the row looks like
    <ROWSET>
    <ROW>
    <col1> A <col1>
    <CLOB_COL> ..clob value of an xml doc..</CLOB_COL>
    </ROW>
    </ROWSET>
    When I convert this document into String and back, one of the "<"
    tags in the clob column document gets changed to "<" and hence
    the parsing fails! I have used the latest label of the XDK build
    to get the latest parser jar but still i have the same problem.
    I am using the following routines for the conversion.
    /* for converting document to string */
    public static String convertToString(XMLDocument xml) throws
    IOException
    StringWriter sw = new StringWriter();
    PrintWriter pw = new PrintWriter(sw);
    xml.print(pw);
    String result = sw.toString();
    return result;
    /* for converting string to document */
    public static XMLDocument convertToXml(String xmlStr)
    throws
    IOException,SAXException
    ByteArrayInputStream inStream = new
    ByteArrayInputStream(xmlStr.getBytes());
    DOMParser parser = new DOMParser();
    parser.setPreserveWhitespace(false);
    parser.parse(inStream);
    return parser.getDocument();

  • How to  make JTextArea rows and colums auto-increase?

    My test program is attached as below.
    The JTextArea can not enlarge itself when the text in a line is too long that some characters are hidden.When rows grows too many will also see the problem.
    How can I make the rows and columns auto-increase to meet the width or height of my text?
    -----My Test Demo----
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.color.*;
    import javax.swing.*;
    public class Test{
    public static void main(String[] args){
    JFrame f = new JFrame("My Editor");
    Container ct = f.getContentPane();
    JPanel jp = new JPanel();
    JTextArea ta = new JTextArea("My software.",10,30);
    JTextArea ta2 = new JTextArea("Hello,World!",10,30);
    jp.setPreferredSize(new Dimension(400,400));
    jp.setBackground(Color.green);
    jp.setLayout(null);
    jp.add(ta);
    ta.setBounds(100,100,150,200);
    ta.setOpaque(false);
    ta.setBorder(null);
    jp.add(ta2);
    ta2.setBounds(100,120,150,200);
    ta2.setOpaque(false);
    ta2.setBorder(null);
    // jp.addMouseListener(new MyMouseListener());
    ct.setLayout(new BorderLayout());
    ct.add(jp,BorderLayout.CENTER);
    f.addWindowListener(new WindowAdapter() {
    public void windowClosing(WindowEvent evt) {
    System.exit(0);
    f.setVisible(true);
    f.pack();

    This link to the Java Swing tutorial will show you how to add the JTextArea to a JScrollPane:
    http://java.sun.com/docs/books/tutorial/uiswing/components/simpletext.html#textarea
    It appears to me that you are new to Swing so you should read the entire tutorial "Creating a GUI using JFC/Swing" before asking any more question. The tutorial can be read online or downloaded from:
    http://java.sun.com/docs/books/tutorial/
    The download link for all tutorials on this page is near the bottom.

  • Anyone know how to add a string to a 1d array with file info, then be able to read back, display string, and sort data array.

    I need to store a data array and include text that describes what the data is. (using for various configuration files.) Anyway, I would like to be able to save the string as part of the txt file, and somehow read it back, remove the (various length string), and display it in an indicator. All the while, not causing too much problem with the initial data array.
    Thanks in advance!!

    There are several ways to do what you require. A simple method would be to use an ASCII text file. When writing one of those, you just need to basically build a gaint string starting with the description text you want. We like to call that a header. Once you've got the header, make some sort of delimiter like a bunch of "-" or two sets of ( EOL = End of Line = CRLF = \r\n ). After your delimiter, concatenate your array in string form or flatten your array from its native form into a string and tack it on the file (append).
    See the (very quick) example attached.
    Dan Press
    www.primetest.com
    Attachments:
    fileheader.vi ‏41 KB

  • I want to convert two image files into strings and than to compare them. This is easy, but how to mention where the difference exist?

    I have two image file in bmp file format. How to convert them into string and to check if they are differnt or same. If different how to mention or find that where the difference exists. This idea have to be extented with video application as well.

    Hi,
    if you have vision, you could use the functin IMAQ Image to Array to have a 2D array of the pixel values.
    You can then compare pixel by pixel; if your images come from a camera, I would recommend to set a treshold of acceptance.
    This is a time consuming solution anyway.
    Alternative methods:
    1) Make a subtraction of the two images, the resulting image will be the difference of them
    2 ) Use IMAQ LogDiff function (operators palette)
    3) Calculate the histogram of both image and compare the histogram reports
    Good luck,
    Alberto

  • How to make changes in company code global data

    Hi folks,
    Can some one suggest me how to make changes in company code global data (t code oby6). I want to assign 1 to co code > co Area which is blank.
    Thanks in advance

    Hi,
      actually if you want to change co code > co Area , it is under controlling (maintain controlling area), transaction code  OX06 .You change the assignment control and save it. It is automatic update you COmpany code global data.
    *give me a point if my answer solve your problem.
    Thank You.
    -akma-

  • Search for string and move decimal

    Hello,
    I am trying to write code that will search for a fractional string within an array and convert it from mV to V so it can be properly compared to the other fractional string numbers in the array.
    I have an array that outputs x iterations  each with a minimum and maximum column including several different types of decimal strings (negative/positive with several decimal places) each ending with either mV and V (example string: -725.543mV).
    I then split the array into columns containing the minumum and maximum values of each iteration. I want to compare the minimum values of each iteration and find the most minimum, and do the same thing with the maximum values.
    Unfortunatley the way I'm doing it, when I convert from fractional string to number it removes the V or mV unit label but does not convert the number from mV to V. so it compares -725.543mV with -52.334V as -725.543 & -52.334 thus declaring the mV value the most minimum. I need the program to recognize that mV is less than V or search each array for values labeled with mV and move the decimal place so it is in standard V format.
    The unit label is actually part of the string and not the display (as you can see in the code I've attached) and I understand this is a little tricky with the way I have to do it. But this is a dumbed down chunk of code I will eventually incorporate into my larger program which reads the values and their units from several different types of oscilloscopes. The Scopes output the values as strings as they appear on the screen and don't differentiate between mV and V unless they are told to output the units which just tags them on the end of the string.
    I'm sorry for the large post. SO to sum up I need to search an array to make sure all values have the same units, if they don't I need to convert each value to the proper unit and output the max and min from the resulting array. my code is attached. Thank you for your help.
    Solved!
    Go to Solution.
    Attachments:
    File manipulation.vi ‏15 KB

    crossrulz wrote:
    jcarmody wrote:
    camerond wrote:
    Sorry, Jim, that's not quite right. You forgot to consider significant figures (your third min is not quite right). [...]
    Good catch, but, really?   
    That "Finally!" comes out to -5569492V to me.  Holy crap.  -5.569492MV!  I think there's a problem there.
    Carp! Stupid negative numbers, shouldn't be allowed. Put a piece of duck tape over the place for that negative sign, that'll fix it.
    I'll get back, it's now a matter of principle.
    Jim, how does your algorithm do when there are 8 or 9 sig figs, say -56.9492345mV? (Yep, too lazy to draw it in myself.)
    Cameron
    To err is human, but to really foul it up requires a computer.
    The optimist believes we are in the best of all possible worlds - the pessimist fears this is true.
    Profanity is the one language all programmers know best.
    An expert is someone who has made all the possible mistakes.
    To learn something about LabVIEW at no extra cost, work the online LabVIEW tutorial(s):
    LabVIEW Unit 1 - Getting Started
    Learn to Use LabVIEW with MyDAQ

  • VISA READ STRING and GRAPH

    I have some basic questions:
    1. I have Serial communication from PXI to device. When I read the string of 26characters, continously, on Hypertermianl. It is fast enough. But when I read in the VI program, simple VISA read.
    The reading is very slow. The VISA read one character at a time and take time to make a string of 26characters. Visa read is very slow, Why?
    The baud rate is 1152K and rate is 32 updates per second, which is super fast in hyperterminal but very slow in Labview VI.
    2. Second I  need the extract the some data from my string at different positions on a string of 26 characters. I already made the subVI for reading it but since the VISA read is slow to read it gives wrong values from the string.
    So I thought I can make an array and ask the subvi to read the the second (i.e n-1 value) 26 characters which are ready rather than first one which is being formed. But there is no arrays for string.How can I do that? also my concern is if I read n-1 value, it is not real time value.
    :8 -0582                                n value Visa read slowly
    :000000 -0076U 0008 -0582   n-1 value
    :000000 -0074U 0008 -0582  n-2 value
    :000000 -0075U 0008 -0582  n-3 value
    3. I will extract the 74, 76, 77 etc say the value as AA. I want to plot the graph of value AA versus Seconds? How can generate Seconds on my X-axis?
    Attachments:
    TSS1-porem-final4.vi ‏16 KB

    Thank you for suggestion!
    Now I am receiving data continuosly.
    1. As mentioned previously, I wish to plot the heave value on real time basis, I saw the shipping example, modified my VI.
    The plot is not correct, as the heave value increases and decreases linearly but there is strange graph.
    2. Also I have one more question, actually if I want to find out the heave value, device once moved up 10cm and brought back to 0 level again. Its not instant as the design of the device says it takes 2 secs to get back to the zero state again. The heave is read from 10, 9, 8,7 6, 5, etc. It takes 10 steps to come back to normal value, zero value.
    I just need to plot the 0 and 10cm or may be  next might be -5cm, I need to capture the final data. How can i do that?
    Attachments:
    TSS1-porem-final4-1.vi ‏16 KB
    MRU-TEST3-1.vi ‏20 KB

  • Creating JVM to Make JNI calls

    I am trying to create a JVM to make JNI calls to Java. When I try to link my C++ program with jvm.lib, I am getting following error. Please advise.
    "fatal error LNK1106: invalid file or disk full"
    I am sure the disk is not full.

    What IDE are you using? I am using MS VC++ 5.0 with jdk 1.3 and I got the same error. After trying several things (including recreating my project)I realized that jdk 1.3 was created after VC++ 5.0. So on a wild hunch I installed jdk 1.2.2. I then removed all project referrences to jdk 1.3. Closed all my files. Reopend them. Made sure the jni.h external dependency was pointing to 1.2.2 (you may have to do a build to force it) and then everything linked fine.

  • Please simplify - doubt in String and StringBuffer

    in output of StringTest1 StringBuffer take more time than String concatenation using + operator.
    and in output of StringTest2 String concatenation using + operator take more time than StringBuffer
    please simplify..
    public class StringTest1 {
    public static void main(String[] args){
               //Test the String Concatination
              long startTime = System.currentTimeMillis();
              for(int i=0;i<5000;i++){
              String result = "This is"+ "testing the"+ "difference"+ "between"+
                                    "String"+ "and"+ "StringBuffer";
              long endTime = System.currentTimeMillis();
              System.out.println("Time taken for string concatenation using + operator : "
                                              + (endTime - startTime)+ " milli seconds");
               //Test the StringBuffer Concatination
               long startTime1 = System.currentTimeMillis();
               for(int i=0;i<5000;i++){
              StringBuffer result = new StringBuffer();
                                 result.append("This is");
                                result.append("testing the");
                                result.append("difference");
                                result.append("between");
                               result.append("String");
                               result.append("and");
                               result.append("StringBuffer");
              long endTime1 = System.currentTimeMillis();
              System.out.println("Time taken for String concatenation using StringBuffer : "
                                                 + (endTime1 - startTime1)+ " milli seconds");
    }output:
    Time taken for String concatenation using + operator : 0 milli seconds
    Time taken for String concatenation using StringBuffer : 15 milli seconds
    public class StringTest2 {
    public static void main(String[] args){
              //Test the String Concatenation using + operator
              long startTime = System.currentTimeMillis();
              String result = "hello";
              for(int i=0;i<1500;i++){
              result += "hello";
              long endTime = System.currentTimeMillis();
              System.out.println("Time taken for string concatenation using + operator : "
                                              + (endTime - startTime)+ " milli seconds");
              //Test the String Concatenation using StringBuffer
              long startTime1 = System.currentTimeMillis();
              StringBuffer result1 = new StringBuffer("hello");
              for(int i=0;i<1500;i++){
              result1.append("hello");
              long endTime1 = System.currentTimeMillis();
              System.out.println("Time taken for string concatenation using StringBuffer :  "
                                              + (endTime1 - startTime1)+ " milli seconds");
    }output:
    Time taken for string concatenation using + operator : 63 milli seconds
    Time taken for String concatenation using StringBuffer : 0 milli seconds

    As jverd said - in the first class, your String concat is only done once. Add/replace this code to your original and see what you get"
    {code} String results = "This is"+ "testing the"+ "difference"+ "between"+
    "String"+ "and"+ "StringBuffer";
    Object o = results;
    for(int i=0;i<500000;i++){
    results = "This is"+ "testing the"+ "difference"+ "between"+
    "String"+ "and"+ "StringBuffer";
    if (i < 10 ) System.out.println("same result: "+(o == results));
    }{code}
    Now made just one change ( appending +i to that String each time ) as follows:
    {code} String results = "This is"+ "testing the"+ "difference"+ "between"+
    "String"+ "and"+ "StringBuffer";
    Object o = results;
    for(int i=0;i<500000;i++){
    results = "This is"+ "testing the"+ "difference"+ "between"+
    "String"+ "and"+ "StringBuffer"+i;
    if (i < 10 ) System.out.println("same result: "+(o == results));
    {code}
    Then, also in the first class, create your StringBuffer BEFORE the loop and "delete(0,result.length());" within the loop. This speeds it up and makes for a better comparison.
    Next, increase your loop size to something that will produce more consistent results (I used half a million).
    Lastly (or approximately so, at least) change the first part of your first class - using String - to the following:
    {code} results = "This is";
    results += "testing the";
    results += "difference";
    results += "between";
    results += "String";
    results += "and";
    results += "StringBuffer";
    results += i;
    {code}
    Now you have a more legitimate comparison and you will see a real difference.

  • Creating value expression​s dynamicall​y with strings and numbers?

    Hello everybody!
    I'm having a problem regarding passing arguments (DLL-Adapter) from different locations to a function in TestStand 3.5.
    Here is what I have:
    FileGlobals.Data.MyArray
    and
    StationGlobals.Data.MyArray
    Which means there are 2 arrays of the same type, one stored in the sequence and one globally. "Data" is just a container.
    The type of MyArray is a custom one each element containing a string and a number: Array[n].Name and Array[n].Nr
    Now I want to pass (string) arguments of the array to a function using a value expression of: FileGlobals.Data.MyArray[Step.index].Name
    Whereas Step.index is a local property (number) of a custom step. It's working well!
    Here is the actual problem:
    Since I have to sources, FileGlobals OR StationGlobals, I want to specify dynamically which string to pass.
    Therefore I introduced a property Step.ThisIsMyScope . It's a string containing either "FileGlobals" or "StationGlobals".
    I have been experimenting in expressions like
    Step.ThisIsMyScope + ".Data.MyArray[" + Step.index + "].Name"
    or Evaluate(...) , etc.
    Nothing worked.
    I do not want to use the API, though I managed to do things with getValString and temporary saving the Value in the step, but that's not nice nor transparent enough.
    May anyone help me?
    Thank you very much,
    Stefan

    Hi,
    have you tried Evaluate(Step.ThisIsMyScope + ".Data.MyArray[" + Step.index + "].Name")
    or
    (Step.ThisIsMyScope == "FileGlobals"  )  ?  (FileGlobals.Data.MyArray[ Step.index].Name)  :  (StationsGlobals.Data.MyArray[ Step.index].Name)
    Regards
    Ray Farmer
    Message Edited by Ray Farmer on 04-05-2007 10:09 AM
    Regards
    Ray Farmer

Maybe you are looking for

  • Final Cut Pro X Opens But Doesn't Respond

    I am running FCPX 10.0.9 on OS X Mavericks (10.9). FCPX worked without issue on my computer and it was running Mavericks. Now, out of the blue, it will open but not respond. Once the loading screen goes away, nothing happens. FCPX is not responding a

  • Report to view Vendor name & VAT Registration no's

    HI All... I need to find out a report that only display vendor account, vendor name & VAT reg no. All these data can be captured through S_ALR_87012086 - Vendor List. But I only need to display the above mentioned fields in the report. Pls help me to

  • Empty response HWC

    Hi, We are working on HWC application with rest webservices MBO approach. Getting empty response in hdc.processDataMessage hwc.processDataMessage = function (incomingDataMessageValue) {   alert(JSON.stringify(incomingDataMessageValue)+"in process dat

  • FCP 6 : LOST MANUAL. Where can i find it?

    Hi all. I incredibly LOST my original FCP 6 user's manual vol 3 about audio and effects. I'm desperate because now i have the box incomplete. Where can i buy it? and in the meantime where can i download the pdf version? thanx

  • My super simple ip checking script

    i have a small home network with a PC running arch that acts as a NAT router; in the near future i am planning on setting up VPN access on this arch box. i would assume that it is imperative to know the external IP address of the router in order to c