Daily Archives

Articles indexed Tuesday May 11 2010

Page 26/123 | < Previous Page | 22 23 24 25 26 27 28 29 30 31 32 33  | Next Page >

  • String Manipulation.

    - by Harikrishna
    I will have a different type of string(string will not have fixed format,they will be different every time) from them I want to remove some specific substring.Like the string can be FUTIDX 26FEB2009 NIFTY 0 FUTSTK ONGC 27 Mar 2008 FUTIDX MINIFTY 30 Jul 2009 FUTIDX NIFTY 27 Aug 2009 NIFTY FUT XP: 29/05/2008 Actuall I want the string from every string defined above like NIFTY-FEB09 ONGC-MAR08 MINIFTY-JUL09 NIFTY-AUG09 NIFTY-MAY08 How can I do that ?

    Read the article

  • Did anybody use the constream (constrea.h) lib?

    - by user337938
    Two years ago, I used the conio.h (actually conio2.h for Dev-C++) to create a console form interface. Now I want to make the same thing, but C++ std lib does not provide the needed functions and I don't want to use the old C conio lib. I found some websites which highlights the constream lib, but I have no idea to use it on VS! I tried just copying the header file into my project, but VS show several erros. I believe I am doing something wrong. ps: i got this file: ftp://ftp.cs.technion.ac.il/pub/misc/baram/TC31/INCLUDE/CONSTREA.H

    Read the article

  • How to hide Amazon webstore default toolbar with Prototype?

    - by melaos
    Hi Guys, after playing around this morning, i've found that there's this default chunk of html code in the amazon webstore which will add a toolbar on top of the page. the html looks like below: <td id="wba_logo_bg"> <table class="logo" border="0" cellpadding="0" cellspacing="0" width="100%"> <tbody><tr><td align="left"></td> <td class="wba_account" style="padding: 5px;" align="right" valign="top"> <table border="0" cellpadding="0" cellspacing="0"> <form action="#" id="searchForm" method="get" name="searchForm"></form> <tbody><tr><td class="wba_account_link"> <a xmlns:xhtml="http://www.w3.org/1999/xhtml" class="myAccountNav" href="#" onclick="return false;">home</a></td> <td class="myAccountDots"></td> <td class="wba_account_link"><a class="myAccountNav" href="#" onclick="return false;">view cart</a></td> <td class="myAccountDots"></td><td class="wba_account_link"><a class="myAccountNav" href="#" onclick="return false;">my account</a></td> <td class="myAccountDots"></td><td class="wba_account_link"><a class="myAccountNav" href="#" onclick="return false;">order status</a></td> <td><img src="pageEditor_files/1_pixel.gif" hspace="7"></td> <td><input name="keyword" tabindex="1" type="text"></td> <td><img alt="Search" class="wba_search_btn" onclick="return false;" onkeyup="if (13==event.keyCode) searchForm.submit();" src="pageEditor_files/btn_search.gif" style="cursor: pointer;" tabindex="2" title="Search" hspace="3"> </td></tr></tbody> </table> </td></tr></tbody> </table> </td> and thus far i was able to use prototype to find those with the class name of wba_account_link and hide them via the codes below: function hideAmazonToolbar() { $("wba_logo_bg").hide(); }//end function but what i really want to do is preferably to hide the whole tbody instead, but with my limited prototype skills, i don't really know how to do this. can anybody point me to the right resources on how to get this done? thanks! EDIT Went higher up and apparently there's a td with an id, and solve it using prototype hide function! man, i love javascript framework :) thanks :)

    Read the article

  • using time() to measure how long a function takes

    - by hap497
    Hi, I am trying to use time() to measure various points of my program. http://www.cplusplus.com/reference/clibrary/ctime/time/ What I don't understand is why the values in the before and after are Different? I understanding this is not the best way to profile my program, I just want to see how long does something take. printf ("**MyProgram::before time= %ld\n", time(NULL)); doSomthing(); doSomthingLong(); printf ("**MyProgram::after time= %ld\n", time(NULL)); Thank you.

    Read the article

  • passing custom object as parameter to a webmethod of asp.net web service

    - by Jon
    Hi, I have a custom class declared as follows (in vb.net) <Serializable()> _ Public Class NumInfo Public n As String Public f As Integer Public fc As char() Public t As Integer Public tc As char() Private validFlag As Boolean = True Public Sub New() End Sub 'I also have public properties(read/write) for all the public variablesEnd Class In my service.asmx codebehind class I have a webmethod as follows: <WebMethod()> _ <XmlInclude(GetType(NumInfo))> _ Public Function ConvertTo(ByVal info As NumInfo) As String Return mbc(info)'mbc is another function defined in my service.asmx "service" class End Function The problem is that when I start debugging it to test it, the page that I get does not contain any fields where I could input the values for the public fields of numInfo. How do I initialise the class? There is no "Invoke" button either. All I see are soap details as below: ConvertToTestThe test form is only available for methods with primitive types as parameters.SOAP 1.1The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.POST /Converter/BC.asmx HTTP/1.1Host: localhostContent-Type: text/xml; charset=utf-8Content-Length: lengthSOAPAction: "http://Services/ConvertTo"<?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <ConvertTo xmlns="http://Services/"> <info> <n>string</n> <f>int&lt/f> <fc> <char>char</char> <char>char>/char> </fc>..etc.. What am I doing wrong? For the record I tried replacing char() with string to see if it was the array causing problems but that didn't help either. I'm fairly new to web services. I tried replacing the custom object parameter with a primitive parameter just to check how things worked and it rendered a page with an input field and invoke button. I just can't seem to get it working with custom object. Help!

    Read the article

  • How to dynamically show/hide rows in a table

    - by pradeep
    I'm working on a website where I need to show/hide table rows. I got the feature working, but the CSS gets bad when I do show. I'm providing a working link; click the 'More...' link and see the action for an example. I'm using jQuery's toggle(slow) for hiding and showing

    Read the article

  • RDLC Report Viewer Drill Through Report

    - by Abhishek
    I had posted this question on MSDN Forum http://social.msdn.microsoft.com/Forums/en/vsreportcontrols/thread/f00e3406-354d-4f54-acce-7b7f0ad4c90f But I am not getting any response. Can you please help me. I am really stuck with this rather simple task. My code seems to be correct but still I get the A data source instance has not been supplied for the data source 'DataSet1_Order_Details'. Sorry for the cross post...

    Read the article

  • Security issues of running PHP scripts as the owner of the PHP file with suexec

    - by thomasrutter
    I'm using suexec to ensure that PHP scripts (and other CGI/FastCGI apps) are run as the account holder associated with the relevant virtual host. This allows for securing each users' scripts from reading/writing by other users. However, it occurs to me that this opens up a different security hole. Previously, the web server ran as an unprivileged user, with read-only access to user's files (unless the user changed the file permissions for some reason). Now, the web server can also write to user's files. So while I've prevented different users taking advantage of each other's scripts, I've made it so that in the event that some application has a remote code injection vulnerability, it now has not only read access but also write access to all that user's scripts and website. How can I deal with this? One idea I've had is to create a second user account for each user account in the system, so that each user has their own user account, and all their scripts are run under another user account. But that seems cumbersome.

    Read the article

  • How change ubuntu remote desktop setting from terminal

    - by Mirage
    MY Remote desktop was working when i had no security or authentication enabled un ubuntu. I go to preferences then remote desktop and then uncheck all checkboxes in security tab. I tried enabling password and now i can connect to server. I don't have access to server. is there any way to clear the security setting via terminal

    Read the article

  • Xcode / Interface Builder - better workflow from designer to coder?

    - by tbarbe
    Were dealing with some pretty custom UI elements while building our OSX / Cocoa and iPhone / IPad apps. I was wondering if anyone has good recommendations or tricks for getting a better workflow between UI designers and coders while using Xcode / Interface Builder? It seems that many things require programmatic settings with UI editing in Cocoa... if you stray from the pre-built UI elements then you can't really easily drag-drop build a UI... instead we end up handing off a design doc ( photoshop/illustrator ) and then the poor developer has to deal with recreating this masterpiece in code or by using interface builder - usually a combination of both. This work flow is leading us to not so great results and we have to re-iterate around the UI elements to get them to work better. We love CSS and / or Flash designer to developer workflow where the UI could look exactly as it should and the hand off to developer was more seamless. Is there anyone out there who has some tricks - or insights into getting better workflow when using tools like Xcode / Interface Builder and doing Cocoa apps?

    Read the article

  • How to remove the domain name?

    - by Dilse Naaz
    Hi I have one sharepoint application, in this i have to show the current user, i used SPContext.Current.Web.CurrentUser.LoginName. then it returns XXXXXX\abida. But i want only the username like abida. How to achieve this requirement?

    Read the article

  • open a link in a new tab in the same window

    - by encryptor
    Hi I am making a firefox extension which needs to open a link in anew tab in the same window of firefox. How should i do this? This opens in a new window (replacing the old window): window.location = url; This opens in the same tab window.content.document.location = url Any idea on how to open the url in a new tab?

    Read the article

  • How to execute maven tasks in eclipse (Sonatype plugin)

    - by Bruce
    Hi all I know it must be something simple, but I just can't figure it out.. I'm using the Sonatype maven plugin on eclipse. When I want to build a war file for a webapp project, the only way I know to do it is to use the command line and type mvn package. I've looked all through the right click menu and I can't find any way to do it from eclipse. There's a maven submenu that seems to have no options to do with building, and there's a run menu that doesn't seem right - I don't want to run my project - I just want to build it. There is a maven build option in the run menu, but if I run it, a configuration window pops up for me to enter goals in.. How I do I just do a simple mvn package, but through gui? What am I missing? Thanks!

    Read the article

  • Qt and Bluetooth on Symbian S60

    - by belhaouary
    Hi all, i am working on a mobile application which needs to use bluetooth to send a file to another mobile device. I'm using Qt for symbian. my problem is that Qt doesn't provide ready to use API for bluetooth.Only Qt extended(which runs on embedded linux) has API for bluetooth. Do you have a clue to use bluetooth from Qt on symbian platform? Thanks in advance

    Read the article

  • Question about Reporting and Data Warehousing Software bundled with SQL Server 2005

    - by anonymous user
    We currently use SQL Server 2005 Enterprise for our fairly large application, that has its roots in pre SQL Server 7.0. The tables are normalized and designed mainly for the application. The developers for the most part have the legacy SQL Server mindset. Only using the part of TSQL that existed back in 7.0, not using any of the new features of tsql or that are bundled with 2005. We're currently trying to build on demand reports using some crappy third party software, and will eventually try to build a data warehouse using more of the same crappy third party software (name removed to protect the guilty, don't ask I will not tell). The rationale for this was that we didn't want to spend more money to buy this additional software from Microsoft (this was not my decision, I had no input, but is my problem now). But from what I can tell is that Enterprise includes all of these tools, or am I missing something? What comes bundled with SQL Server 2005 Enterprise as far as reporting and data warehousing? Will we need to purchase anything else? is there actually anything else that can be purchased from Microsoft in this regard?

    Read the article

  • Future proof Primary Key design in postgresql

    - by John P
    I've always used either auto_generated or Sequences in the past for my primary keys. With the current system I'm working on there is the possibility of having to eventually partition the data which has never been a requirement in the past. Knowing that I may need to partition the data in the future, is there any advantage of using UUIDs for PKs instead of the database's built-in sequences? If so, is there a design pattern that can safely generate relatively short keys (say 6 characters instead of the usual long one e6709870-5cbc-11df-a08a-0800200c9a66)? 36^6 keys per-table is more than sufficient for any table I could imagine. I will be using the keys in URLs so conciseness is important.

    Read the article

  • how to implement a sparse_vector class

    - by Neil G
    I am implementing a templated sparse_vector class. It's like a vector, but it only stores elements that are different from their default constructed value. So, sparse_vector would store the index-value pairs for all indices whose value is not T(). I am basing my implementation on existing sparse vectors in numeric libraries-- though mine will handle non-numeric types T as well. I looked at boost::numeric::ublas::coordinate_vector and eigen::SparseVector. Both store: size_t* indices_; // a dynamic array T* values_; // a dynamic array int size_; int capacity_; Why don't they simply use vector<pair<size_t, T>> data_; My main question is what are the pros and cons of both systems, and which is ultimately better? The vector of pairs manages size_ and capacity_ for you, and simplifies the accompanying iterator classes; it also has one memory block instead of two, so it incurs half the reallocations, and might have better locality of reference. The other solution might search more quickly since the cache lines fill up with only index data during a search. There might also be some alignment advantages if T is an 8-byte type? It seems to me that vector of pairs is the better solution, yet both containers chose the other solution. Why?

    Read the article

  • Cannot send value to paypal

    - by preetu
    Hi PayPal IPN sends a notification to your script directly. Since the notification is coming from PayPal - NOT the customer that placed the order - My Login session doesn't exits this context .Therefore,all my login data doesn't exist in the session.I need my login session values to update my DB with paypal ipn value.How should i mentain my login session should i set browser session or other way can i send login primary key to paypal.

    Read the article

< Previous Page | 22 23 24 25 26 27 28 29 30 31 32 33  | Next Page >