Search Results

Search found 1359 results on 55 pages for 'doubt'.

Page 2/55 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • emacs cedet set up doubt

    - by trybeingarun
    Hi, I installed cedet successfully today and got most of it working; thanks to Alex Ott's Gentle Introduction to Cedet. However i am having a problem When I give the exact path relative to the current file i am working on then auto-completion is working fine. #include "../../opensource/inc/lldp_port.h" void test_func() { lldp_port port; port.blah //here auto-completion worked fine } However i cannot specify the full path all the time( we have eclipse at office and it generates makefiles for us ) #include "lldp_port.h" void test_func() { lldp_port port; port. //here auto-completion does not work :( } What should i do to solve this?

    Read the article

  • doubt regarding carrying data in custom events using actionscript

    - by user267530
    Hi I am working on actionscript to generate a SWF dynamically using JSON data coming from an HTTP request. I receive the data on creationComplete and try to generate a tree like structure. I don’t create the whole tree at the same time. I create 2 levels, level 1 and level 2. My goal is to attach custom events on the panels which represent tree nodes. When users click the panels, it dispatches custom events and try to generate the next level. So, it goes like this : On creation complete - get JSON- create top tow levels - click on level 2- create the level 2 and level 3 - click on level 3- create level 3 and 4. …and so on and so on. I am attaching my code with this email. Please take a look at it and if you have any hints on how you would do this if you need to paint a tree having total level number = “n” where( 0 import com.iwobanas.effects.*; import flash.events.MouseEvent; import flash.filters.BitmapFilterQuality; import flash.filters.BitmapFilterType; import flash.filters.GradientGlowFilter; import mx.controls.Alert; private var roundedMask:Sprite; private var panel:NewPanel; public var oldPanelIds:Array = new Array(); public var pages:Array = new Array();//cleanup public var delPages:Array = new Array(); public function DrawPlaybook(pos:Number,title:String,chld:Object):void { panel = new NewPanel(chld); panel.title = title; panel.name=title; panel.width = 100; panel.height = 80; panel.x=pos+5; panel.y=40; // Define a gradient glow. var gradientGlow:GradientGlowFilter = new GradientGlowFilter(); gradientGlow.distance = 0; gradientGlow.angle = 45; gradientGlow.colors = [0xFFFFF0, 0xFFFFFF]; gradientGlow.alphas = [0, 1]; gradientGlow.ratios = [0, 255]; gradientGlow.blurX = 10; gradientGlow.blurY = 10; gradientGlow.strength = 2; gradientGlow.quality = BitmapFilterQuality.HIGH; gradientGlow.type = BitmapFilterType.OUTER; panel.filters =[gradientGlow]; this.rawChildren.addChild(panel); pages.push(panel); panel.addEventListener(MouseEvent.CLICK, function(e:MouseEvent){onClickHandler(e,title,chld)}); this.addEventListener(CustomPageClickEvent.PANEL_CLICKED, function(e:CustomPageClickEvent){onCustomPanelClicked(e,title)}); } public function onClickHandler(e:MouseEvent,title:String,chld:Object):void { //var panel:Panel; for each(var stp1:NewPanel in pages){ if(stp1.title==title){ var eventObj:CustomPageClickEvent = new CustomPageClickEvent("panelClicked"); eventObj.panelClicked = stp1; dispatchEvent(eventObj); } } } private function onCustomPanelClicked(e:CustomPageClickEvent,title:String):void { //cleanup itself Alert.show("onCustomPanelClicked" + title); var panel:NewPanel; for each(var stp:NewPanel in pages){ startAnimation(e,stp); } if(title == e.panelClicked.title){ panel = new NewPanel(null); panel.title = title; panel.name=title; panel.width = 150; panel.height = 80; panel.x=100; panel.y=40; this.rawChildren.addChild(panel); // var slideRight:SlideRight = new SlideRight(); slideRight.target=panel; slideRight.duration=750; slideRight.showTarget=true; slideRight.play(); //draw the steps var jsonData = this.map.getValue(title); var posX:Number = 50; var posY:Number = 175; for each ( var pnl:NewPanel in pages){ pages.pop(); } for each ( var stp1:Object in jsonData.children){ //Alert.show("map step=" + stp.text ); panel = new NewPanel(null); panel.title = stp1.text; panel.name=stp1.id; panel.width = 100; panel.id=stp1.id; panel.height = 80; panel.x = posX; panel.y=posY; posX+=150; var s:String="hi" + stp1.text; panel.addEventListener(MouseEvent.CLICK, function(e:MouseEvent){onChildClick(e,s);}); this.addEventListener(CustomPageClickEvent.PANEL_CLICKED, function(e:CustomPageClickEvent){onCustomPnlClicked(e)}); this.rawChildren.addChild(panel); // Alert.show("map step=" + this.getChildIndex(panel) ); // oldPanelIds.push(panel); pages.push(panel); //this.addEventListener(CustomPageClickEvent.PANEL_CLICKED, //function(e:CustomPageClickEvent){onCustomPanelClicked(e,title)}); var slide:SlideUp = new SlideUp(); slide.target=panel; slide.duration=1500; slide.showTarget=false; slide.play(); } } } public function onChildClick(e:MouseEvent,s:String):void { //var panel:Panel; //Alert.show(e.currentTarget.title); for each(var stp1:NewPanel in pages){ if(stp1.title==e.currentTarget.title){ var eventObj:CustomPageClickEvent = new CustomPageClickEvent("panelClicked"); eventObj.panelClicked = stp1; dispatchEvent(eventObj); } } } private function onCustomPnlClicked(e:CustomPageClickEvent):void { for each ( var pnl:NewPanel in pages){ pages.pop(); } //onCustomPanelClicked(e,e.currentTarget.title); //Alert.show("hi from cstm" + e.panelClicked.title); } private function fadePanel(event:Event,panel:NewPanel):void{ panel.alpha -= .005; if (panel.alpha <= 0){ //Alert.show(panel.title); panel.removeEventListener(Event.ENTER_FRAME, function(e:Event){fadePanel(e,panel);}); }; panel.title=""; } private function startAnimation(event:CustomPageClickEvent,panel:NewPanel):void{ panel.addEventListener(Event.ENTER_FRAME, function(e:Event){fadePanel(e,panel)}); } Thanks in advance. Palash

    Read the article

  • Basic doubt about sensor usage

    - by Al
    Suppose I have a cellphone with accelerometer and magnetometer, and want to determine its absolute (wrt North/East/South/West) 3d position. Imagine the phone is laid vertically, with the screen facing me, the "up" vector pointing to the ceil. Whenever I tilt, the accelerometer allows me to get the "up" vector info change. The problem is that if I tilt the device and put it horizontally (screen now facing ceil, and "up" vector pointing to the opposite of where I am), then the up vector doesn't get updated any more if I rotate the phone horizontally on the table. This is something that clearly is detected by the magnetometer now. So, the question is, when to know where to use acc or mag for each case? Is there a generic way to achieve this?

    Read the article

  • DropDownList problem/doubt

    - by SlimBoy
    Hi everybody!! I have one dropdownlist like this bellow.. the problem is that if I have more than 30 ListItem the list will have 30 elements/rows display and the rest to scroll. Is there a way to show only 10 elements and scroll the rest? I read in some pages that this is not possible. Is that true? <asp:DropDownList ID="id" runat="server"> <asp:ListItem Text="A" Value="AA" Enabled="true"></asp:ListItem> <asp:ListItem Text="B" Value="AA" Enabled="true"></asp:ListItem> . . . <asp:ListItem Text="D" Value="AA" Enabled="true"></asp:ListItem> </asp:DropDownList>

    Read the article

  • Pointer initialization doubt

    - by Jestin Joy
    We could initialize a character pointer like this in C. char *c="test"; Where c points to the first character(t). But when I gave code like below. It gives segmentation fault. #include<stdio.h> #include<stdlib.h> main() { int *i=0; printf("%d",*i); } Also when I give #include<stdio.h> #include<stdlib.h> main() { int *i; i=(int *)malloc(2); printf("%d",*i); } It worked(gave output 0). When I gave malloc(0), it worked(gave output 0). Please tell what is happening

    Read the article

  • A doubt on DOM parser used with Python

    - by fixxxer
    I'm using the following python code to search for a node in an XML file and changing the value of an attribute of one of it's children.Changes are happening correctly when the node is displayed using toxml().But, when it is written to a file, the attributes rearrange themselves(as seen in the Source and the Final XML below). Could anyone explain how and why this happen? Python code: #!/usr/bin/env python import xml from xml.dom.minidom import parse dom=parse("max.xml") #print "Please enter the store name:" for sku in dom.getElementsByTagName("node"): if sku.getAttribute("name") == "store": sku.childNodes[1].childNodes[5].setAttribute("value","Delhi,India") print sku.toxml() xml.dom.ext.PrettyPrint(dom, open("new.xml", "w")) a part of the Source XML: <node name='store' node_id='515' module='mpx.lib.node.simple_value.SimpleValue' config_builder='' inherant='false' description='Configurable Value'> <match> <property name='1' value='point'/> <property name='2' value='0'/> <property name='val' value='Store# 09204 Staten Island, NY'/> <property name='3' value='str'/> </match> </node> Final XML : <node config_builder="" description="Configurable Value" inherant="false" module="mpx.lib.node.simple_value.SimpleValue" name="store" node_id="515"> <match> <property name="1" value="point"/> <property name="2" value="0"/> <property name="val" value="Delhi,India"/> <property name="3" value="str"/> </match> </node>

    Read the article

  • java source code doubt

    - by abson
    this compiles class ex1 { public int show() { try { int a=10/10; return 10;} catch(ArithmeticException e) { System.out.println(e); } finally { System.out.println("Finally");} System.out.println("hello"); return 20; } } on the other hand this doesn't class ex15 { public int show() { try { int a=10/0; return 10;} catch(ArithmeticException e) { System.out.println(e); } finally { System.out.println("Finally"); return 40;} System.out.println("hello"); return 20; } } why is it so?

    Read the article

  • Doubt about django model API

    - by Clash
    Hello guys! So, here is what I want to do. I have a model Staff, that has a foreign key to the User model. I also have a model Match that has a foreign key to the User model. I want to select how much Matches every Staff has. I don't know how to do that, so far I only got it working for the User model. From Staff, it will not allow to annonate Match. This is what is working right now User.objects.annotate(ammount=Count("match")).filter(Q(ammount__gt=0)).order_by("ammount") And this is what I wanted to do Staff.objects.annotate(ammount=Count("match")).filter(Q(ammount__gt=0)).order_by("ammount") And by the way, is there any way to filter the matches? I want to filter the matches by a certain column. Thanks a lot in advance!

    Read the article

  • Echo autoincrement id doubt

    - by Marcelo
    Hi, can I print the id, even if it's autoincrement ? Because the way I'm doing I'm using an empty variable for id. $id= ""; mysql_connect(localhost,$username,$password); @mysql_select_db($database) or die ("Não conectou com a base $database"); mysql_query("INSERT INTO table1(id,...) VALUES ('".$id."',....)") or die(mysql_error()); mysql_close(); echo "Your id is :"; echo "".$id; I'm trying to print the id, but it's coming blank. I checked the table and there's an id number there. How can I print it then at? Thanks for the attention

    Read the article

  • NSNotification doubt?

    - by senthilmuthu
    hi, i am new Notification.what is the purpose of it... can we use [[NSNotificationCenter defaultCenter] addObserver without postNotification, If we can do it,how it is identified?what is the relationship between addObserver and postNotification?any one can explain in detail?

    Read the article

  • piping in UNIX doubt

    - by Happy Mittal
    In The Unix Programming Environment by K & P, it is written that " The programs in a pipeline actually run at the same time, not one after another. This means that programs in a pipeline can be interactive;" How can programs run at same time? For ex: $ who | grep mary | wc -l How grep mary will be executed until who is run or how wc -l will be executed until it knows results of previous programs?

    Read the article

  • amazon design doubt

    - by praveen
    I was looking at the amazon website and was wondering how one of the feature would have been implemented. The feature : what customers buy after viewing a particular item. If i were to develop such a feature i would probably generate a session id for each user session and store the session id-page id combination in a log file. and if a book is bought set a separate flag for the session id-page id. A separate program can then be run on the log file periodically, to identify the groups that were bought together/viewed together and that information can be stored in a persistent file. This is ofcourse a simple solution without taking into consideration the distributed nature of the servers - but would this suffice or can you help me identify a better design.

    Read the article

  • doubt about radio button mysql php beginner

    - by Marcelo
    Hi, i'm an engineering student and i'm developing a simple software based on html,php and mysql. I learned this topics on w3schools, i know only the basics. I tired to search about this in this website but I thought the doubts about php,mysql, radio buttons but they were much more complex than I need, and that i could understand. Sorry for the english. (Q1)Ex: $email=$_REQUEST['email'] , in this case the input is text, if it where like a radio button for ex: sex: male or female, how would it be? (Q2) what would be the type of this field (for exemple sex in question 1) in the database: text, int, varchar ? thanks for the attention

    Read the article

  • Doubt with c# handlers?

    - by aF
    I have this code in c# public void startRecognition(string pName) { presentationName = pName; if (WaveNative.waveInGetNumDevs() > 0) { string grammar = System.Environment.GetEnvironmentVariable("PUBLIC") + "\\SoundLog\\Presentations\\" + presentationName + "\\SpeechRecognition\\soundlog.cfg"; /* if (File.Exists(grammar)) { File.Delete(grammar); } executeCommand();*/ recContext = new SpSharedRecoContextClass(); recContext.CreateGrammar(0, out recGrammar); if (File.Exists(grammar)) { recGrammar.LoadCmdFromFile(grammar, SPLOADOPTIONS.SPLO_STATIC); recGrammar.SetGrammarState(SPGRAMMARSTATE.SPGS_ENABLED); recGrammar.SetRuleIdState(0, SPRULESTATE.SPRS_ACTIVE); } recContext.Recognition += new _ISpeechRecoContextEvents_RecognitionEventHandler(handleRecognition); //recContext.RecognitionForOtherContext += new _ISpeechRecoContextEvents_RecognitionForOtherContextEventHandler(handleRecognition); //System.Windows.Forms.MessageBox.Show("olari"); } } private void handleRecognition(int StreamNumber, object StreamPosition, SpeechLib.SpeechRecognitionType RecognitionType, SpeechLib.ISpeechRecoResult Result) { System.Windows.Forms.MessageBox.Show("entrei"); string temp = Result.PhraseInfo.GetText(0, -1, true); _recognizedText = ""; foreach (string word in recognizedWords) { if (temp.Contains(word)) { _recognizedText = word; } } } public void run() { if (File.Exists(System.Environment.GetEnvironmentVariable("PUBLIC") + "\\SoundLog\\Serialization\\Voices\\identifiedVoicesDLL.txt")) { deserializer = new XmlSerializer(_identifiedVoices.GetType()); FileStream fs = new FileStream(System.Environment.GetEnvironmentVariable("PUBLIC") + "\\SoundLog\\Serialization\\Voices\\identifiedVoicesDLL.txt", FileMode.Open); Object o = deserializer.Deserialize(fs); fs.Close(); _identifiedVoices = (double[])o; } if (File.Exists(System.Environment.GetEnvironmentVariable("PUBLIC") + "\\SoundLog\\Serialization\\Voices\\deletedVoicesDLL.txt")) { deserializer = new XmlSerializer(_deletedVoices.GetType()); FileStream fs = new FileStream(System.Environment.GetEnvironmentVariable("PUBLIC") + "\\SoundLog\\Serialization\\Voices\\deletedVoicesDLL.txt", FileMode.Open); Object o = deserializer.Deserialize(fs); fs.Close(); _deletedVoices = (ArrayList)o; } myTimer.Interval = 5000; myTimer.Tick += new EventHandler(clearData); myTimer.Start(); if (WaveNative.waveInGetNumDevs() > 0) { _waveFormat = new WaveFormat(_samples, 16, 2); _recorder = new WaveInRecorder(-1, _waveFormat, 8192 * 2, 3, new BufferDoneEventHandler(DataArrived)); _scaleHz = (double)_samples / _fftLength; _limit = (int)((double)_limitVoice / _scaleHz); SoundLogDLL.MelFrequencyCepstrumCoefficients.calculateFrequencies(_samples, _fftLength); } } startRecognition is a method for Speech Recognition that load a grammar and makes the recognition handler here: recContext.Recognition += new _ISpeechRecoContextEvents_RecognitionEventHandler(handleRecognition); Now I have a problem, when I call the method startRecognition before method run, both handlers (the recognition one and the handler for the Tick) work well. If a word is recognized, handlerRecognition method is called. But, when I call the method run before the method startRecognition, both methods seem to run well but then the recognition Handler is never executed! Even when I see that words are recognized (because they happear on the Windows Speech Recognition app). What can I do for the recognition handler be allways called?

    Read the article

  • Doubt regarding executable files in linux

    - by Chaitanya
    I have a program written in C, which is named computeWeight.c and to compile it i use the following code chaitu@ubuntu:~$ gcc -Wall -o computeWeight computeWeight.c //to execute it: chaitu@ubuntu:~$ ./computeWeight Do i have any mechansim where i can directly use as mentioned below, chaitu@ubuntu:~$ computeWeight Should i be changing any permissions on the executable to get this?

    Read the article

  • doubt in javascript name validation

    - by raja
    Hi: I am using the below validation for textbox which accepts only alphabets and maximum of 50 characters. I am passing the object directly in the parameter. The below case by giving the field name i.e "my_text" directly is working is working fine. But if i pass it in variable, that time it is not working(commented the if statement). Please help me. My requirement is each time when we enter the charater, the hardcode field name should not be used in the validation. <html><head> <script language=JavaScript> function check_length(my_form,fieldName) { alert(fieldName); // if (my_form.fieldName.value.length >= maxLen) { if (my_form.my_text.value.length >= maxLen) { var msg = "You have reached your maximum limit of characters allowed"; alert(msg); my_form.my_text.value = my_form.my_text.value.substring(0, maxLen); } else{ var keyCode = window.event.keyCode; if ((keyCode < 65 || keyCode > 90) && (keyCode < 97 || keyCode > 123) && keyCode != 32) { window.event.returnValue = false; alert("Enter only Alphabets"); } my_form.text_num.value = maxLen - my_form.my_text.value.length;} } </script> </head> <body> <form name=my_form method=post> <input type="text" onKeyPress=check_length(this.form,this.name); name=my_text rows=4 cols=30> <br> <input size=1 value=50 name=text_num> Characters Left </form> </body> </html>

    Read the article

  • Doubt in abstract classes

    - by mohit
    public abstract class Person { private String name; public Person(String name) { this.name = name; System.out.println("Person"); } public String getName() { return name; } abstract public String getDescription(); } public class Student extends Person { private String major; public Student(String name, String major) { super(name); this.major = major; } public String getMajor() { return major; } @Override public String getDescription() { return "student" + super.getName() + " having" + major; } } public class PersonTest { public static void main(String[] args) { Person person = new Student("XYZ", "ABC"); System.out.println(person.getDescription()); } } Ques: We cannot create objects of abstract classes, then why Person Constructor has been invoked, even its an abstract class?

    Read the article

  • gridview doubt asp.net

    - by user305678
    i want to load grid view as header with roles tablle horizontally and first column datafields with page table vertically and for other column datafields with these two table interaction the access table

    Read the article

  • Win7 64/32 bits c# dll doubt

    - by aF
    Hello, is it possible to build a c# dll and tlb files in a win7 64 bits computer and make it work in a win7 32bits computer? Thanks in advance :) Edit: I am using a c++ dll that calls the .tlb file generated in my c# COM interop dll proj.

    Read the article

  • Doubt about instance creation by using Spring framework ???

    - by Arthur Ronald F D Garcia
    Here goes a command object which needs to be populated from a Spring form public class Person { private String name; private Integer age; /** * on-demand initialized */ private Address address; // getter's and setter's } And Address public class Address { private String street; // getter's and setter's } Now suppose the following MultiActionController @Component public class PersonController extends MultiActionController { @Autowired @Qualifier("personRepository") private Repository<Person, Integer> personRepository; /** * mapped To /person/add */ public ModelAndView add(HttpServletRequest request, HttpServletResponse response, Person person) throws Exception { personRepository.add(person); return new ModelAndView("redirect:/home.htm"); } } Because Address attribute of Person needs to be initialized on-demand, i need to override newCommandObject to create an instance of Person to initiaze address property. Otherwise, i will get NullPointerException @Component public class PersonController extends MultiActionController { /** * code as shown above */ @Override public Object newCommandObject(Class clazz) thorws Exception { if(clazz.isAssignableFrom(Person.class)) { Person person = new Person(); person.setAddress(new Address()); return person; } } } Ok, Expert Spring MVC and Web Flow says Options for alternate object creation include pulling an instance from a BeanFactory or using method injection to transparently return a new instance. First option pulling an instance from a BeanFactory can be written as @Override public Object newCommandObject(Class clazz) thorws Exception { /** * Will retrieve a prototype instance from ApplicationContext whose name matchs its clazz.getSimpleName() */ getApplicationContext().getBean(clazz.getSimpleName()); } But what does he want to say by using method injection to transparently return a new instance ??? Can you show how i implement what he said ??? ATT: I know this funcionality can be filled by a SimpleFormController instead of MultiActionController. But it is shown just as an example, nothing else

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >