Please HELP !!! Signed Applet & Java Media Framework(JMF)

Hi,
I have written a self signed applet that is used for Recording voice running in browser:
The tag that I've given is as follows:
<OBJECT
classid = "clsid:CAFEEFAC-0014-0001-0000-ABCDEFFEDCBA"
id="recordApplet"
codebase = "http://java.sun.com/products/plugin/autodl/jinstall-1_4_1-windows-i586.cab#Version=1,4,1,0"
WIDTH = 268 HEIGHT = 27>
<PARAM NAME = CODE VALUE = "RecWindow">
<PARAM NAME = ARCHIVE VALUE = "jmf.jar,sound.jar,SignedRecWindow.jar">
<PARAM NAME = "soundtrack" VALUE="testFile.mp3">
<PARAM NAME = "type" VALUE = "application/x-java-applet;jpi-version=1.4.1">
<PARAM NAME = "scriptable" VALUE = "true">
<PARAM NAME = "MAYSCRIPT" VALUE = "true">
</OBJECT>
I've also signed jmf.jar as well as sound.jar that come in JMF 2.1 and am including it the archive. These jars are downloaded on client machine.
My code works perfectly BUT only when JMF 2.1 is installed on the clients machine else I get a RunTime Exception stating "no permission to capture from applet".
JMF FAQ states that If a user chooses to allow playing back locally stored media files or saving media files locally, he/she can do so by making use of a policy file. http://java.sun.com/products/java-media/jmf/2.1.1/faq-jmf.html#jmf2-applet-run
My requirement is that once the user has agreed to the signed applet to run then there should be no need to install JMF rather use the jmf.jar that is downloaded on client machine.
Also how can I grant the permission (permission javax.sound.sampled.AudioPermission "record";) to my applet in client computers ?
The client should not be asked to add any files (policy) by itself, all must be transparent for him.
Thanks in advance.
Vipin.

I too have been trying to get Java JMF sound recording to work via webstart. No luck so far.
I even tried playing (security.AllPermissions) with .java.policy file in the user's home directory and even modifying java.policy in the JRE/lib/security directory. No luck there too!
I also added security.AllPermissions to the javaws.policy in the JRE/jawas/javaws.policy file. Still no luck!
Any idea, anyone?

