Search Results

Search found 12061 results on 483 pages for 'non printable'.

Page 75/483 | < Previous Page | 71 72 73 74 75 76 77 78 79 80 81 82  | Next Page >

  • Permission denied: cannot call non-public or static methods remotely.

    - by rstat1
    Ok I've found a solution to this particular error message on here already. But my case is slightly different. There are no "non-public" or "static" methods in my code. All are public. What I'm trying to do is pass a FrameworkElement (more specifically a web browser control) that was created in one process over to another process for display and use. Also I'm not using (and would to avoid using) any of the framework 3.5 addin stuff. Fails at the following line everytime. fe = FrameworkElementAdapters.ContractToViewAdapter(tab.ReturnBrowserObject) tab.ReturnBrowserObject returns an INativeHandleContract which the above line is suppose to convert to a FrameworkElement.

    Read the article

  • What is a Perl regex for finding the first non-consecutively-repeating character in a string.

    - by DVK
    Your task, should you choose to accept it, is to write a Perl regular expression that for a given string, will return the first occurence of a character that is not consecutively duplicated. In other words, both preceded AND succeeded by characters different from itself (or start/end of string respectively). Example: IN: aabbcdecc OUT: c Please note that "not consecutively duplicated" does not mean "anywhere in the string". NOTE: it must be a pure regex expression. E.g. the solution that obviously comes to mind (clone the string, delete all the duplicates, and print the first remaining character) does not count, although it solves the problem. The question is inspired by my somewhat off-topic answer to this: http://stackoverflow.com/questions/2548606/perl-function-to-find-first-non-repeating-character-in-a-string

    Read the article

  • Is regex too slow? Real life examples where simple non-regex alternative is better

    - by polygenelubricants
    I've seen people here made comments like "regex is too slow!", or "why would you do something so simple using regex!" (and then present a 10+ lines alternative instead), etc. I haven't really used regex in industrial setting, so I'm curious if there are applications where regex is demonstratably just too slow, AND where a simple non-regex alternative exists that performs significantly (maybe even asymptotically!) better. Obviously many highly-specialized string manipulations with sophisticated string algorithms will outperform regex easily, but I'm talking about cases where a simple solution exists and significantly outperforms regex. What counts as simple is subjective, of course, but I think a reasonable standard is that if it uses only String, StringBuilder, etc, then it's probably simple.

    Read the article

  • Should primitive types or non-primitive types be preferred in Java interfaces?

    - by Greg Mattes
    (I thought I once read something about this in a book, but now I'm not sure where to find it. If this question reminds you of some material that you've read, please post a reference!) What are the pros and the cons of primitives in interfaces? In other words, is one of these preferable to the other and why? Perhaps one is preferable to the other in certain contexts? public interface Foo { int getBar(); } or public interface Foo { Integer getBar(); } Similarly: public interface Boz { void someOperation(int parameter); } or public interface Boz { void someOperation(Integer parameter); } Obviously there's the issue of having to deal with nulls in the non-primitive case, but are there deeper concerns?

    Read the article

  • is there a way to generate pdf containing non-ascii symbols with pisa from django template?

    - by mihailt
    Hi. i'm trying to generate a pdf from template using this snippet: def write_pdf(template_src, context_dict): template = get_template(template_src) context = Context(context_dict) html = template.render(context) result = StringIO.StringIO() pdf = pisa.pisaDocument(StringIO.StringIO(html.encode("UTF-8")), result) if not pdf.err: return http.HttpResponse(result.getvalue(), mimetype='application/pdf') except Exception('PDF error') but all non-latin symbols are not showing correctly, the template and view are saved using utf-8 encoding. i've tried saving view as ANSI and then to user unicode(html,"UTF-8"), but it throws TypeError. Also i thought that maybe it's because the default fonts somehow do not support utf-8 so according to pisa documentation i tried to set fontface in template body in style section. that still gave no results. Does any one have some ideas how to solve this issue?

    Read the article

  • Options for non-native form inputs for the web?

    - by Sam Lee
    I'm wondering if there are any good non-native form inputs for web development? I am currently using the built in <input> controls. They work just fine, but for my application they are too big (especially on OS X). I am wondering if there are any libraries that I can drop in as replacements. I am especially interested in ones that: Are a close to native control behavior as possible. Support for tabbing, highlighting current textbox, pressing up/down in <select>, etc. Have something that replicates <select> Look good and are compact I am aware that you can use CSS for some styling, but it's pretty minimal and looks different depending on the browser. Thanks for your help.

    Read the article

  • Is "non breaking change" a common term in revision control?

    - by mafutrct
    Non breaking change is a term used to describe minor contributions which are supposed to not break anything and is abbreviated as NBC. Typical example include formatting a source file or adding a comment - it really, really should not break the build (of course there are always exceptional cases). Is this a common term in revision control talk? I'm especially asking those familiar with RC systems. I use "NBC" on occasion but I never heard anyone else using it so I wondered... (btw: Don't trust wikipedia as a source on this)

    Read the article

  • How to lock non-browser clients from submitting a request?

    - by Thomas Kohl
    I want to block non-browser clients from accessing certain pages / successfully making a request. The website content is served to authenticated users. What happens is that our user gives his credentials to our website to 3rd party - it can be another website or a mobile application - that performs requests on his behalf. Say there is a form that the user fills out and sends a message. Can I protect this form so that the server processing the submission can tell whether the user has submitted it directly from the browser or not? I don't want to use CAPTCHA for usability reasons. Can I do it with some javascript?

    Read the article

  • Easy Way for Non-Nerd to Manage Simple Site?

    - by Mark Evans
    Hi I'm not sure if this is an appropriate question for StackOverflow. I have a friend show wants a simple "Brochure Ware" web site. I could make it for him but it would be better if he could manage it himself. Are there any services out there that allow a non-technical person to create and maintain a very simple site? I'm thinking just a few pages - contact, about, home with some photos and general info. He also wants to sell some stuff but I'm going to suggest he does this using EBay but the web site would be a handy reference for potential customers who want to know more about him and his services. Thanks a lot! Cheers Mark

    Read the article

  • How do I force SSL for some URLs and force non-SSL for all others?

    - by brad
    I'd like to ensure that certain URLs on my site are always accessed via HTTPS while all other URLs are accessed via HTTP. I can get either case working in my .htaccess file, however if I enable both, then I get infinite redirects. My .htaccess file is: <IfModule mod_expires.c> # turn off the module for this directory ExpiresActive off </IfModule> Options +FollowSymLinks AddHandler application/x-httpd-php .csv RewriteEngine On RewriteRule ^/?registration(.*)$ /register$1 [R=301,L] # Force SSL for certain URL's RewriteCond %{HTTPS} off RewriteCond %{REQUEST_URI} (login|register|account) RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L] # Force non-SSL for certain URL's RewriteCond %{HTTPS} on RewriteCond %{REQUEST_URI} !(login|register|account) RewriteRule ^(.*)$ http://%{HTTP_HOST}%{REQUEST_URI} [R=301,L] # Force files ending in X to use same protocol as initial request RewriteRule \.(gif|jpg|jpeg|jpe|png|ico|css|js)$ - [S=1] # Use index.php as the controller RewriteCond %{REQUEST_URI} !\.(exe|css|js|jpe?g|gif|png|pdf|doc|txt|rtf|xls|swf|htc|ico)$ [NC] RewriteCond %{REQUEST_URI} !^(/js.*)$ RewriteRule ^(.*)$ index.php [NC,L]

    Read the article

  • How do I assign a non-persistent (in-memory) cookie in ASP.NET?

    - by Jørn Schou-Rode
    The following code will send a cookie to the user as part of the response: var cookie = new HttpCookie("theAnswer", "42"); cookie.Expires = DateTime.Now.AddDays(7); Response.Cookies.Add(cookie); The cookie is of the persistent type, which by most browsers will be written to disk and used across sessions. That is, the cookie is still on the client's PC tomorrow, even if the browser and the PC has been closed in between. After a week, the cookie will be deleted (due to line #2). Non-persistent/in-memory cookies are another bread of cookies, which have a lifespan determined by the duration of the client's browsing session. Usually, such cookies are held in memory, and they are discarded when the browser is closed. How do I assign an in-memory cookie from ASP.NET?

    Read the article

  • What good timesheet should and shouldn't have for a small (non programming) 50 people company?

    - by MadBoy
    I'm sure most people here had to fill at least one time sheet in their life that made their life miserable, hell it's even the worst time taker ever especially after you have to fill it in hurry. I will be developing some simple TimeSheet application for a small company of 50 people (non programming related, it's actually 4 companies working together) and would like it to be user friendly and as less disturbing as possible. So what in your opinion makes it a good timesheet (lack of it doesn't count :p), what data it should store? Should be only hours per day with possibility to choose project, company and simple overview what you have worked on like: Day 1, 3:00, 'Company 1', 'Project5', 'Name', Short Overview Day 1, 5:00, 'Company 2', 'Project6', 'Name', Short Overview Or should it gather more data? Would it be realy bad if it were an WinForms application considering that I don't know ASP.NET or any other web based language? I would be deploying it using ClickOnce or so.

    Read the article

  • How to block non-browser clients from submitting a request?

    - by Thomas Kohl
    I want to block non-browser clients from accessing certain pages / successfully making a request. The website content is served to authenticated users. What happens is that our user gives his credentials to our website to 3rd party - it can be another website or a mobile application - that performs requests on his behalf. Say there is a form that the user fills out and sends a message. Can I protect this form so that the server processing the submission can tell whether the user has submitted it directly from the browser or not? I don't want to use CAPTCHA for usability reasons. Can I do it with some javascript?

    Read the article

  • Split string on non-alphanumerics in PHP? Is it possible with php's native function?

    - by Jehanzeb.Malik
    I was trying to split a string on non-alphanumeric characters or simple put I want to split words. The approach that immediately came to my mind is to use regular expressions. Example: $string = 'php_php-php php'; $splitArr = preg_split('/[^a-z0-9]/i', $string); But there are two problems that I see with this approach. It is not a native php function, and is totally dependent on the PCRE Library running on server. An equally important problem is that what if I have punctuation in a word Example: $string = 'U.S.A-men's-vote'; $splitArr = preg_split('/[^a-z0-9]/i', $string); Now this will spilt the string as [{U}{S}{A}{men}{s}{vote}] But I want it as [{U.S.A}{men's}{vote}] So my question is that: How can we split them according to words? Is there a possibility to do it with php native function or in some other way where we are not dependent? Regards

    Read the article

  • How can I detect if a file is binary (non-text) in python?

    - by grieve
    How can I tell if a file is binary (non-text) in python? I am searching through a large set of files in python, and keep getting matches in binary files. This makes the output look incredibly messy. I know I could use grep -I, but I am doing more with the data than what grep allows for. In the past I would have just searched for characters greater than 0x7f, but utf8 and the like make that impossible on modern systems. Ideally the solution would be fast, but any solution will do.

    Read the article

  • Send javax.mail.internet.MimeMessage to a recipient with non-ASCII name?

    - by phyzome
    I am writing a piece of Java code that needs to send mail to users with non-ASCII names. I have figured out how to use UTF-8 for the body, subject line, and generic headers, but I am still stuck on the recipients. Here's what I'd like in the "To:" field: "????????????" <[email protected]>. This lives (for our purposes today) in a String called recip. msg.addRecipients(MimeMessage.RecipientType.TO, recip) gives "?????S]" <[email protected]> msg.addHeader("To", MimeUtility.encodeText(recip, "utf-8", "B")) throws AddressException: Local address contains control or whitespace in string ``=?utf-8?B?IuOCpuOCo+OCreODmuODh+OCo+OCouOBq+OCiOOBhuOBk+OBnSIgPA==?= =?utf-8?B?Zm9vQGV4YW1wbGUuY29tPg==?='' How the heck am I supposed to send this message?

    Read the article

  • What is better for non-active directory stuff, WMI or ADSI?

    - by nbolton
    I've used both technologies in C# for some time now and thus far have not been able to figure out which is better (in terms of ease of use). It seems to me that because there is support for Windows 95 in WMI, it's an older technology than ADSI (which I assume was invented along with Active Directory). However, despite the hint that ADSI is "for AD", I've used it for several non-AD things, such as managing IIS and local users. So, for those sort of tasks (managing IIS and local users), which is more practical? WMI or ADSI? Consider also that I'm using C# to implement these technologies, not vbscript. However, this may equally apply to vbscript.

    Read the article

  • IE's responseXML.getElementsByTagName() unable to handle non English character ?

    - by trix
    I have a javascript that does this (http is your XMLHttpRequest object) var r = http.responseXML.getElementsByTagName('item'); The issue is variable r is always an empty list if the response contains non-English character (r.length is 0). The response header is correctly set Content-Type: text/xml;charset=ISO-8859-1 This is what the response from the webserver looks like <?xml version='1.0' encoding='UTF-8'?> <d> <r> <item value="jmob" label="John Möb"/> </r> </d> It happens only in IE (both IE6 and IE8), works in Firefox and Chrome. If items contain only English characters, it works fine. Is there a workaround for this ?

    Read the article

  • Is it advisable to have non-ascii characters in the URL?

    - by Ravi Gummadi
    We are currently working on a I18N project. I was just wondering what are the complications of having the non-ascii characters in the URL. If its not, what are the alternatives to deal with this problem? EDIT (in response to Maxym's answer): The site is going to be local to specific country and I need not worry about the world wide public accessing this site. I understand that from usability point of view, It is really annoying. What are the other technical problem associated with this?

    Read the article

  • Javascript - cannot make static reference to non-static function ....

    - by Ankur
    I am making a reference to the Javascript function splice() on an array and I get the error: "Cannot make a static reference to the non-static function splice()" What's going on - how is this a static reference, aren't I referencing an instance of an Array class and its method - how is that static? $(document).ready( function() { var queryPreds = new Array(); var queryObjs = new Array(); function remFromQuery(predicate) { for(var i=0; i<arrayName.length;i++ ) { if(queryPreds[i]==predicate) queryPreds.splice(i,1); queryObjs.splice(i,1); } } }

    Read the article

  • Can I use a single MySQL query to select distinct rows and then non-distinct rows if a limit hasn't

    - by Matt Rix
    I hope I'm explaining this properly, my knowledge of MySQL is quite limited. Let's say I have a table with rows that have name and shape fields. I'd like to select a bunch of rows from a table, but return all of the rows with unique shape field values first. If I have less than a certain number of rows, let's say 7, then I'd like to fill the remaining result rows with non-unique shape rows. The best way I can word it is that they're "ordered by uniqueness, and then by some other value". So, I don't want: square, square, circle, circle, rectangle, square, triangle I'd like to have: square, circle, rectangle, triangle, square, square, circle Is this possible to do using a single SQL query? I'm using MySQL with PHP, if that makes any difference. Thanks!

    Read the article

  • Undefined behaviour with non-virtual destructors - is it a real-world issue?

    - by Roddy
    Consider the following code: class A { public: A() {} ~A() {} }; class B: public A { B() {} ~B() {} }; A* b = new B; delete b; // undefined behaviour My understanding is that the C++ standard says that deleting b is undefined behaviour - ie, anything could happen. But, in the real world, my experience is that ~A() is always invoked, and the memory is correctly freed. if B introduces any class members with their own destructors, they won't get invoked, but I'm only interested in the simple kind of case above, where inheritance is used maybe to fix a bug in one class method for which source code is unavailable. Obviously this isn't going to be what you want in non-trivial cases, but it is at least consistent. Are you aware of any C++ implementation where the above does NOT happen, for the code shown?

    Read the article

  • Non-Latin characters in URLs - is it better to encode them or replace with their Latin "counterparts

    - by Pawel Krakowiak
    We're implementing a blog for a site which supports six different languages and five of them have non-Latin characters in their alphabets. We are not sure whether we should have them encoded (that is what we're doing at the moment) Létání s potravinami: Co je dovoleno? becomes l%c3%a9t%c3%a1n%c3%ad-s-potravinami-co-je-dovoleno and the browser displays it as létání-s-potravinami-co-je-dovoleno. or if we should replace them with their Latin "counterparts" (similar looking letters) Létání s potravinami: Co je dovoleno? becomes letani-s-potravinami-co-je-dovoleno. I can't find a definitive answer as to what's better from SEO perspective? Search engine optimization is very important for us. Which approach would you suggest?

    Read the article

  • Beginner C: error: control reaches end of non-void function?

    - by Ting
    I'm trying to make a greedy algorithm and I get this error: greedy2.c:27:1: error: control reaches end of non-void function [-Werror,-Wreturn-type] } ^ 1 error generated. with this code: int man(int argc, char* argv[]) { float amount; do { printf("Input dollar amount owed:\n"); amount = GetFloat(); } while (amount <= 0); int coins = 0; while (amount >= 0.25); { amount = amount - 0.25; coins++; } printf("Number of coins to use: %d\n", coins); } What is wrong with my curly braces, and how do I fix it?

    Read the article

  • Warning: non-integer #successes in a binomial glm! (survey packages)

    - by longrob
    I am using the twang package to create propensity scores, which are used as weigtings in a binomial glm using survey::svyglm. The code looks something like this: pscore <- ps(ppci ~ var1+var2+.........., data=dt....) dt$w <- get.weights(pscore, stop.method="es.mean") design.ps <- svydesign(ids=~1, weights=~w, data=dt,) glm1 <- svyglm(m30 ~ ppci, design=design.ps,family=binomial) This produces the following warning: Warning message: In eval(expr, envir, enclos) : non-integer #successes in a binomial glm! Does anyone know what I could be doing wrong ? I wasn't sure if this message would be better on stats.SE, but on balance I thought I would try here first.

    Read the article

< Previous Page | 71 72 73 74 75 76 77 78 79 80 81 82  | Next Page >