Configurable calculator string?
Hi,
In my application some data is measured and for every sequence of the application,
I calculate all statistical parameters (max, min, avg) of all signals.
So I have a lot of mathematical values about my test.
e.g. math. value 1, math value 2, math value 3, ... math value n.
Then the different users (over different sites) of this application want to evaluate this
test in their specific way. This means that they all have the list of all mathematical
parameters to start from, but they want to configure their end-result themselves.
e.g.
result A = (math value 1 + math value 2) / math value 3
result B = math value 4 * 100 - math value 1
I want to make such an editor in the application, so that the users can build the strings
like I entered above. I don't want these calculator strings hard-coded in the app,
but the user must be able to configure them.
Then after the test, I have to calculate first the mathematical values, and then I can
parse the formula strings with the actual data. Then I get :
Result A : (4 + 6)/ 2
Result B : 84*100 - 4
Now I need a tool or a dll to calculate these expressions. Is something like this available?
At first I was looking if the formula node's string was configurable at run-time, but it isn't.
Thanks in advance,
T.
Have a look at "Eval Formula node" and the tools in the "Analyze...Mathematics..Formula...Advanced Formula Parsing" palette. Check the LabVIEW help for details.
(Not available in LabVIEW Base, you need LabVIEW Full or higher)
LabVIEW Champion . Do more with less code and in less time .
Similar Messages
-
[b]Listener problem while configuring host string through NET config[/b]
Hi,
I am unable to create host string through Net config. While testing with userid/password, the test does not succeed.
The host string configured is known as PROCESS.
Net config error message while testing the connection is as follows:
"Connecting...ORA-12541: TNS:no listener
The test did not succeed.
Some of the information you provided may be incorrect.
Press back to review the information provided for net service
name, or Change Login to change username."
Upon checking the status of listener from command prompt it gives following status:
LSNRCTL> status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC0)))
STATUS of the LISTENER
Alias LISTENER
Version TNSLSNR for 32-bit Windows: Version 9.2.0.1.0 - Produc
tion
Start Date 08-JAN-2003 16:25:08
Uptime 0 days 16 hr. 9 min. 33 sec
Trace Level off
Security OFF
SNMP OFF
Listener Parameter File C:\orant\network\admin\listener.ora
Listener Log File C:\orant\network\log\listener.log
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(PIPENAME=\\.\pipe\EXTPROC0ipc)))
Long postings are being truncated to ~1 kB at this time.Did you check that the DB is up ? If not, then check it and, eventually, start it up.
If yes, then open a DOS window, set your ORACLE_SID, connect to Sqlplus as sysdba and type :
SQL> show parameter service
what is the result ? -
we have an OCCI client program for which we want to increase the prefetch count preferably without producing a new binary between releases. Is it possible via a configuration parameter or the connection string (which is parameterized in our program)? Thanks
we have an OCCI client program for which we want to increase the prefetch count preferably without producing a new binary between releases. Is it possible via a configuration parameter or the connection string (which is parameterized in our program)? Thanks
Not that I am aware of. For OCI the methods needed are part of the statement class, not the connection class. See the OCI prog guide
http://docs.oracle.com/cd/B28359_01/appdev.111/b28390/reference030.htm#sthref889
setPrefetchMemorySize()
Sets the amount of memory that will be used internally by OCCI to store data fetched during each round trip to the server.
setPrefetchRowCount()
Sets the number of rows that will be fetched internally by OCCI during each round trip to the server. -
hi experts,
How to calculate string length from driver program. Is there any function module to do it. Please help me. In my application, i will get the input from user and calculate string length and process it. Please help me.Hi,
<<removed>>
Umang Mehta
Edited by: kishan P on Oct 9, 2010 3:42 PM -
Variant Configuration:Calculation For Masking tape in VA:21.
Dear Experts,
Our client is using sales order BOM for Quotation purpose, now they need following calculation, kindly suggest way to make it possible.
Below is the calculation of MASKING TAPE requirement,
3M means 7000232
1)
2) If 3M X 2 is u226410 system should capture 7000557
3) If 3M X 2 is >10 and u226420 system should capture 7000558
4) If 3M X 2 is >20 and u226430 system should capture 7000559
5) If 3M X 2 is >30 and u226440 system should capture 7000560
6) If 3M X 2 is >50 system should capture 7000235
7)
8) We require MASKING TAPE calculation, based on consolidated 3M Quantity.
9)
Example: For Line Item 10 - 3M Tape Qty is 5m
For Line Item 20 - 3M Tape Qty is 15m
For Line Item 30 - 3M Tape Qty is 18m
Total 3M Qty is 38Mtrs, MASKING TAPE required Qty is 38x2 = 76 Mts
Hence Material for Masking to be picked
1 No. 7000235 (50Mts)
1 No. 7000559 (30Mts)
Kind Regards From Samirsinh.Hi Amber,
Thanks for help, but our porblem is different, take a look following example for understanding of problem,
10 STEEL DOOR 1 EA
11 7000002 3 EA
12 7000190 2 EA
13 7000232 4.400 M
14 7001041 154 ML
20 STEEL DOOR 2 EA
21 7000002 6 EA
22 7000232 16.800 M
23 7001041 588 ML
30 STEEL DOOR 1 EA
31 7000002 3 EA 0
32 7000232 4.200
33 7000186 2
34 7001041 147
Here line items 13,22 and 32 are same, client requirement is that system should consolidate requirement first like 2x(4.416.84.2)=50.8 and then it should capture 7000235 of 50MTS for 50 and for0.8 it should capture 7000559 of 30MTS so losses would be minimize.
Kind Regards From Samirsinh -
Search and replace string not work as per required
please find the attachment. i am trying to replace the variable names but it doesnt replace the variable as i expected. Please help me in this
Attachments:
Replace String.vi 8 KB
Replace String.vi 8 KBYou haven't configured the strings to be "default". Hence, all string elements in your attached vi's are empty.
I have no idea what you try to achieve without those strings....
Norbert
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it. -
How to find number of characters in a character string
Hi,
Can anyone please tell me about how to find the number of characters in a character string type variable.
Reagards,
Sivahi,
Use STRLEN for Calculating String Length..
Assign it to integer variable for Further Use.Suppse u need to find string length for "hai".. this piece of code will help u
data: var type string value 'hai',
len type i.
len = strlen(var).
write len. -
Dynamic Configuration in SAP PI 7.3
Hello,
I am doing one file to file scenario in PI 7.3 (Java Stack only).
There is one requirement i.e. The output file name will change according to Development, Quality and Production. Prefix will be added to the outputput file name according to Development, Quality & production.
I am new in SAP PI . Please suggest me what to do for the above requirement.
Thanks & Regards,
MoumitaHi Moumita,
Please find the details
1) read the source directory and based on source directory name set the file name in dynamic configuration
In sender communication channel select the ASMA parameter Directory and read the dynamic configuration as below
String devFileName = "DEV_out.txt";
String qaFileName = "QA_out.txt";
String regFileName = "Reg_out.txt";
String directory= "";
DynamicConfiguration conf1 = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key1 = DynamicConfigurationKey.create( "http:/"+"/sap.com/xi/XI/System/File","Directory");
directory= conf1.get(key1);
If (directory.equals("DEV"))
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
conf.put(FileName, devFileName);
return "";
else
If (directory.equals("QA"))
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
conf.put(FileName, qaFileName);
return "";
else
If (directory.equals("Reg"))
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
conf.put(FileName, regFileName);
return "";
2) read the system id and based on that set the file name in dynamic configuration.
String System = System.getProperty("SAPSYSTEMNAME");
String devFileName = "DEV_out.txt";
String qaFileName = "QA_out.txt";
String regFileName = "Reg_out.txt";
If (System.equals("DEV"))
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
conf.put(FileName, devFileName);
return "";
else
If (System.equals("QA"))
DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
conf.put(FileName, qaFileName);
return "";
else
If (System.equals("Reg"))
DynamicConfiguration conf = (DynamicConfiguration) container.getTransf
ormationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey FileName = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
conf.put(FileName, regFileName);
return "";
regards,
Harish -
Problems saving values in the configuration file
Hello,
I'm upgrading one of my projects from VS2005 (with .NET 2.0) to VS2013 (with .NET 4.5). I have a setup project in my solution, but this is no longer supported and I have to change to InstallShield
deployment project. With the old setup project my app runs fine, but now with InstallShield I have a problem. I install the application in this folder: C:\Program Files (x86)\CompanyName\AppName. I use .config file to read and write some parameters.
Reading parameters goes well, but when I write new values in the .config file a get one error. When I used the old setup project, at writing time the system created new .config file in C:\Users\me\AppData\Local\VirtualStore\Program Files (x86)\CompanyName\AppName
(this is named isolated storage, isn't it? :S).
These are all changes I made in the solution:
When I opened the solution with VS 2013 the migration process went well (some warnings and messages) except setup project (of course).
I upgrade all projects to .NET Framework 4.5 (Project properties -> Application -> Target framework).
I have intalled InstallShielld Limited Edition and added and configured the new deployment project.
I think that these are all changes. And this is the source code where I get the exception:
public void SetXParamValue(string value)
try
Configuration conf = ConfigurationManager.OpenExeConfiguration(Application.ExecutablePath);
conf.AppSettings.Settings["XParam"].Value = value;
conf.Save();
catch (Exception e)
MessageBox.Show("Error setting X param.");
And this is the exception:
Exception messsage:
An error occurred loading a configuration file: Access to the path 'C:\Program Files (x86)\CompanyName\AppName\oy25i1se.tmp' is denied. (C:\Program Files (x86)\CompanyName\AppName\ExeFile 1.0.192b.exe.config)
Stack trace:
at System.Configuration.MgmtConfigurationRecord.SaveAs(String filename, ConfigurationSaveMode saveMode, Boolean forceUpdateAll)
at System.Configuration.Configuration.SaveAsImpl(String filename, ConfigurationSaveMode saveMode, Boolean forceSaveAll)
at System.Configuration.Configuration.Save()
at VisualizadorCabecera.FormPrincipal.EstablecerIdioma(CultureInfo idioma)
Inner exception messsage:
Access to the path 'C:\Program Files (x86)\CompanyName\AppName\oy25i1se.tmp' is denied.
Stack trace:
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean
checkHost)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access)
at System.CodeDom.Compiler.TempFileCollection.EnsureTempNameCreated()
at System.CodeDom.Compiler.TempFileCollection.AddExtension(String fileExtension, Boolean keepFile)
at System.CodeDom.Compiler.TempFileCollection.AddExtension(String fileExtension)
at System.Configuration.Internal.WriteFileContext..ctor(String filename, String templateFilename)
at System.Configuration.Internal.InternalConfigHost.StaticOpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext, Boolean assertPermissions)
at System.Configuration.Internal.InternalConfigHost.System.Configuration.Internal.IInternalConfigHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext, Boolean assertPermissions)
at System.Configuration.Internal.InternalConfigHost.System.Configuration.Internal.IInternalConfigHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext)
at System.Configuration.ClientConfigurationHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext)
at System.Configuration.UpdateConfigHost.OpenStreamForWrite(String streamName, String templateStreamName, Object& writeContext)
at System.Configuration.MgmtConfigurationRecord.SaveAs(String filename, ConfigurationSaveMode saveMode, Boolean forceUpdateAll)
Any suggestions? I have to configure something else?
Thank you,
Jon.> "With the old setup project my app runs fine"
Actually, I disagree. Your configuration file is sitting alongside your application, in a directory that
should be protected from changes by "regular" users and it's
only running because Windows is intercepting your attempt to write under C:\Program Files* and rerouting those attempts to a "Virtual Store" location. By the sounds of it, something your new installer is doing is [quite rightly]
stopping this from happening (IIRC, virtualisation can be turned off for a program and, IMHO,
should be).
You need to move the configuration file to a location that the user can write to (somewhere under C:\Users\username), even if you have to copy it the very first time it's needed.
Regards, Phill W. -
System.ServiceModel.Configuration.MachineSettingsSection does not exist
Based on the instructions in this link for enabling logging of PII...
https://msdn.microsoft.com/en-us/library/ms730318(v=vs.90).aspx
None my versions - 3.5 -4.5.1 of .NET has a class System.ServiceModel.Configuration.MachineSettingsSection
The only class with that name that exists is System.Transactions.Configuration.MachineSettingsSection
I can only assume this is why it is not possible to add that section to machine.config, can anybody confirm this please?
If so, then where should this section go in machine.config to enable PII logging?
Thanks
JonThe System.ServiceModel.Configuration.MachineSettingsSection class is indeed not public.
But you can still add the enableLoggingKnownPii setting to a configuration file if this is what you want:
Configuration machineConfig = ConfigurationManager.OpenMachineConfiguration();
System.ServiceModel.Configuration.ServiceModelSectionGroup section = machineConfig.GetSectionGroup("system.serviceModel") as System.ServiceModel.Configuration.ServiceModelSectionGroup;
foreach (ConfigurationSection s in section.Sections) {
if(s.GetType().ToString().Equals("System.ServiceModel.Configuration.MachineSettingsSection"))
string xml = s.SectionInformation.GetRawXml();
if (xml == null)
xml = string.Empty;
s.SectionInformation.SetRawXml(xml + "<machineSettings enableLoggingKnownPii=\"true\"/>");
machineConfig.Save();
The other option is to just open the machine.config file in Notepad and add the enableLoggingKnownPii attribute manually:
http://stackoverflow.com/questions/2325473/where-is-machine-config
Hope that helps.
Please remember to mark helpful posts as answer to close your threads and then start a new thread if you have a new question. -
Configurations are not saved on Aironet 3602E
I tried configuring snmp string on aironet 3602E. It gets configured but movement i restart the AP, configurations are not saved. I tried using write memory command but no use.
Kindly assistYou can't. Things are handled by the WLC.
Q. Can a LAP AP handle SNMP messages like an IOS AP?
A. The LAP APs cannot handle SNMP messages on their own. In order to handle SNMP messages, you should configure an SNMP community on the WLC to which the LAP is registered. All the AP information is managed by the WLC.
Scott -
Dears
We have a scenario where bank is using NTRF both for check and Bank Transfer. Only way to distinguish that it is check is that immediately after External Transaction the check number is of 6 character otherwise it is Bank Transfer. In the EBS configuration with each External Transaction we can assign only one Posting Rule and algorithm.
We come to know that through search strings we can change the posting rule and algoritham. We went to many answer on net to work on search strings but so far nothing successful. Can someone guide us how to use it.
ThanksHi Expert,
Please refer to the below link which will help in configuring Search Strings for your scenario.
http://help.sap.com/saphelp_46c/helpdata/es/af/0a242bc925d311b60f0060b03c2bff/content.htm
http://help.sap.com/saphelp_46c/helpdata/en/6d/0cdf4b142e11d3963800a0c9426c73/content.htm
Regards,
GK
SAP -
Sear string for customer bank account no
Hai ,
The requirement is that customer account number should be identified from customer bank key and bank account number which are available in the bank statement .I need to configure search string and assign it to interpretation algorithm.How i need to define and assign search string for bank key,bank account number .Example :AC-250-208762-20
The problem is that the length of bank key and bank account number for each customer is different
Example 1:Customer 100000
AC-25-45275865-333
Example 2 :customer 100001
AC-215-115275865-11
I need to post entries to customer account and no clearing is required . How search string can be defined for this ?
Note:Search string should be defined for customer bank account no because statement has no reference number
Regards,
KumarHi.
'customer master data, what are the integrated effects to FI > Bank Accounting > House Bank ?' House bank not linked with Customer master data(only if customer affiliated company).
Bank details in customer could be used eg for invoicing(printing form) -
How to configure Sesion Factory in Hibernate to implement getCurrentSession
Hi,
I am new in Hibernate and I am using an application where I need to improve the performance while uploading the users through a utility. While analyzing the system, I found that, to insert a single user there were around 8 hits are made to DB to get the information and based on that finally it inserts the user. The strange thing I have noticed is that for every hit, a new DB connection is opened in code using the snippet getHibernateTemplate().getSessionFactory().openSession();
However, the connection is getting closed in finally block. But I think instead of using Open Connection; getCurrentSession can save time.
Can any one suggest whether I am on right track?
Also, when I have tried to use getCurrentSession I have simply replaced "getHibernateTemplate().getSessionFactory().openSession();" with "getHibernateTemplate().getSessionFactory().getCurrentSession();" from everywhere in code.
But when I tried to run the Utility I got some Hibernate Exception stating "No Hibernate Session bound to thread, and configuration does not allow creation".
Could anyone suggest do I need to configure anything else in my applicationcontext.xml to use the getCurrentSession() method.
Thanks in advance.the method getCurrentSession() should be done using Singleton factory method so that you have only one connection per application. You can implement something like this as coded below:
import java.io.File;
import javax.naming.InitialContext;
import org.apache.log4j.Logger;
import org.hibernate.HibernateException;
import org.hibernate.Session;
import org.hibernate.SessionFactory;
import org.hibernate.cfg.Configuration;
import org.hibernate.cfg.Environment;
* @author hennebrueder This class garanties that only one single SessionFactory
* is instanciated and that the configuration is done thread safe as
* singleton. Actually it only wraps the Hibernate SessionFactory.
* When a JNDI name is configured the session is bound to to JNDI,
* else it is only saved locally.
* You are free to use any kind of JTA or Thread transactionFactories.
public class InitSessionFactory {
* Default constructor.
private InitSessionFactory() {
* Location of hibernate.cfg.xml file. NOTICE: Location should be on the
* classpath as Hibernate uses #resourceAsStream style lookup for its
* configuration file. That is place the config file in a Java package - the
* default location is the default Java package.<br>
* <br>
* Examples: <br>
* <code>CONFIG_FILE_LOCATION = "/hibernate.conf.xml".
* CONFIG_FILE_LOCATION = "/com/foo/bar/myhiberstuff.conf.xml".</code>
private static String CONFIG_FILE_LOCATION = "<Path to hibernate.cfg.xml>";
/** The single instance of hibernate configuration */
private static final Configuration cfg = new Configuration();
/** The single instance of hibernate SessionFactory */
private static org.hibernate.SessionFactory sessionFactory;
* initialises the configuration if not yet done and returns the current
* instance
* @return
public static SessionFactory getInstance() {
if (sessionFactory == null)
initSessionFactory();
return sessionFactory;
* Returns the ThreadLocal Session instance. Lazy initialize the
* <code>SessionFactory</code> if needed.
* @return Session
* @throws HibernateException
public Session openSession() {
return sessionFactory.getCurrentSession();
* The behaviour of this method depends on the session context you have
* configured. This factory is intended to be used with a hibernate.cfg.xml
* including the following property <property
* name="current_session_context_class">thread</property> This would return
* the current open session or if this does not exist, will create a new
* session
* @return
public Session getCurrentSession() {
return sessionFactory.getCurrentSession();
* initializes the sessionfactory in a safe way even if more than one thread
* tries to build a sessionFactory
private static synchronized void initSessionFactory() {
* [laliluna] check again for null because sessionFactory may have been
* initialized between the last check and now
Logger log = Logger.getLogger(InitSessionFactory.class);
if (sessionFactory == null) {
try {
File f = new File(CONFIG_FILE_LOCATION);
cfg.configure(f);
String sessionFactoryJndiName = cfg
.getProperty(Environment.SESSION_FACTORY_NAME);
if (sessionFactoryJndiName != null) {
cfg.buildSessionFactory();
log.debug("get a jndi session factory");
sessionFactory = (SessionFactory) (new InitialContext())
.lookup(sessionFactoryJndiName);
//sessionFactory = new AnnotationConfiguration().configure(System.getProperty("user.dir") + "\\" + CONFIG_FILE_LOCATION).buildSessionFactory();
} else{
log.debug("classic factory");
sessionFactory = cfg.buildSessionFactory();
} catch (Exception e) {
System.err
.println("%%%% Error Creating HibernateSessionFactory %%%%");
e.printStackTrace();
throw new HibernateException(
"Could not initialize the Hibernate configuration");
public static void close(){
if (sessionFactory != null)
sessionFactory.close();
sessionFactory = null;
}Test it and let me know. -
Failing Search String in EBS through IDOC
Dear All,
we upload our EBS through idoc processing of type finsta. The problem is that for a particular bank theres a search string attached which will replace the posting rule if a certain but fix narration (say "Trf 66852") is received in note to payee field apart from the fixed external transaction code. The problem is that, in the idoc segment, though i am putting the same fixed narration as Trf66852 however the posting rule is not replacing. I am not able to determine even if the search string is working. I tried checking in EBSTS but apart from two blank lines nothing much is appearing. If anyone ever come across this issue pls share your experience.
best regds
SubhaHi Subha,
The Notes to payee updates from FINSTA IDoc should work.
1. If you want to know if the configured search string is working or not, you can simulate it in OTPM, where the search strings are defined in the search string definition > Simulation. You need to entry the text from bank in Simulation and click on test.
2. Secondly, you can check in table FEBRE where the notes to Payee fields are updated.
Regards,
Kavita
Maybe you are looking for
-
What are some steps to troubleshoot to see if apache is working?
-
How to run windows dll files and driver loaded in remote system?
Dear Friends, I need some valuable info regd how to run a remote windows dll files and the drivers of the system using java reply regd thanking you
-
Hello folks, I am just wondering how to code a select statement on a tvarv table with ranges. To be clear, I had created a variable with name ZTEST and then I clicked on the YELLOW arrow on the right and entered 10 numbers from 1 to 10. Now I have a
-
I am unable to listen to iheart radio app
na
-
How to Integrate Google_Mini with Stellent
Hi, Please let me know the integration steps of Google Mini with Stellent.