Similar Messages

  • Java Media Framework (JMF) Installation on Linux platform

    Currently I'm developing a Cross-Platform Media Player. My application runs properly on my machine running Windows. But I'm unable to test my application on my machine running Linux just because I'm unable to Install and configure Java Media Framework (JMF) on Linux.
    Can somebody tell me how to Install and Configure Java Media Framework (JMF) on Linux platform? Please tell me about all the required steps in detail.

    Are you perhaps trying to install a specific verion of Oracle on a specific verison of Linux?
    Both sets of specific version information are useful.
    For example, Fedora Core 5 has made a lot of changes in the stdandard c/C++ libraries and is incompatible with an regular Oracle install. (You would need to install the 'compatible' libraries in Fedora Core 5 before attempting to install Oracle..)

  • Please Help - signed applet wierdness

    I have a signed applet. Signing works fine.
    I get the following error:
    Exception occurred during event dispatching:
    java.lang.StackOverflowError
         at java.io.FilePermission$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.io.FilePermission.init(Unknown Source)
         at java.io.FilePermission.<init>(Unknown Source)
    and so on... (about 5 pages worth).
    This occurs on the following line:
    KeyPairGenerator keygen = KeyPairGenerator.getInstance("RSA");
    Please note that when I run this not in the plug in (just unit testing) it works fine. I have included all the necessary jars etc (note that it is not a class not found error). The signing works fine, the applet is trusted and can do trusted things.
    Please help, I have been stuck on this for quite some time, and it is getting quite urgent. I am getting more and more dismayed with the problems that seem to be inherent with the java plug in.

    Hi,
    I am getting the same problems as yours...using Plugin 1.3.0 i get the same error, even though no problem when debugging-running outside the sandbox...
    Did you get how to do, please?
    Thank you!
    Marzio
    ([email protected])

  • Using Java Media Framework (JMF) in Eclipse

    Hey all, I want to use JMF to have a video shown in my GUI application in Eclipse and have no idea where to start, I know the basics of GUI and how to show pictures etc but otherwise i don't know anything about videos... Any help would be hugely appreciated

    you can simply use the setup file available with JMF to install it ; then, the classpath will be automatically updated, and you should be able to use the JMF classes inside your application (even with eclipse)

  • Java Media Framework silent install

    Hi,
    When I install JMF on HP laptop, in JM studio File->Capture i donot get "use video device" portion so i am not able to capture video with the help of WebCam :( on other hand if i install JMF on Dell laptop, JM studio->File->Capture is disabled may i know what can be possible reason of this?
    Please guide me help.

    983818 wrote:
    I need to install the Java Media Framework to over 1000 windows computers. How to do this. MSI package does not exist. Oracle does not change this installer since 1998. Oracle spit of the fact that someone is forced to use this software. I hate proprietary software.You should take the hint: it is abandoned, don't use it.

  • Request: Java Media Framework

    http://java.sun.com/products/java-media … nload.html
    OpenOffice.org 2,x uses the Java Media Famework (JMF) to render media such as film and sound under Linux.
    It would be very usefull in Impress presentations
    I tryed but was unable to make a package
    Thanks in advance

    Try this package:
    http://aur.archlinux.org/packages.php?d … 1&ID=11728
    Give me feedback please
    See you
    You also have to:
    Set up OpenOffice.org to use Java Media Framework
    Use the Tools > Options > OpenOffice.org > Java menu
    Click the Class Path... Button.
    Click the Add Archive... Button.
    Browse to the /opt/java/jre/lib/ext/jmf.jar file to add it.
    More info at http://www.oooforum.org/forum/viewtopic … mfhome+sun
    Last edited by darzephyr (2007-06-20 19:23:47)

  • Java Media Framework fails on Windows 7

    I wrote a Java program to manage and play my MP3 files. This program works fine on Windows XT and Windows Vista but does not work on the new laptop I just purchased with Windows 7. The Java Media Framework cannot play my MP3 files running on Windows 7. Does anyone know of a fix? I saw some very old forum posts where the poster asked if anyone knew how to obtain the source code for the Java Media Framework. If I could get my hands on the source, I would debug the problem and provide the fix to the Java community. So does anyone know of a fix to Windows 7 problems or know how to get the Java Media Framework source code????

    I believe you are right. I didn't know how much native support the JMF code requires but that must be the problem because it doesn't work on Windows 7. I think I would get some other error if the native libraries needed by JMF were not available on Windows 7. Appears that the native code is invoked but fails for some reason resulting in the JMF ControllerEventError that I get when attempting to play my MP3 files. I always had an error on a very few MP3 files that I have downloaded using LimeWire but the songs were playable by Windows Media. So whatever native support JMF uses, it is not the same as Windows Media or JMF is just not using the native MP3 support correctly. I guess I will just have to keep my Music Library on one of my older computers and not use my Java program on Windows 7 to play my MP3 files. Do you have any idea if the programmers who wrote the JMF code are still maintaining it? Perhaps they would be interested in fixing the Windows 7 problem in a new release??

  • Is the Java Media Framework still supported by Sun or not ??

    Hello my name is Michael.
    I have questions about the JFM, are there any person who can response it, please post it.
    I don't know if the technology is up to date if there is no release or bug fix since 2003.
    Please tell me something about the plan from Sun about the Java Media Framework.
    Is there any substitute java framework to work with ??
    Thank you for your benefit !!
    Michael

    Doug,
    Your iPod should work with no issues on 10.4.11 and iTunes 8+.
    When the iPod "locks up" do you hear any clicking noises? Your symptoms sound like the hard drive is having hardware issues.
    Here's a trick I used to use to fix the older iPods. It involves opening up the iPod, so if you don't feel comfortable, you might want to go to someone who does.
    Take a blade from a box cutter and gently move it along where the plastic meets the metal on the iPod. Use the blade to pry open the iPod from the metal case for the back.
    Once you get the iPod out, look towards the bottom of the iPod, and you should see the hard drive with a wide cable attached to it. Take that cable out of the hard drive (gently). Find a Bic pen cap (or something similar) and push it in between the two rows of pins on the cable. Try to make sure the pins are spread apart evenly and all pointing directly out. Once you get that in place, firmly push the cable back into the hard drive and gently put the iPod back together.
    You may then want to restore just to be safe, and try loading your music again. I've used this trick on many old iPods to bring another couple of years of life into them. (sometimes this cable comes loose, causing the issues you're describing)
    Justin

  • Silent installation Java Media Framework

    Anyone knows the parameters to install the Java media framework 2.1.1 in silent mode?
    Thanks

    Abra-Cadabrah!
    There is no such option. Though you might deploy JMF using JWS, for a less painful experience for your users.

  • Signed Applet problems in Vista + JMF

    Hi All,
    I'm new to Java Applet programming. I wrote an application which works as a VoIP Client in a webpage (Using JMF). Its working very fine in allmost all Windows XP machines.
    But not in Windows Vista machines. In Vista i'm getting the following error :
    "No permission to capture from applet" - Since its a Signed applet. The application is digitally signed from a CA. Even though its not working in Vista (IE and Mozilla Firefox also).
    I have went through the following link which says IE in Vista will run on protected mode, so Signed Applet will not have all the permission eventhough its signed for "AllPermission".
    ----- http://java.sun.com/javase/6/webnotes/install/system-configurations.html
    And also I'm not able to create a customized jar file for JMF using JMF Customizer. (JMF Customizer is an application which creates a jar file with specified classes). While creating a jar file I'm getting particular class is not available. (In Windows XP, this class is compilled at run time).
    Please let me know the following things,
    a) Is there any security settings i have to make to run Signed Applet in Windows Vista ?
    b) What is Java Policy file? I don't have any policy file - will it affect the application ?
    c) Do I need to sign each applet (say i have 5 applets in single jar file) ?
    d) In Vista how Mozilla Firefox are running (like IE7's restricted environment or XP compatiable mode) ?
    Thanks in Advance,
    Karthikeyan R

    I have exatly the same problem but not with the class itself. I have the problem with an jar that my class calls.
    I use jdk1.4.2. I think it's basicaly the same problem as "lfpgMW".
    I'll also whould like an idea...
    thanks

  • Java media framework

    the browser is not able to pick the jmf classes.the same piece of code is running fine in the applet viewer but not in the browser.
    errors are
    class not found exception

    HAva a look at http://java.sun.com/products/java-media/jmf/2.1.1/solutions/ and look at "RTP Streaming Transmitting/Receiving media over RTP"

  • Using Java media framework

    I am look at this source code and it imports java.media when i compile it it says there is no such package. So i installed the JMF and it still doesn't work. Srry i am new to this and thanx fot the help.

    Hi,
    did you mean that you got some program's source code and they have javax.media imported?? That is the JMF package. Pls check if your installing of JMF is correct? Like for me, I am using eclipse. You can check in the JRE System lib. You will see the jmf.jar etc in there.
    Hope this help.
    Best Regards
    Ferdinand Ng

  • IE Specific problem loading signed applet java 1.5

    Hello,
    I am having troubles loading our signed applet under IE 6.0 (only tested version atm).
    Firefox loads it without trouble, though the <object> tag that launches each is different.
    Every time I try to launch the applet, it prompts me to install the java runtime environment. I currently have 3 different versions of the java 1.5 runtime on my machine and the Java Control Panel is set to default to the most recent (1.5.04).
    Regardless of whether I choose 'Install' or 'Don't Install' a rectangle with a red X appears in the top left corner of the window. Nothing happens if I choose 'Install'. I did install through that prompt once. I don't know why it keeps asking me.
    I have enabled the console before loading the applet, and there is absolutely NO output there. The applet is not loaded at all. I am not prompted to accept or deny our certificate. I have also tried disabling as much as I could security-wise in IE.
    Any help would be greatly appreciated. I've been searching the net for 2 days and haven't come across anything that fixes this problem. Almost everything I have found has indicated at least some console output at least.
    Here is the javascript code I am using. createVCRTarget is called on a button click. I guess I should also mention that this was working some months ago, but it is possible that it was before I installed Service Pack 2. All of my Windows security updates are installed. Also, you should be able to see in here that I also tried using an applet tag. That didn't work either. Nothing loaded when I tried that, the little Active-X icon was in the top left instead of a Red X. That was my first attempt with an applet tag ever though, so it may not have been correct. I think it is obsolete anyways?
    function createVCRTarget() {
         createWindow('valid.package.path.VCRLauncher', 'vcr.jar, targetsdk.jar, xercesImpl.jar, cidero-common.jar', 'VCRTarget', '300', '110');
         return true;     
    function createWindow(classid, jars, title, width, height) {
      var agent = navigator.userAgent.toLowerCase();
      var newWin = window.open("", title, "width="+width+",height="+height+",scrollbar=no,status=no,statusbar=no,resizable=no");
      newWin.document.write("<html>\n");
      newWin.document.write(" <head><title>" + title + "</title>\n");
      newWin.document.write(" <style type=\"text/css\">body { margin: 0; padding: 0; }</style>\n");
      newWin.document.write(" </head>\n<body>\n");
         if (agent.indexOf("msie")==-1) { // not IE
        newWin.document.write('<object classid="java:'+classid+'"');
        newWin.document.write('          codetype="application/java"');
        newWin.document.write('          archive="'+jars+'"');
        newWin.document.write('          width="'+width+'" height="'+height+'">');
        newWin.document.write('</object>');
         } else {
    //          newWin.document.write('<applet archive="'+jars+'" code="'+classid+'" height="'+height+'" width="'+width+'">');
              newWin.document.write('<object classid="clsid:CAFEEFAC-0014-0001-0005-ABCDEFFEDCBA"');
    //          newWin.document.write('               codebase="http://java.sun.com/products/plugin/autodl/jinstall-1_5_0-windows-i586.cab#Version=5,0,0,0"');
              newWin.document.write('               codebase="http://java.sun.com/update/1.5.0/jinstall-1_5_0_02-windows-i586.cab#Version=5,0,0,0"')
              newWin.document.write('               width="'+width+'" height="'+height+'">');
              newWin.document.write('<param name="code" value="'+classid+'" />');
              newWin.document.write('<param name="archive" value="'+jars+'" />');
              newWin.document.write('<param name="type" value="application/x-java-applet;jpi-version=1.5.0" />');
              newWin.document.write('</object>');
      newWin.document.write("</body>\n</html>\n");
    }Thanks in advance,
    -Tim

    I see now that you are forsing IE to use jre version 1.4.1_5 but you provide a codebase
    pointing to the 1.5 jre.
    It doesn't matter though what you use evan if you use the htmlconverter if the jdk
    you'll get wrong values for codebase and/or IE is not able to download the cab
    file.
    The only way I was able to install the jre through clsid and codebase browsing a
    page with IE was to download the cab file with mozilla (if you know the correct url to it).
    And then host the cab file yourselve.

  • The problem about Java media framework

    Excuse me, How to use Real Time Protocol Vedio with web camera?
    My program can use MIC, but can't found camera?
    Please Help me

    Hi,
    You can try a package named: JTwain, which is available at http://asprise.com/product/jtwain.
    JTwain supports all kinds of digital cameras and scanners. You can use Java to access, contorl digital cameras and scanners, and of course, to acquire images with flexible settings.
    The developers' guide is available @ http://asprise.com/product/jtwain/devGuide.php
    In the simplest case, one line of Java code can solve your problem.
    Good luck!

  • Please help C++ into java.

    Hello,
    I am working one small swing program. And want to know about c++ code. Can any one tell me that can we convert the c++ code into java code. My c++ code is:
    void Activity::computeInternalStructure(Rules& r)
         //the internal subgroups list must be computed before entering here.
         //teachers
         //this->nTeachers=0;
         this->iTeachersList.clear();
         for(QStringList::Iterator it=this->teachersNames.begin(); it!=this->teachersNames.end(); it++){
              int tmp;
              for(tmp=0; tmp<r.nInternalTeachers; tmp++){
                   if(r.internalTeachersList[tmp]->name == (*it))
                        break;
              assert(tmp < r.nInternalTeachers);
              //assert(this->nTeachers<MAX_TEACHERS_PER_ACTIVITY);
              //this->teachers[this->nTeachers++]=tmp;
              this->iTeachersList.append(tmp);
         //subjects
         this->subjectIndex = r.searchSubject(this->subjectName);
         assert(this->subjectIndex>=0);
         //activity tags
         this->iActivityTagsSet.clear();
         foreach(QString tag, this->activityTagsNames)
              assert(tag!="");
              int index=r.searchActivityTag(tag);
              assert(index>=0);
              this->iActivityTagsSet.insert(index);
         //this->activityTagIndex = r.searchActivityTag(this->activityTagName);
         //students     
         //this->nSubgroups=0;
         this->iSubgroupsList.clear();
         for(QStringList::Iterator it=this->studentsNames.begin(); it!=this->studentsNames.end(); it++){
              StudentsSet* ss=r.searchAugmentedStudentsSet(*it);
              assert(ss);
              if(ss->type==STUDENTS_SUBGROUP){
                   int tmp;
                   /*for(tmp=0; tmp<r.nInternalSubgroups; tmp++)
                        if(r.internalSubgroupsList[tmp]->name == ss->name)
                             break;*/
                   tmp=((StudentsSubgroup*)ss)->indexInInternalSubgroupsList;
                   assert(tmp>=0);
                   assert(tmp<r.nInternalSubgroups);
                   //assert(this->nSubgroups<MAX_SUBGROUPS_PER_ACTIVITY);
                   bool duplicate=false;
                   if(this->iSubgroupsList.contains(tmp))
                   //for(int j=0; j<this->nSubgroups; j++)
                   //     if(this->subgroups[j]==tmp)
                             duplicate=true;
                   if(duplicate){
                        QString s;
                        s=QObject::tr(QString("Warning: activity with id=%1\ncontains duplicated subgroups. Automatically correcting..."))
                             .arg(this->id);               
                        cout<<qPrintable(s)<<endl;
                   else
                        this->iSubgroupsList.append(tmp);
                        //this->subgroups[this->nSubgroups++]=tmp;
              else if(ss->type==STUDENTS_GROUP){
                   StudentsGroup* stg=(StudentsGroup*)ss;
                   for(int k=0; k<stg->subgroupsList.size(); k++){
                        StudentsSubgroup* sts=stg->subgroupsList[k];
                        int tmp;
                        /*for(tmp=0; tmp<r.nInternalSubgroups; tmp++)
                             if(r.internalSubgroupsList[tmp]->name == sts->name)
                                  break;*/
                        tmp=sts->indexInInternalSubgroupsList;
                        assert(tmp>=0);
                        assert(tmp<r.nInternalSubgroups);
                        //assert(this->nSubgroups<MAX_SUBGROUPS_PER_ACTIVITY);
                        bool duplicate=false;
                        if(this->iSubgroupsList.contains(tmp))
                        //for(int j=0; j<this->nSubgroups; j++)
                        //     if(this->subgroups[j]==tmp)
                                  duplicate=true;
                        if(duplicate){
                             QString s;
                             s=QObject::tr(QString("Warning: activity with id=%1\ncontains duplicated subgroups. Automatically correcting..."))
                                  .arg(this->id);
                             cout<<qPrintable(s)<<endl;
                        else
                             //this->subgroups[this->nSubgroups++]=tmp;
                             this->iSubgroupsList.append(tmp);
              else if(ss->type==STUDENTS_YEAR){
                   StudentsYear* sty=(StudentsYear*)ss;
                   for(int k=0; k<sty->groupsList.size(); k++){
                        StudentsGroup* stg=sty->groupsList[k];
                        for(int l=0; l<stg->subgroupsList.size(); l++){
                             StudentsSubgroup* sts=stg->subgroupsList[l];
                             int tmp;
                             /*for(tmp=0; tmp<r.nInternalSubgroups; tmp++)
                                  if(r.internalSubgroupsList[tmp]->name == sts->name)
                                       break;*/
                             tmp=sts->indexInInternalSubgroupsList;
                             assert(tmp>=0);
                             assert(tmp<r.nInternalSubgroups);
                             //assert(this->nSubgroups<MAX_SUBGROUPS_PER_ACTIVITY);
                             bool duplicate=false;
                             if(this->iSubgroupsList.contains(tmp))
                             //for(int j=0; j<this->nSubgroups; j++)
                             //     if(this->subgroups[j]==tmp)
                                       duplicate=true;
                             if(duplicate){
                                  QString s;
                                  s=QObject::tr(QString("Warning: activity with id=%1\ncontains duplicated subgroups. Automatically correcting..."))
                                       .arg(this->id);
                                  QObject::tr("&Ok"));
                                  cout<<qPrintable(s)<<endl;
                             else{
                                  //this->subgroups[this->nSubgroups++]=tmp;
                                  this->iSubgroupsList.append(tmp);
              else
                   assert(0);
    }Please help me. In this code we are using some variables. with QT GUI in c++.
    Thanks in advance.
    Manveer.

    Manveer-Singh wrote:
    Hello,
    I am working one small swing program. And want to know about c++ code. Can any one tell me that can we convert the c++ code into java code. My c++ code is:
    void Activity::computeInternalStructure(Rules& r)
         //the internal subgroups list must be computed before entering here.
         //teachers
         //this->nTeachers=0;
         this->iTeachersList.clear();
         for(QStringList::Iterator it=this->teachersNames.begin(); it!=this->teachersNames.end(); it++){
              int tmp;
              for(tmp=0; tmp<r.nInternalTeachers; tmp++){
                   if(r.internalTeachersList[tmp]->name == (*it))
                        break;
              assert(tmp < r.nInternalTeachers);
              //assert(this->nTeachers<MAX_TEACHERS_PER_ACTIVITY);
              //this->teachers[this->nTeachers++]=tmp;
              this->iTeachersList.append(tmp);
         //subjects
         this->subjectIndex = r.searchSubject(this->subjectName);
         assert(this->subjectIndex>=0);
         //activity tags
         this->iActivityTagsSet.clear();
         foreach(QString tag, this->activityTagsNames)
              assert(tag!="");
              int index=r.searchActivityTag(tag);
              assert(index>=0);
              this->iActivityTagsSet.insert(index);
         //this->activityTagIndex = r.searchActivityTag(this->activityTagName);
         //students     
         //this->nSubgroups=0;
         this->iSubgroupsList.clear();
         for(QStringList::Iterator it=this->studentsNames.begin(); it!=this->studentsNames.end(); it++){
              StudentsSet* ss=r.searchAugmentedStudentsSet(*it);
              assert(ss);
              if(ss->type==STUDENTS_SUBGROUP){
                   int tmp;
                   /*for(tmp=0; tmp<r.nInternalSubgroups; tmp++)
                        if(r.internalSubgroupsList[tmp]->name == ss->name)
                             break;*/
                   tmp=((StudentsSubgroup*)ss)->indexInInternalSubgroupsList;
                   assert(tmp>=0);
                   assert(tmp<r.nInternalSubgroups);
                   //assert(this->nSubgroups<MAX_SUBGROUPS_PER_ACTIVITY);
                   bool duplicate=false;
                   if(this->iSubgroupsList.contains(tmp))
                   //for(int j=0; j<this->nSubgroups; j++)
                   //     if(this->subgroups[j]==tmp)
                             duplicate=true;
                   if(duplicate){
                        QString s;
                        s=QObject::tr(QString("Warning: activity with id=%1\ncontains duplicated subgroups. Automatically correcting..."))
                             .arg(this->id);               
                        cout<<qPrintable(s)<<endl;
                   else
                        this->iSubgroupsList.append(tmp);
                        //this->subgroups[this->nSubgroups++]=tmp;
              else if(ss->type==STUDENTS_GROUP){
                   StudentsGroup* stg=(StudentsGroup*)ss;
                   for(int k=0; k<stg->subgroupsList.size(); k++){
                        StudentsSubgroup* sts=stg->subgroupsList[k];
                        int tmp;
                        /*for(tmp=0; tmp<r.nInternalSubgroups; tmp++)
                             if(r.internalSubgroupsList[tmp]->name == sts->name)
                                  break;*/
                        tmp=sts->indexInInternalSubgroupsList;
                        assert(tmp>=0);
                        assert(tmp<r.nInternalSubgroups);
                        //assert(this->nSubgroups<MAX_SUBGROUPS_PER_ACTIVITY);
                        bool duplicate=false;
                        if(this->iSubgroupsList.contains(tmp))
                        //for(int j=0; j<this->nSubgroups; j++)
                        //     if(this->subgroups[j]==tmp)
                                  duplicate=true;
                        if(duplicate){
                             QString s;
                             s=QObject::tr(QString("Warning: activity with id=%1\ncontains duplicated subgroups. Automatically correcting..."))
                                  .arg(this->id);
                             cout<<qPrintable(s)<<endl;
                        else
                             //this->subgroups[this->nSubgroups++]=tmp;
                             this->iSubgroupsList.append(tmp);
              else if(ss->type==STUDENTS_YEAR){
                   StudentsYear* sty=(StudentsYear*)ss;
                   for(int k=0; k<sty->groupsList.size(); k++){
                        StudentsGroup* stg=sty->groupsList[k];
                        for(int l=0; l<stg->subgroupsList.size(); l++){
                             StudentsSubgroup* sts=stg->subgroupsList[l];
                             int tmp;
                             /*for(tmp=0; tmp<r.nInternalSubgroups; tmp++)
                                  if(r.internalSubgroupsList[tmp]->name == sts->name)
                                       break;*/
                             tmp=sts->indexInInternalSubgroupsList;
                             assert(tmp>=0);
                             assert(tmp<r.nInternalSubgroups);
                             //assert(this->nSubgroups<MAX_SUBGROUPS_PER_ACTIVITY);
                             bool duplicate=false;
                             if(this->iSubgroupsList.contains(tmp))
                             //for(int j=0; j<this->nSubgroups; j++)
                             //     if(this->subgroups[j]==tmp)
                                       duplicate=true;
                             if(duplicate){
                                  QString s;
                                  s=QObject::tr(QString("Warning: activity with id=%1\ncontains duplicated subgroups. Automatically correcting..."))
                                       .arg(this->id);
                                  QObject::tr("&Ok"));
                                  cout<<qPrintable(s)<<endl;
                             else{
                                  //this->subgroups[this->nSubgroups++]=tmp;
                                  this->iSubgroupsList.append(tmp);
              else
                   assert(0);
    }Please help me. In this code we are using some variables. with QT GUI in c++.
    Thanks in advance.
    Manveer.why do you say this?
    My c++ code is:and
    In this code we are using some variables. with QT GUI in c++. You didn't code that. Liviu Lalescu code that, not you.
    He has rights on that code and he published it under gpl.
    So you must say that it is from him, not from you.
    Also if you "translate" (modify) his algorithm you must still care about the gpl. Please read whole gpl and care about that.
    Regards,
    Volker Dirr
    PS:
    compare original code from Liviu at sourceforge or at his homepage:
    http://lalescu.ro/liviu/fet/
    you can see the copied copy in /src/engine/activity.cpp line 167 and following.

Maybe you are looking for