Daily Archives

Articles indexed Tuesday May 4 2010

Page 19/117 | < Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >

  • [asp.net-mvc] Html.DropDownList FindByValue in an Edit view?

    - by Pandiya Chendur
    I have an edit page with a Html.DropDownList in it.... I place the value in textbox but i cant show the dropdownlist value it always shows up with Select... Any suggestion how it can be done... <p> <label for="Mat_Name">Mat_Name:</label> <%= Html.TextBox("Mat_Name", Model.Mat_Name) %> <%= Html.ValidationMessage("Mat_Name", "*") %> </p> <p> <label for="MeasurementTypeId">MeasurementType:</label> <%= Html.DropDownList("MeasurementType", "Select")%> <%= Html.ValidationMessage("MeasurementTypeId", "*") %> </p>

    Read the article

  • Developers: How does BitLocker affect performance?

    - by Chris
    I'm an ASP.NET / C# developer. I use VS2010 all the time. I am thinking of enabling BitLocker on my laptop to protect the contents, but I am concerned about performance degradation. Developers who use IDEs like Visual Studio are working on lots and lots of files at once. More than the usual office worker, I would think. So I was curious if there are other developers out there who develop with BitLocker enabled. How has the performance been? Is it noticeable? If so, is it bad? My laptop is a 2.53GHz Core 2 Duo with 4GB RAM and an Intel X25-M G2 SSD. It's pretty snappy but I want it to stay that way. If I hear some bad stories about BitLocker, I'll keep doing what I am doing now, which is keeping stuff RAR'ed with a password when I am not actively working on it, and then SDeleting it when I am done (but it's such a pain).

    Read the article

  • How make decides to build target

    - by Michael
    One sign is that target does not exist, understand this. Another is by comparing modification timestamp of target and prerequisites. How it works in more details? What is the logic of comparing target and prerequisite timestamps and how it works when there are multiple prerequisites?

    Read the article

  • Storing the HTML output from a local PHP file into a string using file_get_contents

    - by bobo
    There is a header.php file and it contains some php codes that return HTML. I know I can use require, include to echo the results, but what I want to do is to store its processed output string into a variable. In a page, I used: $headerHTML=file_get_contents('header.php'); Then I got the PHP code output rather than the processed HTML output. I know adding http:// would help. But I prefer to keep using relative path, how can I tell the function to treat the php file correctly?

    Read the article

  • How and what benefit i can take from included Sizzle.js along with jquery 1.4.2?

    - by metal-gear-solid
    latest jquery 1.4.2 downloaded from jquery.com comes with Sizzle.js also. How and what benefit i can take from included Sizzle.js? /*! * jQuery JavaScript Library v1.4.2 * http://jquery.com/ * * Copyright 2010, John Resig * Dual licensed under the MIT or GPL Version 2 licenses. * http://jquery.org/license * * Includes Sizzle.js * http://sizzlejs.com/ * Copyright 2010, The Dojo Foundation * Released under the MIT, BSD, and GPL Licenses. * * Date: Sat Feb 13 22:33:48 2010 -0500 */

    Read the article

  • How to change the handler position by dragging/single click on the slider

    - by Geetha
    Hi All, I am using the following files to create a slider. Problem:Needs double click to change the handler position first click: it move the handler but the following code is not working. a second later it return back to the previous position. second click on the handler in new position, before it moves back the following code is working. Needs: I want change the media player current position with the handler current position value by dragging the handler or single click on the new position of the slider. Ex: initial position of the handler: l-------------------------------- document.mediaPlayer.currentPosition = 0 After dragging it some other position ----------------------l---------- document.mediaPlayer.currentPosition = 125 Code: var endTime = document.mediaPlayer.SelectionEnd; $("#slider-constraints").slider({ animate: true, max: endTime, range: $R(0, endTime), value: 1, enforceConstraints: false, start:function(event,index){document.mediaPlayer.currentPosition=index.value; $('#slider-constraints').slider("constraints", [0, index.value]); $('#slider-constraints').slider("value", index.value);} }); window.setInterval(function() { $('#slider-constraints').slider("value", document.mediaPlayer.currentPosition); }, 4000);

    Read the article

  • How do I use a custom #theme function to a fieldset in a drupal module?

    - by Rob Crowell
    I have a module that builds a form that includes a fieldset. Instead of using the <legend> element to render the fieldset title, I want to place this content in a <div> element instead. But I want to change the behavior only for the form returned by my module, so I don't want to place any new functionality into my theme's template.php file. In mymod.module I have defined: // custom rendering function for fieldset elements function theme_mymod_fieldset($element) { return 'test'; } // implement hook_theme function mymod_theme() { return array( 'mymod_fieldset' => array('arguments' => array('element' => NULL)), 'mymod_form' => array('arguments' => array()) ); } // return a form that is based on the 'Basic Account Info' category of the user profile function mymod_form() { // load the user's profile global $user; $account = user_load($user->uid); // load the profile form, and then edit it $form_state = array(); $form = drupal_retrieve_form('user_profile_form', $form_state, $account, 'Basic Account Info'); // set the custom #theme function for this fieldset $form['Basic Account Info']['#theme'] = 'mymod_fieldset'; // more form manipulations // ... return $form; } When my page gets rendered, I expected to see the fieldset representing 'Basic Account Info' to be wholly replaced by my test message 'test'. Instead what happens is that the <fieldset> and <legend> elements are rendered as normal, but with the body of the fieldset replaced by the test message instead, like this: <fieldset> <legend>Basic Account Info</legend> test </fieldset> Why doesn't my #theme function have the chance to replace the entire <fieldset> element? If I wrap a textfield in this function instead, I am able to completely replace the <input> element along with its label. Furthermore, if I provide an override in my site's template.php for theme_fieldset, it works as expected and I am able to completely replace the <fieldset>, so I know it is possible. What's different about providing #theme functions to fieldsets inside a module?

    Read the article

  • Python modules not updating after restarting the main module.

    - by Ian
    I've recently come back to a project having had to stop for about 6 months, and after reinstalling my operating system and coming back to it I'm having all kinds of crazy things happen. I made sure to install the same version(2.6) of python that I was using before. It started by giving me strange tkinter error that I hadn't had trouble with before, the program is relatively simple and the 2 or 3 bugs that were left when i quit, I had documented and weren't related to the interface. Things got even weirder when the same error would pop up even after I had removed the offending section of code. In fact, the traceback pointed to a line that didn't even exist in the module it was referencing, eg: line 262 when the module was only 200 lines long. After just starting a completely new file for the main module and copy/pasting it finally recognized that the offending code was gone and I stopped getting the error only to find that any updates to the code I made in another module didn't show up when I restarted the program through the shell. (I didn't forget to save.) After fiddling with this, of course, the old interface error came back, only in a different section of code that had been working previously. In fact, if I revert back to the files I had six months ago, the program works fine. As soon as I change anything in the main module, however, the interface bug comes back. Here's the original error: Exception in Tkinter callback Traceback (most recent call last): File "C:\Python26\lib\lib-tk\Tkinter.py", line 1410, in __call__ return self.func(*args) File "C:\PyStuff\interface.py", line 202, in dispOne __main__.top.destroy() File "C:\Python26\lib\lib-tk\Tkinter.py", line 1938, in destroy self.tk.call('destroy', self._w) TclError: can't invoke "destroy" command: application has been destroyed I'm guessing something else is going on here other than my own poor programming. Anyone have any ideas?

    Read the article

  • Linux core dumps are too large!

    - by themoondothshine
    Hey guys, Recently I've been noticing an increase in the size of the core dumps generated by my application. Initially, they were just around 5MB in size and contained around 5 stack frames, and now I have core dumps of 2GBs and the information contained within them are no different from the smaller dumps. Is there any way I can control the size of core dumps generated? Shouldn't they be at least smaller than the application binary itself? Binaries are compiled in this way: Compiled in release mode with debug symbols (ie, -g compiler option in GCC). Debug symbols are copied onto a separate file and stripped from the binary. A GNU debug symbols link is added to the binary. At the beginning of the application, there's a call to setrlimit which sets the core limit to infinity -- Is this the problem?

    Read the article

  • Visual Studio 2010 Installer Project - Text Input Validation

    - by LioKig
    Hi Everyone, I'm doing with Visual Studio 2010 Installer Project. I want users to enter an text input the installer will check if it is valid. If the text is NOT valid (somethings like emails), installer lets the users know and suggests re-enter the text. I could not find how to check the validation, anyone knows how to do, please help me.

    Read the article

  • Live Security Talk Webcast: Using Standards-Based Internet Explorer Features to Protect Apps (Level

    If you are building mashups and other web applications, what do you need to know to make sure that you are building secure applications that don't expose security vulnerabilities? What do you need to consider when building your applications using features from HTML 5, HTML 4.01, and important features of the browser? Attend this webcast to learn how to use standards-based Windows Internet Explorer features to protect the applications you develop....Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • Try Out the New Microsoft Desktop Player

    Microsoft Desktop Player allows developers to access technical content (such as videos, webcasts, podcasts, and white papers) and links to resources (including developer evangelists, local training opportunities, and local user groups) in your area. View it online or download the WPF application to view offline. Try it today!...Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • An Hour With Bill Buxton MIX10

    After spending a couple of hours with Rowan Simpson yesterday afternoon I found myself continually coming back to some of the things that Bill Buxton talked about in his hour Q&A at MIX10 in Las Vegas. Dont have Silverlight? Download the video in WMV, WMV (High) or MP4 format. At the more theoretical level, Bill discusses technology as a human prosthesis, but he favours metaphors that are as far away from technology as possible. The Seattle Public Library and software building....Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • ThinkPad T400 backlight doesn't always turn on when booting from battery

    - by srunni
    I have a Lenovo ThinkPad T400, which I've owned for about a year. A while back, I noticed a problem in which the LED backlight would not always turn on when booting from battery. Usually, if I hold the power button down until the BIOS screen shows up, the backlight turns, but sometimes even that doesn't work. If I just press the power button and let it go right away, the backlight usually doesn't turn on. This happens before the OS (I dual-boot Linux and Windows) gets a chance to boot - the BIOS screen itself is displayed without the backlight if it fails to turn on, so the problem isn't at the OS level. Any ideas? Thanks!

    Read the article

  • No internet connection for some programmes after installing ad hoc wireless network

    - by Michael
    After installing a wireless network (through the program iPhoneModem) several programmes have stopped working when connected to the Internet using another wireless connection. Working programmes: Firefox (browser) uTorrent (p2p) FileZilla (ftp) etc. Programmes that are not working: Chrome (browser) Digsby (IM client) etc. I'm running Windows 7. I have tried to disable Windows Firewall entirely as well as AVG anti virus, with no effect. I've tried to run the FixIt program from Microsoft adressing a corrupt TCP/IP stack. This too had no effect. Any suggestions?

    Read the article

  • error C2065: undeclared identifier

    - by karikari
    Currently, I have this function inside my other cpp file: UINT32 functionHtml(const wchar_t *url) { WinHttpClient client(url); client.SendHttpRequest(); wstring httpResponseHeader = client.GetHttpResponseHeader(); wstring httpResponse = client.GetHttpResponse(); writeToLog(httpResponse.c_str()); return 0; } I have another cpp file, and I would like to execute the stuff inside the above file. Here is the code for the other file: HRESULT CButtonDemoBHO::onDocumentComplete(IDispatch *pDisp, VARIANT *vUrl){ ATLTRACE("CButtonDemoBHO::onDocumentComplete %S\n", vUrl->bstrVal); // <---- i would like to call funtionHTML here or .. if (isMainFrame(pDisp)){ m_normalPageLoad=false; // <---- here.. MessageBox(m_hWnd, L"Main Document has completed loading", L"Document Complete", MB_OK); return S_OK; } return S_OK; } I got the error C2065: 'url' : undeclared identifier. Need help.

    Read the article

  • Can I use jQuery Ajax in a SharePoint WebPart without having to worry about the same origin policy?

    - by mythicdawn
    Hi all, My current project for work involves developing a SharePoint 2007 WebPart which will be deployed by our clients. To provide a better user experience, I am "simulating" AJAX via setting the SRC attirbute of an IFRAME to be the address of an HTTP handler. These handlers are deployed to the layouts directory in the 12 hive. Although this works, I would prefer to use the $get() method of jQuery. Will this work reliably in my scenario or will I still be subject to the same origin policy? What about the scenario where the WebPart is being deployed to various places on a SharePoint farm? Will there be any problems with using $get() in that case? Thank you!

    Read the article

  • How to Use Eclipse to Debug JNI code (Java & C/C++)

    - by tkryger
    While I can debug my application with the Eclipse JDT debugger for Java code and GDB for C code, I would prefer to use a single tool for all my debugging. I found several projects that enable "mixed-mode" debugging in Eclipse and include support for single stepping between Java and native code. Intel's Integrated Debugger for Java/JNI Environments Mariot Chauvin's Summer of Code Project: Support Seamless Debugging between JDT & CDT Unfortunately, one claims to be pre-release quality and the other is currently unmaintained. Are there any plug-ins that bring mixed mode debugging functionality to Eclipse in a reliable way or should I continue to use two separate debuggers?

    Read the article

  • Simple imeplementation of admin/staff panel?

    - by Michael Mao
    Hi all: A new project requires a simple panel(page) for admin and staff members that : Preferably will not use SSL or any digital ceritification stuff, a simple login from via http will just be fine. has basic authentication which allows only admin to login as admin, and any staff member as of the group "staff". Ideally, the "credentials(username-hashedpassword pair)" will be stored in MySQL. is simple to configure if there is a package, or the strategy is simple to code. somewhere (PHP session?) somehow (include a script at the beginning of each page to check user group before doing anything?), it will detect any invalid user attempt to access protected page and redirect him/her to the login form. while still keeps high quality in security, something I worry about the most. Frankly I am having little knowledge about Internet security, and how modern CMS such as WordPress/Joomla do with their implementation in this. I only have one thing in my mind that I need to use a salt to hash the password (SHA1?) to make sure any hacker gets the username and password pair across the net cannot use that to log into the system. And that is what the client wants to make sure. But I really not sure where to start, any ideas? Thanks a lot in advance.

    Read the article

  • Create an anonymous type object from an arbitrary text file

    - by Robert Harvey
    I need a sensible way to draw arbitrary text files into a C# program, and produce an arbitrary anonymous type object, or perhaps a composite dictionary of some sort. I have a representative text file that looks like this: adapter 1: LPe11002 Factory IEEE: 10000000 C97A83FC Non-Volatile WWPN: 10000000 C93D6A8A , WWNN: 20000000 C93D6A8A adapter 2: LPe11002 Factory IEEE: 10000000 C97A83FD Non-Volatile WWPN: 10000000 C93D6A8B , WWNN: 20000000 C93D6A8B Is there a way to get this information into an anonymous type object or some similar structure? The final anonymous type might look something like this, if it were composed in C# by hand: new { adapter1 = new { FactoryIEEE = "10000000 C97A83FC", Non-VolatileWWPN = "10000000 C93D6A8A", WWNN = "20000000 C93D6A8A" } adapter2 = new { FactoryIEEE = "10000000 C97A83FD", Non-VolatileWWPN = "10000000 C93D6A8B", WWNN = "20000000 C93D6A8B" } } Note that, as the text file's content is arbitrary (i.e. the keys could be anything), a specialized solution (e.g. that looks for names like "FactoryIEEE") won't work. However, the structure of the file will always be the same (i.e. indentation for groups, colons and commas as delimiters, etc). Or maybe I'm going about this the wrong way, and you have a better idea?

    Read the article

  • After making a call programatically, my android app crashes

    - by Casidiablo
    Hello! The title explains all... I have this snippet of code in my application: String url = createTelUrl("3112007315"); Intent intent = new Intent(Intent.ACTION_CALL); intent.setData(Uri.parse(url)); context.startActivity(intent); It does make a call, but once the call ends, my application crashes. I'd like to return to my application once the call has finished, but I read this post and it seems not to be possible. So... is there anyway to at least pause my application and resume it once the call has finished? Thank you so much for reading.

    Read the article

  • How to make dropdownlist show a selected value in asp.net mvc?

    - by Pandiya Chendur
    I have an edit page with a Html.DropDownList in it....I cant show the dropdownlist value it always shows up with Select instead i want to make the dropdown show an item as selected based on a model value say Model.Mes_Id... Any suggestion how it can be done... <p> <label for="MeasurementTypeId">MeasurementType:</label> <%= Html.DropDownList("MeasurementType", // what should i give here?)%> <%= Html.ValidationMessage("MeasurementTypeId", "*") %> </p> EDIT: It has the list items but i want to show a value selected in the edit view... public ActionResult Edit(int id) { var mesurementTypes = consRepository.FindAllMeasurements(); ViewData["MeasurementType"] = mesurementTypes; var material = consRepository.GetMaterial(id); return View("Edit", material); }

    Read the article

< Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >