Loop or recursion in VC?

Hi all,
is it possible to simulate a "while" loop or a recursion in VC. Obviously VC has no official tools or components for it. So I guess I will need a workaround. But I don't know how.
What e.g. I want to achieve is an independent floating progressbar to simulate progress status.
I thought about using dynamic actions, but I can't get them working. I'm using NW2004s SP9.
Good ideas are appreciated,
Thanks Tobias

Hi again,
thanks for your help. Ok, I see that the timer is not implemented for such a special case.
But what's about dynamic actions? Maybe I could use a recursive action (something like an automatic update action triggered by a condition). Do you know, if dynamic actions work fine? I tried several ways to use them but without any success.
Thanks in advance,
Tobias

Similar Messages

  • Need to loop through Recursive node

    Hi Everyone,
    I am having troubles looping through a node to get a boolean value called "Check".
    Basically I am using the TreeNesteedInTable UI.  One of the columns I display is the "Check" mentioned above.  Basically the user can go through the tree structure and check his/her options.  I should then be able to loop through this structure to get all the records "Checked".  My application is not doing this.
    At the moment I am looping through the top level node - think this is where my probelm is because this node can only be singleton!  This means that I then have to loop through the Recusrsive node of this type to get the values as the recusrive is always non-singleton en must therefor contain the elements I am looking for.  But, i do not know how tho get access to this node.  Is this the correct way of doing it, or how should it be done otherwise?
    Many thanks,
    Christiaan

    HI,
    I got it to work like this:
    public void addICAMForIncident( )  {
        //@@begin addICAMForIncident()
           IWDMessageManager msgMgr = wdComponentAPI.getMessageManager();
              try {
                   int count;
                   Bapi1240_Rc rootCause;
                   IPublicEhs_icam.IAbsentOrFailedControlsElement existingAbsentOrFailedControlsElement;
                   IPublicEhs_icam.IAbsentOrFailedControlsElement recursive;
                   IPublicEhs_icam.IAbsentOrFailedControlsElement recursiveChildElement;
                   IPublicEhs_icam.IAbsentOrFailedControlsNode      recursiveChildNode;
              //     if(wdContext.nodeAbsentOrFailedControls() != null){
                             // set header data:
                             wdContext.currentHeader_CreateElement().setRecord_No(wdContext.currentHeader_GDElement().getRecord_No());
                             wdContext.currentHeader_CreateElement().setRecno_Root(wdContext.currentHeader_GDElement().getRecno_Root());
                             wdContext.currentHeader_CreateElement().setIncident(wdContext.currentGPInputNodeElement().getIPIncidentNum());
                             //Top Level Node (Singleton)
                             existingAbsentOrFailedControlsElement = wdContext.currentAbsentOrFailedControlsElement();
                             //We need to go through the values of the RECURSIVE node as that is where the values are!
                             //Each time we expand a node in the tree this recursive node is filled with values
                             for(int i = 0;i<existingAbsentOrFailedControlsElement.nodeRecursiveAbsentOrFailedControl().size();i++)
                                       recursiveChildNode = existingAbsentOrFailedControlsElement.nodeRecursiveAbsentOrFailedControl().nodeRecursiveAbsentOrFailedControl(i);
                                       for(int m = 0;m<recursiveChildNode.size();m++)
                                            recursiveChildElement = recursiveChildNode.getAbsentOrFailedControlsElementAt(m);
                                            if(recursiveChildElement.getCheck())
                                                 //New line in the "table":
                                                 rootCause = new Bapi1240_Rc();
                                                 rootCause.setFunction("009");
                                                 rootCause.setHierarchy_Key("EHS_IAL_STD");
                                                 rootCause.setNode_Key(recursiveChildElement.getNODE_ID());
                                                 rootCause.setRef_Recno(wdContext.currentHeader_GDElement().getRecord_No());
                                                 rootCause.setRef_Object("IAL");
                                                 rootCause.setRef_Recno_Smeas("0");
                                                 rootCause.setPrimarykey("00000000000000000001");
                                                 rootCause.setForeignkey("00000000000000000001");
                                                 rootCause.setFlgfrgnkey(true);
                                                 rootCause.setFlgprimkey(true);
                                                 rootCause.setFlag_Selected(true);
                                                 //add the line to the "table":
                                                 createInput.addRootcause(rootCause);
                                            }//end if
                                       }//end for
                        }// end for
                   // execute:
                   wdContext.currentBapi_Bus1240_Create_InputElement().modelObject().execute();
                   // invalidate the output structure:
                   wdContext.nodeOutput_Create().invalidate();
              } catch (CMIException ex) {
                   msgMgr.reportException(ex.getLocalizedMessage(), true);
        //@@end

  • For-loop in XSLT-Important

    All,
    version:11.1.1.4
    I have a requirement in the for-loop which has to iterate for a fixed loop. For instance: I want the for-loop to iterate only for 5 times, how should I define the for-loop?  Any idea, please share your thoughts.
    <xsl:for-each select="5">
    </xsl:for-each>
    I tried the above code, didn't work!.
    Rgds
    sen

    You can use templates in xslt like one below :-  Assign max - 5 and this will loop for 5 times.
    <xsl:template name="loop">
      <!--recursive loop until done-->
      <xsl:param name="i"/>
      <xsl:param name="max"/>
      <xsl:if test="$i &lt;= $max">
        <!-- Repeated content Here -->
        <!-- use value-of i to get loop index -->
        <xsl:value-of select="$i"/>.<br/>
          <xsl:call-template name="loop">
            <xsl:with-param name="i" select="$i + 1"/>
            <xsl:with-param name="max" select="$max"/>
          </xsl:call-template>
      </xsl:if>
    </xsl:template>
    <xsl:call-template name="loop">
      <xsl:with-param name="i" select="number(1)"/>
      <xsl:with-param name="max" select="number(5)"/>
    </xsl:call-template>
    Or you can also do while loop like one below:-
    <!-- recursive named template -->
    <xsl:template name="while">
    <xsl:variable name="VALUE">
    <!-- your evaluation -->
    </xsl:variable>
    <!-- evaluate and recurse -->
    <xsl:if test="$VALUE=0">
       <xsl:call-template name="while"/>
    </xsl:if>
    </xsl:template>

  • Directory recursion in MX6

    I've been asked to create an on-line tree of all the
    collateral files on the site such as, .pdf, .doc, .xls. I want to
    be able to dynamically grab every filename on the site from every
    directory and list it.
    Unfortunately, I'm stuck with CFMX6 so I can't use the
    "recurse" parm to go through all the subdirs of my site. I've seen
    some information out there on how to do this, but no helpful
    examples.
    I know I need to use recursion and I have a loop set up
    that's using it, but I'm having a hard time figuring out how to go
    as many directory levels deep as I need to. I think I can use the
    "type" parm value of "dir" to tell me when I've hit a new directory
    to search, but I don't know how to reset back to its root dir once
    I'm done searching the sub-level (if that makes any sense).
    Any tips or web references?

    You are correct you need to use recursion. One of the easiest
    ways to
    do recursion on your version is either a custom tag or a
    component method.
    You call either the tag or method passing it the top level
    directory.
    It loops over this directory output files. When it finds a
    directory
    entry it calls itself passing in this directory. This new
    instance
    loops over the next level directory repeating all the above.
    Your handing back to the higher level is handled
    automatically by the
    finishing of these spawned instances.
    Basic outline using a custom tag
    A basic CFM file:
    <cf_directoryScan directory="c://myDir">
    The custom Tag named "directoryScan":
    <cfdirectory name="dirQry"
    directory="#attributes.directory#"...>
    <cfloop query="dirQry">
    <cfif dirQry.type = "file">
    <cfoutput>#dirQry.name#</cfoutput><br/>
    <cfelse>
    <cf_directoryScan
    directory="#dirQry.directory#/#dirQry.name#">
    </cfif>
    <cfloop>
    If you are on an old enough version of CF that
    <cfdirectory...> returns
    the '.' and '..' directories, you will want to filter these
    out so that
    you do not create an endless loop of recursion.
    Rough, untested code with all the usual warnings.

  • Recursion issue

    I am experiencing an issue with recursive use of a method which needs to append string each time boolean hasNext is true.
    However in debug mode I detect the block if (hasNext) is being accessed even if the hasNext = false.
    So to temporarily fix the problem instead of
                   if (hasMaster){
                        standardizedPath.append(toBeAdded);
    I am using
                   if (hasMaster){
                        // FIXME enters the block even if hasMaster is false
                        // temporary solution
                        String toBeAdded = getStandardizedPath(next, filteredPaths);
                        if (!standardizedPath.toString().contains(toBeAdded)){
                             standardizedPath.append(toBeAdded);
    which although works, but the cause still remains unclear to me
    Any clue what is done wrongly here:
         private static String getPreparedJavaStatement(
                   List<String> givenPaths, String objName) {
              StringBuffer javaStatement = new StringBuffer();
              String next = "";
              List <String> filteredPaths = new ArrayList();
              for (String path : givenPaths){
                   // split pattern "dependent,master,dependency"
                   String [] paths = path.split(",");
                   String dependent = paths[0];
                   String master = paths[1];
                   String dependency = paths[2];
                   if (dependent.equals(objName)){
                        javaStatement.append((master + "_" + dependency).toLowerCase());
                        next = master; // next start for the chain
                   } else {
                        filteredPaths.add(path);
              // next the chain of getters should be appended recursively
              standardizedPath = new StringBuffer();
              boolean hasMaster = false;
              for (String path : filteredPaths){
                   String dependent = path.split(",")[0];
                   if (next.equals(dependent)){
                        hasMaster = true;
              if (hasMaster){
                   javaStatement.append(getStandardizedPath(next, filteredPaths));
              System.out.println(javaStatement);
              return javaStatement.toString();
         static StringBuffer standardizedPath;
         static String nextMaster;
         // recursively constructs the java getters chain to the propagated master
         private static String getStandardizedPath(
                   String next, List<String> filteredPaths ) {
                   Iterator it = filteredPaths.iterator();
                   while (it.hasNext()){
                        String path = (String) it.next();
                        String [] paths = path.split(",");
                        String dependent = paths[0];
                        nextMaster = paths[1];
                        String dependency = paths[2];
                        if(dependent.equals(next)){
                             if (dependency.contains("_")){
                                  if (!dependency.equals(nextMaster)) {
                                       dependency = nextMaster + "_" + dependency;
                             standardizedPath.append(".get"
                                       + PropertyUtils.standardizeForCG(dependency) + "()");
                             next = nextMaster;
                   boolean hasMaster = false;
                   for (String path : filteredPaths){
                        String dependent = path.split(",")[0];
                        if (next.equals(dependent)){
                             hasMaster = true;
                   if (hasMaster){
                        // FIXME enters the block even if hasMaster is false
                        // temporary solution
                        String toBeAdded = getStandardizedPath(next, filteredPaths);
                        if (!standardizedPath.toString().contains(toBeAdded)){
                             standardizedPath.append(toBeAdded);
              return standardizedPath.toString();
         }

    OK! Got you! And thanks for caring to answer :)
    Not even gonna read the unformatted code, but i the fix is based on the incorrect assumption that you're entering an if block when the condition is false, then the "fix" is wrong. Actually i didn't mean to enter the block when the condition is false, what I really need is when the condition false is detected to break the loop and return,
    but it doesn't. Couldn't just trace why after return the debugger enters the if block, but this time with hasMaster = true, which I didn't want.
    I suppose some stupid loop or recursion problem. Anyway, will figure out after refreshing the mind.
    In any case, if one cares to have a look here is the formatted code:
         private static String getPreparedJavaStatement(
                   List<String> givenPaths, String objName) {
              StringBuffer javaStatement = new StringBuffer();
              String next = "";
              List <String> filteredPaths = new ArrayList();
              for (String path : givenPaths){
                   // split pattern "dependent,master,dependency"
                   // and filter out the direct master object variable
                   // from the masters of direct masters if any
                   String [] paths = path.split(",");
                   String dependent = paths[0];
                   String master = paths[1];
                   String dependency = paths[2];
                   if (dependent.equals(objName)){
                        javaStatement.append((master + "_" + dependency).toLowerCase());
                        next = master; // next start for the chain
                   } else {
                        filteredPaths.add(path);
              // check if master has master(s)
              standardizedPath = new StringBuffer();
              boolean hasMaster = false;
              for (String path : filteredPaths){
                   String dependent = path.split(",")[0];
                   if (next.equals(dependent)){
                        hasMaster = true;
              if (hasMaster){
                   // here the chain of getters (CGStandardized) should be appended recursively
                   javaStatement.append(getStandardizedPath(next, filteredPaths));
              System.out.println(javaStatement);
              return javaStatement.toString();
         static StringBuffer standardizedPath;
         static String nextMaster;
         // recursively constructs the java getters chain to the propagated master
         private static String getStandardizedPath(
                   String next, List<String> filteredPaths ) {
                   Iterator it = filteredPaths.iterator();
                   while (it.hasNext()){
                        String path = (String) it.next();
                        String [] paths = path.split(",");
                        String dependent = paths[0];
                        nextMaster = paths[1];
                        String dependency = paths[2];
                        if(dependent.equals(next)){
                             // if appropriate dependency detected
                             if (dependency.contains("_")){
                                  if (!dependency.equals(nextMaster)) { // has named dependency
                                       dependency = nextMaster + "_" + dependency;
                             // no named dependency, can further proceed to direct master via getter
                             standardizedPath.append(".get"
                                       + PropertyUtils.standardizeForCG(dependency) + "()");
                             next = nextMaster;
                   boolean hasMaster = false;
                   for (String path : filteredPaths){
                        String dependent = path.split(",")[0];
                        if (next.equals(dependent)){
                             hasMaster = true;
                   if (hasMaster){
                        // FIXME issue with appending path more than once
                        // temporary solution
                        String toBeAdded = getStandardizedPath(next, filteredPaths);
                        if (!standardizedPath.toString().contains(toBeAdded)){
                             standardizedPath.append(toBeAdded);
              return standardizedPath.toString();
         }

  • Recursive StackOverFlow in Java client aplication

    Hi,
    We run into this recursive stackoverflow problem in our Swing + AWT + BWT client application. We could not pin point what GUI action caused this stackoverflow problem yet. We are currently trying to reset the stack size, see if we can find out the beginning of the stack trace, hope it will show what action caused this. At the mean time, can someone please shed some lights here on what was going on, and how to solve the problem? Thanks in advance.
    -Zihong
    OS: windows XP
    JDK: 1.5.0_08
    The exception stack trace is:
    java.lang.StackOverflowError
    at java.util.Hashtable.put(Hashtable.java:401)
    at sun.java2d.Disposer.add(Disposer.java:101)
    at sun.java2d.Disposer.addRecord(Disposer.java:69)
    at sun.awt.windows.Win32SurfaceData.initOps(Native Method)
    at sun.awt.windows.Win32SurfaceData.<init>(Win32SurfaceData.java:448)
    at sun.awt.windows.Win32SurfaceData.createData(Win32SurfaceData.java:316)
    at sun.awt.Win32GraphicsConfig.createSurfaceData(Win32GraphicsConfig.java:357)
    at sun.awt.windows.WComponentPeer.replaceSurfaceData(WComponentPeer.java:332)
    at sun.awt.windows.WComponentPeer.replaceSurfaceData(WComponentPeer.java:313)
    at sun.awt.windows.WComponentPeer.displayChanged(WComponentPeer.java:372)
    at sun.awt.windows.WCanvasPeer.displayChanged(WCanvasPeer.java:48)
    at sun.awt.windows.WPanelPeer.displayChanged(WPanelPeer.java:142)
    at sun.awt.windows.WPanelPeer.recursiveDisplayChanged(WPanelPeer.java:130)
    at sun.awt.windows.WPanelPeer.displayChanged(WPanelPeer.java:145)
    at sun.awt.windows.WPanelPeer.recursiveDisplayChanged(WPanelPeer.java:130)
    at sun.awt.windows.WPanelPeer.displayChanged(WPanelPeer.java:145)
    at sun.awt.windows.WPanelPeer.recursiveDisplayChanged(WPanelPeer.java:130)
    at sun.awt.windows.WPanelPeer.displayChanged(WPanelPeer.java:145)
    at sun.awt.windows.WPanelPeer.recursiveDisplayChanged(WPanelPeer.java:130)
    at sun.awt.windows.WPanelPeer.displayChanged(WPanelPeer.java:145)
    ...

    When we increased the stack trace limit to infinite (-XX:MaxJavaStackTraceDepth=0), we found the cause for this recursive problem:
         at sun.awt.windows.WPanelPeer.recursiveDisplayChanged(Unknown Source)
         at sun.awt.windows.WPanelPeer.displayChanged(Unknown Source)
         at sun.awt.windows.WWindowPeer.displayChanged(Unknown Source)
         at sun.awt.SunDisplayChanger.notifyListeners(Unknown Source)
         at sun.awt.Win32GraphicsDevice.displayChanged(Unknown Source)
         at sun.awt.Win32GraphicsEnvironment.displayChanged(Unknown Source)
         at sun.awt.windows.WToolkit$4.run(Unknown Source)
         at java.awt.event.InvocationEvent.dispatch(Unknown Source)
         at java.awt.EventQueue.dispatchEvent(Unknown Source)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
         at java.awt.EventDispatchThread.run(Unknown Source)
    Exception in thread "AWT-EventQueue-0"
    We suspect this occured when users was using windows XP remote desktop to access the client machine that ran the client application, which caused the windows resolution to change, so the call to Win32GraphicsEnvironment.displayChanged. The display change caused infinite loop of recursive calls.
    That seems to be a bug in Sun's java implementation.

  • Pascal's Triangle Problem

    Hey there guys. I was looking around the forums seeing if there was anything that someone posted simliar to my assignment. While there were SOME similar things, I think mines a bit more specific. Let me just state here that I don't want anyone to just come out and do the assignment for me, nor do I think that anyone would be willing to. Anyways, here's what I am dealing with.
    I am to design a method which uses recursion to print the n-th line of the Pascal's triangle. I have a few ideas in my head about how to make it, but I just can't translate my thoughts into words.
    My first guess is that my method declaration should look something like this:
    public int println(int n)
    }But I'm just at a brainlock. My class really hasn't touched recursion extremely in-depthly expect for what was needed for AP Exam and Binary Search methods. Usually I can figure this stuff out, but ahhh!
    Anyways, any help (aka nudge in the right direction) would be very appreciated.

    A recursive function can be explained as a function defined in terms of itself.
    It is a mathematical concept. Let's take a look at something simple, like fibonacci numbers. Fibonacci numbers are defined in math something like:f(1) = 1
    f(2) = 1
    f(n) = f(n-1) + f(n-2)What this means is that the first two fib numbers are 1 and 1, and every fib number after that is the sum of the two numbers immediately preceeding it. So if we unroll the fibonacci numbers, they are:1 1 2 3 5 8 13 21 34 ...Now we want to implement a method in Java that accepts a single int argument, n, and will return the nth fibonacci number. One way is to do this recursively as such:public int fibonacci(int n) {
        if (n == 1 || n == 2)
            return 1;
        return fibonacci(n - 1) + fibonacci(n - 2);
    }(what we haven't handled is when n < 1, but since this is just to increase understanding of recursion I will omit that)
    What you see is a commonality with all recursive functions, a base case and a recursion step. All recursive methods must have a base case or they will run infinately. Similarly all recursive methods must have a recursion step, for the simple reason that they would not be recursive functions otherwise. Another thing that all recursive functions have in common is that the recursive call is made on some narrower scope (in this case n less 1 and n less 2) resulting in a call drawing ever closer to the base case (not doing so would also result in infinite recursive calls).
    Note: sometimes fibonacci numbers are defined to have the 0th number as 0 and the 1st number as 1, for me that is matter of taste and still results in the same sequence of numbers, with an added 0 at the front.
    In your example, the base case is when n == 1, and the recursion step is the call to fillN with n less 1 (i.e., narrowing the scope). The thing that is different in your example is that the resulting array is being passed around in the recursive calls, this is quite common for accumulating results as the recursion is being wound up (the calls themselves) and even down (when calls return, like in your case).
    You should try tracing out the calls on paper with a reasonably small n, this will better help your understanding. Let me do it with n == 2.fillN(2, a) // a = [0, 0]
    // n is not 1 so we do the recursive call
    fillN(1, a) // a = [0, 0]
    // n is 1 so we do the base case
    array[0] = 1 // a = [1, 0]
    // returning back to the call with n == 2
    // we run through the loop (i begins at n - 1 or 1)
    array[1] += array[0] // a = [1, 1]
    // i becomes 0 which is not > 0 so we exit the loop
    // the recursion has ended and a is now [1, 1]Now you try it with n == 3.
    ps. slightly off-topic, there is a great article by Olivier Danvy and Mayer Goldberg called "There and back again" on the programming pattern of traversing one data structure as recursive calls are being made and traversing a different data structure as the calls are returning (hence, there and back again or TABA). If you're interested you should check it out (Note: they use Scheme in their examples, but that doesn't mean that there's nothing to learn from it if you don't know Scheme):
    http://www.brics.dk/RS/05/3/BRICS-RS-05-3.pdf
    Message was edited by:
    dwg

  • ODP and ADO and a trigger - problem

    I have written a simple trigger to turn on tracing for a session based on the username:
    It works fine through sqlplus. The application works when run using JDBC and native(?) java. But when we use hibernate and ODP.net and ADO.net The session goes into a loop of recursive sql and gets an ORA-36 too many recursive levels. I am not a java developer and I am at a loss on how to proceed. It appears to be firing the trigger or have fired the trigger, and then look for global_db_name until it dies.
    CREATE OR REPLACE TRIGGER gopal_user_login_trigger
    AFTER LOGON ON DATABASE
    DECLARE
         user_name VARCHAR2(30);
    BEGIN
    SELECT username INTO user_name FROM sys.V$SESSION
    WHERE audsid = USERENV('SESSIONID') AND audsid != 0 ;
    IF UPPER(user_name) = 'GOPALASSETUSER'      
    THEN
         DBMS_MONITOR.SESSION_TRACE_ENABLE(NULL, NULL, true, true);
    END IF;
    EXCEPTION
    WHEN NO_DATA_FOUND then null;
    END;

    Hi,
    Thanks for the bug number - that helped alot.
    Why the global_db_name lookup, I do not know. It appears to be part of the logon processing that follows the trigger.It is, indeed, part of the logon process and is called by internal code so that makes sense now.
    If you have MetaLink support, I would recommend opening an SR. One simple thing that I might suggest is to set "enlist=false" in your connect string if you can and test with that.
    Thanks,
    Mark

  • MTA Exam 98-361 CS - Please Help ASAP - It would be greatly appreciated!

    Hey guys:
    I am brand spanking new to this development scene and have zero background in any type of IT so, please bare with me..I'm currently active duty military planning on getting out in the fall. I heard about the MSSA program
    offered by Microsoft and decided to give it a shot since I meet the requirements (well, most). The reason I say most is my lack of background. Anyway, I just heard about the program about three or four weeks ago and didn't find out I met the requirements till
    about two weeks ago..At that time, I was also advised that to get into the program I had to pass this exam (MTA 98-361) , and I had to pass it before the new year to get into the course starting in January.
    Because I had such a short amount of time to prepare for the exam, of which I had no knowledge of, my leadership has been very flexible in letting me have time to study. I've taken great advantage of this and have spent countless hours at my desk studying.
    Probably around 12-14hrs a day, to be honest. I thought I had been taking this stuff in and really learning a lot getting all of these hours in in the past couple of weeks, until today. I get to the building that is holding my certiport proctored exam, I sign
    in, and when I do the proctor asks me, "is this the first time you're taking this exam?" At which point I replied yes and she advised me I had to pick the Visual Basic version of the test because it was my first time..My heart dropped and I got very
    nervous. I began the test and it looked completely foreign to me. These last two weeks I had focused all of my energy on learning C# and didn't have even a slight idea of how to apply these methods to VB. I know, most of you guys that have been in this awhile
    say this test is easy either way, but it wasn't for me, I'm not at that level. Needless to say, I failed...miserably, and was advised I could retake the test in 24hrs and I could take the correct test..real reassuring...When I say I did bad, it was BAD. Now
    I'm beginning to question if I even have a grasp on the simple stuff, the basic understanding of all of this. I enjoyed what I was learning, hence the keeping motivation through those long days.
    Is this not for me? I was advised that my results would be sent directly to MS and all I could think was GREAT, and I'm trying to get a job in this industry..is this going to look negatively on my behalf when MS sees that, even if I do somehow still manage
    to pass the test that I've been studying for and make it into the program? I'm dedicated and wiling to put what I need to into this because, like I said, it really interests me..I'm just looking for some insight if this is a realistic path for me or not and,
    if so, if anyone can enlighten me on how I can better prepare myself for the exam next week (CS version).
    Is the MeasureUp practice testing as good of a source as it's made out to be? Or should I be going elsewhere? I've watched the MSDN MTA modules multiple times, read Wiley cover to cover, and looked up things I didn't know or wasn't sure of all over the internet.
    I'm just wondering what all of you dev gurus would suggest for someone totally new, to learn all of these fundamentals in this short amount of time. Sorry for the lengthiness of this thread, I'm just a little stressed and frustrated.
    Thanks much,
    Joey
    ////I know there's lots of threads about the MTA 98-361, I'm just looking for particular help in regards to ////my current situation, thank you.//

    To start with, I think that your proctor made a mistake. If you have been doing all your studying with C#, you should have taken your exam in C#, not in VB. Although the change from C# to VB is trivial for someone who has years of practice with both languages,
    in your particular case you should have stuck with the one with which you were most familiar.
    As a second piece of advice, you need some practice rather than just stuudy time. The questions in the MTA exams are in general very easy to reply if you have actually done the things that they are talking about (versus just having studied them on paper).
    For this exam about "development fundamentals" I would recommend that you write a few simple programs that exercise the various topics covered in the "skills measured" section of the exam description page. For instance, when you see the
    topic labelled "For loops, While loops, Do...While loops, and recursion", go ahead and write a programs with several types of loops and verify that you understand how to write them, how they work, and that they produce the results that you expected.
    Do the same with recursion. Repeat this for every entry in the list of Skills Measured, and you should be ready to take the exam.

  • How can I access the sub elements of the Nested Cluster-2

    would like to know the label a sub element of a Nested Cluster. I have included the vi. I am trying to programmetically read the Text label of the data elements in Value N mode cluster (Max , Min Mode). I was looking into the Type descriptor document. It can tell me how many and what type of elements are in the cluster. But it does not gove me Refnum to those objects.
    Let me know if you have an solution to my question."
    Attachments:
    cluster_1.vi ‏24 KB

    Hi
    You need to do a recursion. If the reference you get from the array "controls[]" if of type cluster, then you have to loop through recursively.
    Openg toolkit has variant tools that might be of some help to you (www.openg.org).
    Good luck
    PJM
    Got EasyXML?
    JKI.VIPM.EasyXML.OpenG.LAVA.Builder.blog

  • Write two functions to find the the number of elements in a linked list?

    I am trying to Write two functions to find the the number of elements in a linked list. One method using recursion and One method using a loop...
    //The linked List class is Represented here.
    public class lp {
    public int first;
    public lp rest;
    public lp(int first1, lp rest1)
    first = first1;
    rest = rest1;
    The program i wrote so far is
    import java.util.*;
    import linklist.lp;
    public class listCount{
    //loop function
    public static void show_list(lp list)
    int counter = 0;
    while(list != null)
    list = list.rest;
    counter++;
    System.out.println ("length computed with a loop:" + counter);
    //recursive function
    public static int recursive_count(lp list)
    if (list.first == null)
    return 0;
    else
    return recursive_count(list.rest) + 1;
    //main method
    public static void main (String args[])
    lp list1 = new lp(1, new lp(2, new lp(3, null)));
    show_list(list1);
    System.out.println("length computed with a recursion:" +
    recursive_count(list1));
    at the if (list.first == null) line i get the error " incomparable types:
    int and <nulltype>" I know this is a beginners error but please
    help...What should I do?

    byte, char, short, int, long, float, double, and boolean are primitives, not objects. They have no members, you cannot call methods on them, and they cannot be set to or compared with null.

  • Not Able  to Compile Java code

    Hi Java Gurus
    I am not able to compile this code Pl help
    class For {
    public static void main (String [] args) {
    int I = 0;
    show:
         if (I < 2) {
    System.out.print("I is " + I);
    I++;
    continue show;
    }

    class For {
    public static void main (String [] args) {
          for(int i = 0; i < 2; i++){
                  System.out.print("I is " + i);
    }this does the same as your program: the for loop is the best for this, but i agree with the others read some tutorials on loops in java. As posted before java has no concept of the GoTo syntax, loops or recursion are your only options

  • All possible Strings of 1 and 0

    if i wanted to create all possible strings of n 1's and n 0's where there are never more 0's than 1's using 2 for loops and recursion how would i go about this? (the first for loop controlls how many 1's are in the string the second how many 0's up to the number of 1's) What would the recursive alogrithim have to look like inorder for me to create every possible string of n 1's and n 0's where there are never more 0's than 1's ?

    void spew(int c0, int c1, int bal, String soFar){
      if(c0 == 0 && c1 == 0)System.out.println soFar;
      if(c0 > 0 && bal >= 0) spew(c0 - 1, c1, bal - 1, soFar+"0");
      if(c1 > 0) spew(c0, c1 - 1, bal + 1, soFar+"1");
    void spew(int n){spew(n,n,0,"");}And for those of you that are interested, the ones and zeros were not really ones and zeros, they were open and close parenthesis. The reason for not allowing the zeros to ever outnumber the ones was so avoid a mis-balanced set of parenthesis in the initial portion of the string, and the reason to have the same number of ones and zeros was so that final string would have a balanced set of parenthesis.
    Once you cast the problem in it's proper form, you can see that the real question was how to emit Strings with exactly n balanced pairs of parens. The total number of strings of this form are known as the Catalan numbers and you can look them up in Sloan's list of integer sequences. And of course the Catalan numbers are also the way that you count the distinct number of binary trees that you can create with exactly n nodes.
    Of course, I don't know any of that, I am just guessing the intent from the otherwise peculiar clarification of the problem and from the other posts by the OP asking about binary trees. It is a pity that the OP felt a need to obscure the original problem, making it both harder to solve and less likely that anyone googling for similar help would ever find it here.

  • Creating all binary strings with n 1's and n 0's

    if i wanted to create all possible strings of n 1's and n 0's where there are never more 0's than 1's using 2 for loops and recursion how would i go about this? (the first for loop controlls how many 1's are in the string the second how many 0's up to the number of 1's) What would the recursive alogrithim have to look like inorder for me to create every possible string of n 1's and n 0's where there are never more 0's than 1's ?

    {color:#ff0000}Cross posted{color}
    {color:#000080}Including this post --{color}{color:#0000ff}
    http://forum.java.sun.com/thread.jspa?threadID=5223773
    http://forum.java.sun.com/thread.jspa?threadID=5223679
    http://forum.java.sun.com/thread.jspa?threadID=5223774{color}{color:000080}
    Cross posting is rude.
    {color}

  • Flash CS3 Publish

    I am having a bit of trouble using Flash CS3. I have created
    my flash file, and published it to my hard drive. There are two
    files, one is the flash.swf file, and the other is index.html. With
    Flash MX I used to put these two files on my server and everything
    worked fine, however, this is not the case since I have gotten CS3
    - when I go to the domain it gives me this message: [Not Found The
    requested URL /public_html/Bluevision/ was not found on this
    server. Additionally, a 404 Not Found error was encountered while
    trying to use an ErrorDocument to handle the request.]. How do I
    fix this?

    I believe that refers to the timeout limit when a for loop or
    recursive function goes into an endless loop (default is 15 sec).
    Should not affect your coding unless you need to alter the
    limit.

Maybe you are looking for

  • How to connect a Desktop app to a middle teir server app?

    Please tell me if i have posted this in the incorrect forum. I currently have a Desktop app that connects directly to a mySQL database. The persistence abilities have been really helpful since our database is still evolving. I have been frustrated by

  • Hierarchy total

    Hi all, I have set a measure's logical level to a Hierarchy total as it has no detailed granularity of such hierarchy. e.g. budget plan for product total Hence, whatever user drill from product total to details, it will show the same number. Now, I w

  • Error when import a business partner master data

    Dear Colleagues, When i want to import a business partner master data using Data Transfer Workbench, i got an error "Account receivable/payable is missing [OCRD.DebPayAcct] Application-defined or object defined error65171". What is happened? Best Reg

  • Use of FM 'SELECT_OPTIONS_RESTRICT' in other than INITIALIZATION event

    Hi all, I am using function module SELECT_OPTIONS_RESTRICT to restrict the select option ranges. My question is can we use this FM into another event such as AT SELECTION-SCREEN. Basically I want to restrict n grayed out Select Option High value and

  • BO XI R2 - Showing decimal places

    Post Author: Vorax CA Forum: WebIntelligence Reporting Good afternoon all, I am using BO XI R2 (Webi), and have created multiple variables. The issue is that the variables are showing the cents of the figure even though I have formatted the cell. I a