Posts

Showing posts from July, 2013

c# - Entityframework 4.0 .CreateQuery<T> and OrderBy exception -

I thought it was fixed in 4.0. I have this method public IQueryable & lt; T & gt; All (expression & lt; funk & lt; t, object & gt; & gt; sort) {EntityContext.Creatate & quot; T & gt; (EntityName). Eskenable & lt; T & gt; (). Respectively (sort); } Unable to type 'System.Object' for the following throws an exception type 'System.Int32'. LINQ only supports entity-type model model primitive type casting for units. Source System.Data.Entity Any ideas how to fix or if it is no way it happens with every call, while the Order string is not datatype IQueryable & LT; Blog & gt; All sorted = _pozitory.all (x = & gt; x.Title); Since the title is a string by which the order works fine. But it fails with any other datatypes Since I had come up with the "bad" solution before the mark I thought I would post it public IQueryable & lt; T & gt; All (expression & lt; funk & lt; t, obje

runtime error - exception in thread "main" java.lang.NoclassDefFoundError: cal/class -

आयात करें java.io. * दर्ज करें; वर्ग eval {डबल जोड़ (डबल ए, डबल ख) {वापसी (ए + बी); } डबल उप (डबल ए, डबल ख) {रिटर्न (ए-बी); } डबल मुल (डबल ए, डबल ख) {रिटर्न (ए * बी); } डबल डिव (डबल ए, डबल बी) {रिटर्न (ए / बी); }} क्लास कैल eval {public static void main (स्ट्रिंग एजीआर []) IOException फेंकता {eval a1 = new eval ()); कोशिश {System.out.println ("1) जोड़ें"); System.out.println ("2) घटाना"); System.out.println ("3) गुणा"); System.out.println ("4) विभाजित"); System.out.println ("5) अपनी पसंद दर्ज करें"); बफ़रेड्ड रीडर br = नया बफ़्टेड रीडर (नया इन्पुटस्ट्रीमरेडर (सिस्टम।)); Int ch; ch = पूर्णांक। पैरासेन्ट (ब्र्रेडलाइन ()); System.out.println ("दो नंबर दर्ज करें"); डबल ए; ए = इंटीजर। पीर्सआईंट (ब्र्रेडलाइन ()); डबल बी; बी = इंटिजर .परसेन्ट (ब्र्रेडलाइन ()); स्विच (सीए) {मामला 1: ए 1.एड (ए, बी); टूटना; मामले 2: ए 1.sub (ए, बी); टूटना; मामले 3: a1.mul (ए, बी); टूटना; मामला 4: ए 1 डीवायव (ए, बी); टूटना; }} पकड़ (IOException ई) {

graphics - Problem when trying to use simple Shaders + VBOs -

Hello I'm trying to convert the following function to a VBO based function for the purpose of learning, on this screen Displays a steady texture. I'm using OpenGL ES 2.0 with Shaders on the iPad (in this case, it should be almost identical with Regular OpenGL), this is what I have worked: // Works! - (zero) Drawpoint: (CP point) Depth of point: (CGFLOT) Depth {GL Float coordinate [=] 0, 1, 1, 1, 0, 0, 1, 0}; GLFlot width = (GL float) _ width * _ MaxS, height = (GL float) _height * _maxy; GLfloat Corner [] = {-width / 2 + point.x, -height / 2 + point.y, width / 2 + point.x, -height / 2 + point.y, -width / 2 + point.x, Height / 2 + point.or, width / 2 + point.x, height / 2 + point.i,}; Globindactments (GL_design DD, _name); // Attrib condition and attrib_texen coordination, handles for shaver attributes glavitaxe attribute pointers (ATTRIBO_POSITION, 2, GL_Flat, GL_FLSE, 0, Cortis); GlEnableVertexAttribArray (ATTRIB_POSITION); GlVertexAttribPointer (ATTRIB_TEXCOORD, 2, GL_

downgrade - Restoring older firmware through XCode? -

I am trying to restore the 3GS to the iPhone OS 3.1.3 which has been upgraded to iOS 4. Reject the fulfillment of iTunes What needs to be done? I am currently using GM XCode, should I use the latest public stable version instead? Update: XCode reports that "baseband can not be recovered." There are some answers. BlackRa1n gets iPhone out of reboot loop after failed baseband rollback.

Most efficient way to have a 50 state drop down box in Drupal Forms -

I know that in a way there is a table in the database with all states and then you will read it in your form. Is there any easy way for people in your opinion? I feel that doing something like this is bad because it is so elementary, but I think that something like simple will be implemented in Drupal already. There is no need to hit the database, create yourself a task that is one of the states Returns the array. $ form ['state'] = array ('#type' = & gt; select ',' #options' = & gt; Mymodule_states_list (), '# title' = & Gt; t ('state'),); Function mymodule_states_list () {Returns array ('AL' => 'Alabama', 'A' '>' Alaska ', ...' WY '=>' Wyoming ',); }

Log4Net: How to specify different level to separate appenders for ASP.NET -

For Log4Net used in ASP.NET, I see the Web. How can I specify different levels to separate the attendants in the config? Thank you. Here's a pure idea to play. Documentation & amp; Thought, this could be the way to do this. Note: debug level message console & amp; Level messages are logged in the Warning event. I hope this works :) & lt; Log4net & gt; & Lt ;! - A1 is a console adapter set - & gt; & Lt; Appender Name = "A1" type = "log4net.Appender.ConsoleAppender" & gt; & Lt ;! - A1 uses PatternLayout - & gt; & Lt; Layout type = "log4net.Layout.PatternLayout" & gt; & Lt; Conversion value = "% - 4timestamp [% thread]% -5 level% logger% ndc -% message% newline" /> & Lt; / Layout & gt; & Lt; / Appender & gt; & Lt; Appender name = "Event logic" type = "log4net.Appender.EventLogAppender" & gt; & Lt; Layout type = "log4

Rsa Cryptography in c#. i have encrypted an xml file and saved it -

I encrypted an XML file and saved it in cryptographic cryptography C #. After that I transferred this file to another PC. The main problem is that it is not a DNS, D decrypt. why not? When the MIM decrypts on the same machine, the XML file decrypts. public static byte [] decryptfile (XML document dock, RSA RSAK, string keyname) / P> doctor = new XmlDocument (); Doc.PreserveWhitespace = True; Doc.Load (@ "MLPACK1.xml"); Encrypted Xml Encocolx = New Encrypted XML (Doctor); Encoxm.ADKNememapapping (name, RSAK); EncXml.DecryptDocument (); String contentoffdid = Doc.OuterXml; Byte [] buffer = strawberry array (contentofdecution); Return buffer; } You used (....) the third parameter scope of the method method (Enum) type. It seems that you have defined DataProtectionScope.LocalMachine (or even DataProtectionScope.CurrentUser) for DTP and passed it to secure the method. Like it Data ProtectionCheckDPS = DataTransactionScope Localmachine Protected Data Protec

javascript - Cancel the keydown in HTML -

How can I cancel the keydown of a specific key on the keyboard, for example ( Enter the space in an HTML page and arrow ). If you are interested only in the example tricks you mentioned, keydown event Except the old, pre-opted versions of Opera (except for version 12, and at least with), where you have to cancel the keypress event keypress In the keydown event, it is very easy to reliably identify non-printable keys, so the following Uses a variable to set in keydown in order to tell the handler to questions handler to see if the default behavior is suppressed or not. var cancellationpress = wrong; Document.onkeydown = function (evt) {evt = evt || Window.event; Canceled Keypress = / ^ (13 | 32 | 37 | 38 | 39 | 40) $ / trial ("+ + + evt.keyCode); if (cancel the KApr) {return false;}}; / * Opera * / Document.onkeypress = function (evt) {if (cancel kaypress) {return false;}};

How to set up Django app to make cookies work on subdomain -

I posted my application on subdomain.domain.com (this only works on a subdomain) Everything this fact Works fine except that users can not log into the application from time to time (message "It seems that your browser is not configured to accept cookies. Please enable cookies, this page Please reload and retry " in the admin panel Is shown while attempting to log in). I have seen that restarting the web server for some time ends this problem. Is anyone experiencing the setting of the Django project on a subdomain and can direct me to reset it sometimes to work properly without any need? I tried to set up the SESSION_COOKIE_DOMAIN = 'subdomain.domain.com' setting but did not resolve the problem (maybe I set it to false?) < P> I use Django 1.1.1, Python 2.5.4 for this project. The project is deployed in the provider. I use it for other projects and cookies work perfectly there also run on other project sub-domains and you do not have SESSION_COOKIE_DOM

Changing JSON response root node message in WCF -

I have created a certain gate-time service in WCF and the service returns Jason as a response message. In addition to this WebMessageBodyStyle is set to wrap, so it will be the id related to the data that it gives. But when I use the filer to test my service, the response string is: {"GetTimeResult": "2010614104013"} GetTimeResult of the string as response above the ID, I am thinking that there is no way to change that test of the timestamp. So it looks like this: {"timestamp": "2010614104013"} Cheers. If you are using the data contract / datmail attribute in your code, As well as some other named parameters). [Datamember (name = "timestamp")] Public string GetTimeResult

persistence - ActiveMQ - Removing queues programatically -

फ़ेलो स्टैक ओव्हरफ्लॉवर, क्या ऐपटीएमक में कतार या एक विषय को प्रोग्रामेटिक रूप से निकालने का कोई तरीका है? मैं ActiveMQ के मानक निरंतरता का उपयोग कर रहा हूं, और मेरे आवेदन की आवश्यकता है कि, स्टार्टअप पर, सभी नई कतारें गतिशील रूप से फिर से बनाई गई हैं (जब तक कि कतार में संग्रहीत संदेश न हो, उस स्थिति में, कतार में मौजूद रहना चाहिए)। मैं सत्रों के माध्यम से सभी कतारों को प्रोग्रामैटिक रूप से बना रहा हूं क्या उस प्रक्रिया के बराबर है, केवल कतार को हटाना? मौजूदा कतारों से पूछताछ और पुनरावृत्ति करना भी उपयोगी होगा, लेकिन मुझे अभी तक ऐसा करने का कोई तरीका नहीं मिला है। कृपया एक ActiveMQ noob की मदद करें! =) आप कुछ समय के लिए निष्क्रिय भी हो सकते हैं सक्रिय एमक्यू 5.4 के बाद से उपलब्ध है वैकल्पिक रूप से यदि आप सक्रिय एमक एम्बेडेड चल रहे हैं तो आप गंतव्यों को हटाने के लिए एपीआई का उपयोग कर सकते हैं:

cocos2d iphone - height of ccJumpTo function is decreasing? -

I am working on the Cocoa 2D version 0.9.3. I'm creating a demo game called Doodlemzep. Now when I'm creating an object to jump on the touch event, it will reach the next level. I have defined this type of thigh height steadily. actionTo = [CCJumpTo actionWithDuration: 1 position: CCP (Sprite image .position.x, 40 + 28) height: 110 jump: 1]; [Sprite image run action: action to]; It will jump right on the platform at 1 level, but when it will land on the platform at level 2, it will not leap its full height, but will jump very little in comparison to the previous jump. At Level 3 it will jump less than level 2 and similarly. I think it will gradually decrease in height in the jump. You need to change it: CCP (Sprite image.place.x, 40 + 28) do this To: CCP (Sprite image.position.x, Sprite ImageJass.C. 40 + 28) Overall, I did not really understand How CCJP works, it is very confusing and with me a little more time to jump higher or lower. I finished ve

c# - How to make an Firefox like tabcontrol in c sharp? -

Does anyone know how I can expand and tab page so that x appears on an active tab when pressed Is, the tab stops / ask whether the tab should be closed? Thanks Use TabControl.DrawMode property to apply custom drawing MSDN Library is a good example of a document event handler in the article. Use the Graphics.DrawLine () or DrawImage to draw X. Use the mouseup event to click on X To find out which tab was clicked on, you will need the GetTabRect () method. And shrink the space to verify that it was near X.

Using same log4j logger in standalone java application -

I have some code that is a standalone Java application that includes 30+ classes. Most of these succession from any other base class. This method is for every and every class to get and use a log4j logger public static logger getLogger () (if (logger! = Zero) returns Logger; try {propertiesUtil propUtil = PropertyUtil.getInstance ("app-log.properties"); if (propulable! = Null & amp; propipible.getProperties ()! = Null) PropertyConfigurator.configure (propUtil.getProperties ()) ; Logger = logger.getlogger (extractedata.class); return logger;} hold (exception exception) {exception.printStackTrace (); a} my question is whether it is some common law Should be re-applied, which is initially used and used in all classes? Is this a better practice? b) If so, how can this be done? is? How can I pass the logger? C) It is not actually being used in code like Logger.debug () but not getLogger (). Debug () . What is the effect on display? In Log4J, you have a logari

apache - How do I interpolate values in the TestString portion of an .htaccess RewriteCond? -

मैं रिव्राइट कंड निर्देश के टेस्टस्ट्रिंग भाग में % {REQUEST_FILENAME} जैसे मानों को कैसे पृथक कर सकता हूं? यहां मैं क्या करने की कोशिश कर रहा हूं: # वेब्रॉट फ़ाइलों के लिए # गैर-मौजूद अनुरोधों को 404 डी रेवर्इटकंड साइट /% {REQUEST_FILENAME} मिलती है! -f पुनर्लेखन नियम / वेबवेल साइट / वेब्रोॉट / 404 [एल] # अन्यथा, उन्हें इन्हें दें! RewriteRule ^ /? Webroot /(.*)$ site / webroot / $ 1 [एल] मुझे क्या करना है, यह अनुरोध है कि डोमेन / www.webroot/image.jpg जा रहा है यह देखने के लिए कि साइट / वेब्रोट / इमेज.जेपीपी मौजूद है। क्या ऐसा करने का कोई तरीका है? # वेबरॉट फ़ाइलों के लिए गैर-मौजूद अनुरोध प्राप्त करें 404 रेवाइट कंट साइट /% {REQUEST_FILENAME}! -f पुनर्लेखन नियम / वेबफोट साइट / वेब्रोट / 404 [एल] # अन्यथा, उन्हें इन्हें दें! RewriteCond साइट /% {REQUEST_FILENAME} -f पुनर्लेखन नियम ^ /? Webroot /(.*)$ साइट / वेब्रोट / $ 1 [एल]

android - TableLayout formatting loss after device rotation -

I see a strange problem with Talikaleaut after being rotated to either side of the device, if you view a picture Or load in landscape mode, the table is fine. But once you rotate the device, the column will fit only its width. I hope after the rotation, the column will still stretch to fit the screen width. Any thoughts on what can be done to solve it? After the rotation & lt; TableLayout android: id = "@ + id / DataTable" Android: Layout_width = "Fill_parent" Android: Layout_height = "Fill_parent" Android: layout_weight = "1" Android: layout_below = "@ id / Chart" Android: Stretch column = "* "Android: Shrink Column =" * "Android: Padding =" 6dip "& gt; & Lt; / TableLayout & gt; table row: & lt; TableRow xmlns: android = "http://schemas.android.com/apk/res/android" Android: Layout_width = "fill_parent" Android: layout_height = "fill_parent&

r - Merge two data frames together that have the same variable names and data types -

I have tried the merge function to merge the imported two CSV files. Both have the same variable name and data type, but each time I run, I have an object in which two data frames are named. I have tried the following: # ex1 obj & lt; - Merge (obj1, obj2, = obj) # ex2 obj & lt; - Merge (obj1, obj2, all) and many other iterative revisions Does the right function merge? If so, what am I doing? I think that you really want rbind > merge () actually in Join is used to equalize .

directshow - Set Positions returns E_NOTIMPL -

I want to write only one specific part of .avi file in the output .avi file. For this, I follow the source filter -> AV MUCUP-> File Writer. I am trying to use IMDAS, set a special set and close the bar using the set position but it does not allow e-notimpl Returns. I also try to ask the graph builder for IMDeSecing and try to set the start and stop position with no success. Can anyone help? Questions for IMDAC, sync on every output pin associated with music input, and those Set the conditions on.

c# - How can I force a winforms app to use the fonts/fontsizes I specify on every machine? -

How do I implement a Winform app to specify fonts / fonts on every machine? I have a C # app where the font resizes on different machines, and this is not a resolution thig. Is it a way to force the font size on Windows 7 with a C # app, or does the user always reverse the OS fonts? The font size is specified in the number one point is 1/72 inches The problem is that it is the rest of the Windows form There is a need to live with, where almost a few pixels are specified. The problem is that how many pixels make a point depends on your video adapter's dot-per-inch setting. The traditional setting is 96 dots per inch so if you ask for 9 point fonts, you get a 9/72 * 96 = 12 pixels high. Unless the control client's area is at least 12 pixels high, the text displayed in it will not be cut. The DPI setting of the video adapter can be changed however. They made it difficult in XP, you had to go to the advanced settings of the display applet to do this. It has become very

Can you run Android Market from a virtual device? -

Can you run the Android Market app in a virtual device or emulator? The market is allowed to run only on devices that Google has licensed to it You can use an app backup tool to get an APK from your phone and then try to install this apk on an emulator. It violates copyright from Google, which means that the copy of market apk is likely to be invalid, and it does not work because the market uses a shared library which is not present on the emulator.

utf 8 - MySQL, Altering Table from Latin-1 to UTF-8 -

I want to remove new entries in my Latin-1 characters database and just allow UTF-8. I am planning to make changes to the table and make the following changes: Charset: latin1 -> utf-8 < P> Code: Latin 1_swishish_c -> utf8_general_ci There is 1 million lines in the table in question, is this a good idea? What are the risks of doing this? What happens to the data that I try to input that is not in utf-8? What is UTF-8, what happens to the data that has been previously entered? You should create a table duplicate, start a transaction, enter all the rows from the old table, And then commit. The safest way. To summarize: Duplicate the Make Table ... (the condition you like, etc) SET AUTOCOMMIT = 0; Start transactions; Duplicate INSERT (... field-list ...) SELECT (... field-list ...) from original_tables; COMMIT; Optional table for basic basic basic return; Repeat duplicates in the original table; You should be careful of unique indexes and auto-fie

jQuery image preload/cache halting browser -

In short, I have a large photo gallery and I am trying to cache several thumbnail images as well I can do that when the first page loads <1000> can be thumbnails. The first question - is it stupid to try to load / cache beforehand? The second question - when the preload () function fire, the whole browser stops responding for one minute to two. Callback fire occurs at that time, so preload is complete. Is there a way to accomplish "smart preloading" that does not hinder the user's experience / speed in trying to load these many objects? $ The PreLoadImages function moves from here: How do I implement it here: $ (document) .ready (function () {setTimeout ("Preload ()", 5000);}); Function preload () {var images = ['image1.jpg', ... 'image1000.jpg']; $ .PpreLoad Images (Picture, Function () {Alert ('done');}); } 1000 images are plenty. Am I asking too much? After looking at that preload script, it seems that

jQuery is not defined on my staging server but works fine on my local -

If you open with your Javascript console, you will see a bunch of JS errors I have not found these errors in my local environment and it seems that this is happening because $ is not defined. I have the same environment as the similarity of my local environment. Using the RB file and trying to recover all JS caching but it is not making any difference Can anyone tell why jQuery is crapping out? It may actually be a little stupid, but I need a second pair of eyes. Try to upload it again if you have to do so from a fresh download copy from the jQuery site It can be an encoding error or something like that. It breaks for me.

Multiple layouts in rails [Newbie Q] -

As a newb, I decided to create a "home inventory" application. Now, while looking into a program, I want to programmatically select a layout based on which type of item. According to my plan, so far I can find some models in my house: Furniture , Electronics and Books . class book & lt; ActiveRecord :: Base & Class Furniture & lt; ActiveRecord :: Base & Class Electronic & lt; ActiveRecord :: Base End Now in the Books model things like isbn , pages , address , and category . The Furniture model contains things like color , value , addresses , and category . names , voltage , address , and category such as electronics . Here's where I was confused I know that property address will be identical to all of them, I also know that the appropriate To show the different qualities of objects that came with graphics and stylesheets, I would need to create several "layouts" for 3 different types of items. But wha

select - How to calculate the number of immediate children for each node in an adjacency list -

I have the sorted data that I am using in the proximity list model. If possible, I want to do it in the same selection, like generating a result ... Results ... ID Title Child Count 1 Test 1 10 2 Test 2 2 3 Test 3 etc ... Thanks for your advice! without title, select parents as ID Make the number of children in the form of COUNT (ID) by the table group by the parents If you want the title, I think that you can join yourself (perhaps slow) : select as t1.ID id, as t1.Title title, COUNT (T.ID) as the child Table T1 join the left OUTER table T2 on T1 .ID = t2.parentID

xaml - How do I turn off a custom IValueConverter at design time? -

Text after " How can I stop designing a custom IValueConverter ? Basically I want to write this: public class MethodBinder Implements IValueConverter Public Function In Convert Object (ByVal Value As Form, ByVal TargetType System.Type, ByVal Parameter Object Form In the form of ByVal Culture CultureInfo), there are IValueConverter.Convert [DESIGN_TIME] Then nothing returns the value implies nothing then return CallByName (value, CSTR (parameter), CallType.Method) return something Also the end ceremony The ConvertBack (ByVal value isnot then applies as object, inVal TargetType as System.Type, as byVal parameter object, as ByVal Culture CultureInfo) object as IValueConverter.ConvertBack New NotSupportedException End Function End Class The text after "throw I have worked around it, especially the incoming (default) value To give feedback on In my example I was using the load in a library sequence to calculate the number of business days (using an expansion method

drupal - I'm trying to use a PHP code for panel visibility in a Panels3 based on Friendlist -

I am trying to gain a true value to get the visibility of the panel of heartbeat messages in a user I have space in a panel to display the list. The display works but I can not understand how to restrict access to the panel based on the user viewing the panel. The goal I want is to show the panel to some people only with friends and some roles. Whatever role I can play, but I do not have enough information about PHP to work on friendship level. I guess a bit like this: The logged-in user is seen twice with the user on the basis of user ID logic. I know that my example is not like the actual code, but as I said that I do not have much on here. You should go to this. Global $ user; $ Friend_list = get_friend_list ($ page_uid_argument); If (in_array ($ user- & gt; uid, $ friend_list)) {// show messages} where get_friend_list () is a normal function that catches The user gives an array of UID based user relations, and the UID. I do not know if you are using codewis

operating system - How does Software/Code actually communicate with Hardware? -

मेरा प्रश्न यह है: जब मैं "शट डाउन" विंडोज / लिनक्स में बटन, कंप्यूटर बंद हो जाता है कमांड "शट डाउन" ने वास्तव में कंप्यूटर को शट डाउन कैसे बना दिया? मेरी बात स्पष्ट करने के लिए: जब हम एक गेंद को लात करते हैं, तो गेंद को स्थानांतरित करने के लिए गेंद और हमारे पैर के बीच शारीरिक संपर्क। तो सॉफ्टवेयर और हार्डवेयर के बीच भौतिक कनेक्शन कैसे प्राप्त हुआ है? कैसे कोड का सादा पाठ कंप्यूटर को यह करता है कि वह क्या करता है? बहुत ही बुनियादी स्तर पर, सादा पाठ कोड अंततः 0 और 1 के अनुवाद करता है। ये 0 और 1 है कम और उच्च वोल्टेज स्तर का प्रतिनिधित्व करते हैं। इस बिंदु पर, वोल्टेज का स्तर विभिन्न सर्किटों को नियंत्रित करता है। एक बैटरी संचालित प्रशंसक के बारे में सोचें। बैटरी की शक्तियों द्वारा प्रदान की जाने वाली विद्युत बिजली, जो अंदर होती है, एक emag-field बनाने के लिए बिजली का उपयोग करती है जिससे शाफ्ट को घुमाया जाता है, जो स्पिन को प्रशंसक ब्लेड चलाता है। यह एक उदाहरण है कि कैसे वोल्टेज शारीरिक हो सकता है। आप एक "स्विच" का निर्माण कर सकत

objective c - Is Class an object, or is it a struct? -

क्या कक्षा कोई ऑब्जेक्ट है, या यह एक स्ट्रेट है? उद्देश्य- C कक्षाओं को कुछ प्रतिबंधों के साथ वस्तुओं के रूप में माना जाता है (देखें): कक्षा ऑब्जेक्ट्स इस प्रकार पूर्ण रूप से विकसित वस्तुओं को गतिशील रूप से टाइप किया जा सकता है, संदेश प्राप्त कर सकते हैं, और अन्य वर्गों से वारिस के तरीकों वे केवल उस विशेष में हैं, जिन्हें वे कंपाइलर द्वारा बनाए गए हैं, उनकी कक्षा के परिभाषा से निर्मित डेटा संरचनाओं (उदाहरण चर) की कमी है, और रनटाइम पर इंस्टेंसेस बनाने के एजेंट हैं। दृश्य के पीछे, एक वर्ग की परिभाषा में विभिन्न प्रकार की जानकारी होती है, इनमें से अधिकांश वर्ग के उदाहरणों के बारे में: वर्ग और इसके सुपरक्लास का नाम < Li> एक उदाहरण उदाहरण चर का एक सेट वर्णन विधि नामों की घोषणाएं और उनकी वापसी और तर्क प्रकार विधि कार्यान्वयन

security - Sql server execute permission; failure to apply permissions -

I have migrated from SQL2000 to SQL2008 and I spawn_accept on a stored proc the rest of the system db Works fine with login which is added to setup and database. I have tried: use message 15151, level 16, state 1, Line 1 user 'dbuser' can not be found because it does not exist or you do not have permission. I'm logged into the server with full permissions. I can execute a similar SQL statement and apply permissions for a server role, though not login / user. How do I apply changes to specific users / login? I can apply permissions for the public role and it resolves my problem; Although this is a security problem I really do not want to apply to live servers. From the answer to John, the leading user checked the user listing on the master database and my user was not there. Whether it has been removed or lost something which I do not know. Some DBS migration has gone crazy with new server examples. Anyway; To enable the user to perform the databa

xsd - can i write a schema that all XML are valid to it? -

I have to write a schema that all the XML examples are valid for that I tried: & Lt; Xs: element name = "arguments" & gt; & Lt; XS: complexType & gt; & Lt; XS: Sequence & gt; & Lt; Xs: any name space = "## any" minOccurs = "0" maxOccurs = "unbounded" process = "loose" /> & Lt; / XS: sequence & gt; & Lt; / XS: complexType & gt; But it argues for a basic element whose name is logic. Is there any way to root anyway? Good question, although I'm not sure if this has to be done. Your approach is good with using xs: any , but I'm not sure that it can be applied to an entire XML (for root), but for a part of it To read from a book, I read it once (something like "Why?" People are asking, but they put a purpose on it): [...] is useful when XSLT While writing schemas for languages, regular markups are included with many vocabulary, schema is written when unknown [

iphone - EXC_BAD_ACCESS due to PostNotification -

I am facing a problem about a module, so let me clear the flow for this. I have a customized UITableViewCell When I'm getting some new information I am posting a notification [[NSNotificationCenter defaultCenter] PostNotificationName: KGotSomething object: userInfo zero: message]. Viewing where I am maintaining tables I'm starting a customized cell in - (UITableViewCell *) tableView: (UITableView * ) TableView cellForRowAtIndexPath: (NSIndexPath *) IndexPath {cell = [[Custom CL Alok] initWithFrame: reuseIdentifier: Identifier Document: Doctor]; Return cell; } now in customcell.mm - (id) initWithFrame: (CGRect) frame reuseIdentifier: (NSString *) reuseIdentifier {[NSNotificationCenter defaultCenter] AddObserver: Self Selector: @Selector (Gotsamsing :) Name: Kegote Communications: Zero]; } and in dealloc - (zero) dealloc {[NSNotificationCenter defaultCenter] removeObserver: Own name: KGotSomething object: zero]; } Now my app crashes because of this

parsing - how to check an ANTLR token is only used once or less in the parser -

In Anther, if I have a rule for example: Some rules: Token token; This will accept: "Token tokenb" If I want to tip to be optional, then I can say, SomeRule: Tokna * Tokenb .; Then I could: "Tokna Tokenb" or "Tokenb" or "Tokna Tokai Token" But this also means that it is repeated once again can go. Anyway, I can say that this token can be 1 or less but not more than one? Therefore it will accept: "Token tokenb" or "tokenb" but "token token token"? Many thanks ... anyway I can say Can this token be 1 or less but not more than one? ... Here's how: Some rules: Token? Tokenb; Or: Some rules: Token Tokenb. Tokenb;

dynamic link_to_remote in rails with jquery -

I am trying to pass a string with a link_to_remote call as: id, and string an input Should be collected from the field and id of "movie_title". & lt; Div id = "search_list" & gt; There is nothing here yet & lt; / Div & gt; & Lt; Br / & gt; & Lt;% semantic_form_for @movie do | F | | & Gt%; & Lt;% f.inputs do -% & gt; & Lt;% = f.input: title ,: class = & gt; "Movie_title"%> & Lt;% = link_to_remote ('Search ...', {: URL = & gt; {: action = & gt ;: imdb_search ,: id = & gt; "'+ $ (' \ # MOVIE_TITLE ') Value + . "}}, {: Title = & gt;" Search for this movie ",: class =>" imdb_search "}) -%> [... deleted text which does not matter ...] <% end -%> & Lt;% = f.buttons% & gt; & Lt;% end% & gt; I have a javascript getting error and if I remove the jQuery link #, it returns undefined "" Links I'm

reporting services - Obtaining the SQL Server 2005 Report Builder XSD -

I have been able to obtain the report definition schema for SQL Server 2005, but xmlns: rd = "http : //schemas.microsoft.com/sqlserver/reporting/reportdesigner " anywhere schema Is it buried somewhere in the part of 2005? I am asking because I have recently started writing RDL files for SQL reporting services, I want to be able to validate both the schemas and be able to work fully (I am mostly using Eclipse ). Any thoughts on how I can get the XSD Hall? This is just an XML name space - there is no physical representation in it, in fact the rd The definition of Nameslot report is part of the content - you must be already in your XSD.

sql - Data Reader formatting output -

I am using the following function to create a list of users connected to the selected database. How do I change it for more than one similar result? for example:? - rather than listing "MyComputer bit (3)" "sa - MyComputer" three times function ConnectedUsers (ByVal SelectedDatabase String, ByVal SelectedInstance dim dim myCommand SqlCommand as as string) Dr. SqlDataReader dim try new SqlConnection (ConnectionString) myConn.Open (as mystring as string = String.Empty dim myConn) myCommand = new SqlCommand as ( "loginame, select the host name from sysprocesses where db_name (DBID) = '' & amp; SelectedDatabase & amp; ",", myConn) Dr = myCommand.ExecuteReader () while dr.Read () mystring + = GetFullName (Dr (0) KToString () trim ()) & Amp. - "&" (1). Artificial () and; vbCrLf End while DrkClose () MyConnkClose () Catch e exception MessageBox.Show (e.Message) Try End Return mystring as end function Thank you.

asp.net - Two-way data binding of controls in a user control nested inside a FormView doesn't work -

I am trying to bind two-way data in my user control, which is a FormView template: and asp: objectDataSource runat = "server" id = "objectdatasource" typename = "web applications 1.data" selectionMedual = "gate item" update Matthew = "updatem" & gt; & Lt; / ASP: ObjectDataSource & gt; & Lt; ASP: formview runat = "server" id = "formview" datasource id = "object datasource" & gt; & Lt; ItemTemplate & gt; & Lt; Uc: WebUserControl1 runat = "server" & gt; & Lt; / UK: WebUser Control1 & gt; & Lt; / ItemTemplate & gt; & Lt; EditItemTemplate & gt; & Lt; Uc: WebUserControl1 runat = "server" & gt; & Lt; / UK: WebUser Control1 & gt; & Lt; / EditItemTemplate & gt; & Lt; / ASP: FormView & gt; Web user controls: <% @ Control language = "C #" ...%> & Lt; ASP: Text Box Runat = &qu

xsd - Problem with develop of XML Schema based on an existent XML -

After I have a problem with the verification of this piece of XML: & lt; ? XML version = "1.0" encoding = "UTF-8"? & Gt; & Lt; I-ching xmlns = "http://www.oracolo.it/i-ching" & gt; & Lt; Predizione & gt; & Lt; Esagramma nome = "speed" & gt; & Lt; Trigramma & gt; & Lt; Yang / & gt; & Lt; Yang / & gt; & Lt; Yang / & gt; & Lt; / Trigrumma & gt; & Lt; Trigramma & gt; & Lt; Yin / & gt; & Lt; Yin / & gt; & Lt; Yin / & gt; & Lt; / Trigrumma & gt; & Lt; / Esagramma & gt; & Lt; Importantto & gt; Questa combinatorial preening & LT; Enfasi & gt; Wow & lt; / Enfasi>, e forse anche & lt; Enfasi & gt; MAh, chissa & lt; / Enfasi>. & Lt; / Significato & gt; & Lt; / Predizione & gt; & Lt; Predizione & gt; & Lt; Esagramma nome = "rightorno" & gt; & Lt; Trig

Python and object/class attrs - what's going on? -

Can anyone explain why dragon does the following? & gt; & Gt; & Gt; Square Fu (object): ... bar = [] ... & gt; & Gt; & Gt; A = fu ()> gt; & Gt; & Gt; B = FU ()> gt; & Gt; & Gt; A.bar.append (1) & gt; & Gt; & Gt; B. Bar [1] & gt; & Gt; & Gt; A.bar = 1> & gt; & Gt; & Gt; A.bar 1 & gt; & Gt; & Gt; B. Bar [1] & gt; & Gt; & Gt; A.bar = []> gt; & Gt; & Gt; A.bar []> gt; & Gt; & Gt; B. Bar [1] & gt; & Gt; & Gt; Del a.bar & gt; & Gt; & Gt; A.bar [1] This is misleading! As others have said that the written code creates a class variable instead of an example variable To create a frequency variable, you need to assign __init __ . Hopefully this annotated copy of your code is helpful in explaining what is happening at each stage: & gt; & Gt; & Gt; Square Fu (object): ... bar = [] Defines a class variable on #foo

objective c - Accelerometer & Calibration - iPhone SDK -

I need to use the accelerometer functionality in my iPhone game. I need to move an image by tilting the device . However, most of the video on YouTube shows the tilt feature, which somehow forget to include inverted and calibration. Whatever the situation they are in. Are the users who want to fix their equipment? Anyone know how should I get started on this? Your help is highly appreciated, Kevin I have created an app like this once, I will post it here, but it is for iOS 4 ... To check: int tapCount = 0; - (zero) Cancel doubletap {if (tabcount & lt; 2) {tapCount = 0; }} - (zero) reset {{[NSUserDefaults Standard User Defaults] Setflat: 0 for KA: @ "X-Calibrate"]; [[NSUserDefaults standard standard defaults] Set Fleet: 0fork: @ "Y-Calibrate"]; UIAlertView * Warning = [[UIAlertView alloc] initWithTitle: @ "Reset!" Message: @ "Reset calibration." Representative: Cancel zeroTuttonite: @ "OK." OtherButtonTitles: zero

sql - How to create a MySQL query for time based elements with a 'safe window'? -

I am not a SQL expert, far from it I am writing a Rail application, and I am new to that too. I came from a desktop programming background. My application has a table of data, one of the columns on which the data was logged. I want to create a query with a 'safe window' around every line, I mean, it gives the first line, then for x minutes (based on the time-column column) it will not return any data, x ext Once it's up, it will return the next line. For example: id | Timelog 1 3/5/2010 12:01:01 2 3/5/2010 12:01:50 3 3/5/2010 12:02:03 4 3/5/2010 12:10:30 5/5/2010 01 : 30: 03 6 5/5/2010 01:31:05 I want to make a query back with a 5-minute safe window: 1 | 3/5/2010 12:01:01 4 3/5/2010 12:10:30 5/5/2010 01:30:03 (This is 12:01:50 And 12:02:03 leave the objects because they happened within 5 minutes of the first item.) Another example, I have to return the 15-minute 'safe window': 1 | 3/5/2010 12:01:01 5 | 3/5/2010 01:30:03 Maybe I just have

Apache CXF REST Services w/ Spring AOP -

I am trying to work with Apache CXF jacks-RS services with Spring AOP. I have created a simple logging class: public class AOPLogger {public void logBefore () {System.out.println ("first logging!"); }} My Spring Configuration (Beans. Xml): & lt; Aop: config & gt; & Lt; Aop: aspect id = "aoplogger" ref = "test.aop.AOPLogger" & gt; & Lt; Aop: method = "logBefore" pointcut = "execution (* test.rest.RestService. * (..))" /> & Lt; / Aop: Aspect & gt; & Lt; / Aop: config & gt; & Lt; Bean id = "Appleogger" category = "test.aop.AOPLogger" /> I always get calls in RestService to get a service when the call is called for getServletRequest (), in which: return MessageContacts .getHttpServletRequest (); If I remove an app configuration or my beans Commenting on XML, everything works fine. All my real rest services are tested. Test.rest.RestService (which is a

user interface - How do you change the layout of JUnit Reports in Hudson? -

Therefore, I am still installing Hudson and may not be more pleased though, let me display the table in the test results page Is required, as it provides contrast to the graph. Does anyone know how I would go about doing this? I think you want to create a custom plugin from existing junit functionality. You can copy more Java files from: Hudson / Main / Core / src / main / java / hudson / tasks / junit / and from resource files (jellys) : Hudson / Main / Core / src / main / resources / hudson / tasks / junit / for your new plugin (unless you want to cut the Hudson source) . It seems that the files you want to like Bella are Hudson / Main / Core / src / main / java / hudson / tasks / junit / history.java (where the articles are created) And Hudson / Main / Core / src / Main / Resources / Hudson / Work / Junty / History / Index. Jelly (where graphs created are shown). How can you easily create bella with test object from history-class?

caching - How to flush object cache in sharepoint; programmatically -

शेयरपॉइंट में हम साइट कलेक्शन एडमिनिस्ट्रेशन - साइट संग्रह ऑब्जेक्ट कैश क्या समान प्रोग्राममैट करना एक तरीका है? आप ऐसा नहीं कर सकते "वस्तु कैश फ्लश" प्रोग्राम के रूप में (यह आंतरिक वस्तुओं का उपयोग करता है) लेकिन आप "वर्क में सभी सर्वर को अपने ऑब्जेक्ट कैश फ्लश करने के लिए बल दें" के रूप में ऐसा कर सकते हैं: SiteCacheSettingsWriter लेखक = नया SiteCacheSettingsWriter (साइट); writer.SetFarmCacheFlushFlag (); writer.Update ();

c - transferring binary files between systems -

I am trying to move my files between 2 Unix clusters, the data numerically pure (in the binary form) Vector). Unfortunately one of the systems is IBM PPC 997 and the second is AMD Opteron, it seems that the binary number format in these systems is different. I have tried three ways so far: 1- My files have been converted to ASCII format (i.e. a number saved in each line in a text file) , They were sent to the destination and 2- The net binary sent to the destination 3- is used - the UUNcode sent them to the destination and decoded them Unfortunately, none of these methods work (destination sit) Generates my code garbage system, while it is already working on the system, I am 100% sure that the code itself is portable). I do not know what can I do? Do you have any ideas I am not a professional, please do not use the terminology of computer scientists! And: My code is in C, so by binary I mean there is a mapping between memory and hard disk. Thank you If you are wr

SQL Server 2008 query -

I am trying to apply the version of data I have two table clients and addresses I have to display in the UI, with different updates in which they were created but with the correct client version , client table address table ------ ---- ---------- Customer Edition modified date address version modified date cv1t1 avi1t2cv2t4av2t3cv3t5 My result should be CV1 AV1 (first edition) CV1 AV2 (as was updated on AV1T3) CV2 AV2 (as client client on C4 on T4 CV3 AV2 (as the customer has been updated on T5) This is not correct, but you can try a union subquery, select something like: Select Client Virus, AddressVersion, Modify FROM (Client Virus Select this, tap in the form of address, select all from the date of the modification from client unions, client warson, address, address from revised date) modified by order ASC A result like your Sample data should come back from: Client warsen address version modidate date cv1t1 av1t2 av2t3cv2t4cv3t5 Then you can fill Clie

asp.net - ModalPopupExtender doesn't work on IE6 frame layout -

I am using a "frame" layout, one of which: a div #top at the top of the page, on the left Includes a div #, and a div #main #top and # left divs navigation menu with main content. Now I want to use a popup div inside the content (#main) div using AjaxControlToolkit ModalPopupExtender. It works fine IE8 (where #top, left, # is the position of everyone in: Fixed), but when I run it on IE 6, the modal background covers only # brains - I need to cover the whole page with the # top and #left navigation division. Looking at the script for ModalPopupExtender, it seems that the hierarchy of parents is not searched until the parents are related to the status or are not found. And in the IE6 rendering, there is a situation in the mind: absolute because the situation: fixed is not supported, which I think is happening. Is the best / easiest way to do this job properly on IE6? Ideally, without modifying ModalPopupExtender code, but I'll do it if I have to do it and this i

string - Object allocation in C++ -

चार * myfunc () {char * temp = "string"; वापसी अस्थायी; } कोड के इस टुकड़े में, ऑब्जेक्ट के आवंटन को temp द्वारा इंगित किया जाता है और इसका दायरा क्या होगा? क्या यह कार्य एक चार * पॉइंटर को वापस करने का एक वैध तरीका है? क्या कोड सही है ? हाँ आपका कोड (लगभग) ठीक है, क्योंकि "string" एक स्ट्रिंग है और स्थिर भंडारण में स्थित है। नोट : एक सूचक सिर्फ एक वेरिएबल है जो स्मृति पते को स्टोर करता है। यह पंक्ति केवल temp नामक एक चर के अंदर स्ट्रिंग शब्दशः "स्ट्रिंग" का पता संग्रहीत करता है। char * temp = "string"; सी ++ मानक यह गारंटी देता है कि स्ट्रिंग का शाब्दिक कार्यक्रम की अवधि के लिए स्मृति में रह जाएगा जैसा कि नीचे परिभाषित किया गया है। इसका अर्थ है कि आप अपने प्रोग्राम के पूरे जीवन के दौरान कहीं भी किसी भी क्षेत्र में उस मेमोरी पते का उपयोग करने के लिए स्वतंत्र हैं। क्यों? C ++ 03 मानक (वर्तमान) यह कहने के लिए है: एक साधारण स्ट्रिंग शब्दशः प्रकार "सर कॉन्फ़ चार" और स्थिर भंडारण अवधि (3.7), और ख

graphics - alpha blending in gtk -

How can you draw semi-transparent for a drawing in GTK? Its 2010, and how can I put Google alpha values ​​in a color for me, what am I missing? Use gtk.gdk.Drawable.cairo_create () and Work on gtk.gdk.CairoContext . See . Cairo is a generic vector 2D library used in many versions of GTK +; GDK drawing primitives have been deprecated in their favor (though not the entire GDK).

asp.net mvc ajax -

I am using the dropdownlist html assistant and when the value changes, I would like to call an AJAX call on the server. I've seen jquery code dropdownlist.change ... The problem I have is that I have a series of dropdownlist_1 dropdownlist_1, dropdownlist_2, ... ... I would like to be able to specify the same jquery function for each of these dropdown lists. I can not find a way to specify the function name in the dropdownlist html helper. Thanks, Henry Instead of specifying it in HtmlHelper, click on each of your dropdowns Add a class name for the lists: <%> Html.DropDownList ("ddlName", new {@ class = "ajaxDropDown"})%> or & lt; Select class = "ajaxDropDown" id = "ddlOne" & gt; & Lt; Options & gt; 1 & lt; / Options & gt; & Lt; Options & gt; 2 & lt; / Options & gt; & Lt; Options & gt; 3 & lt; / Options & gt; & Lt; / Select & gt; & Lt; Select

regex - What is the Java 1.4.2 equivalent of Pattern.quote() -

What would be the pattern 1.4.2 equivalent pattern? questions? I was using patterns to bid on URI () but now it needs to make 1.4.2 compatible. The good code of pattern.quote is available and looks like this : public fixed string bidding (strings) {int slash eindex = s.indexOf ("\\ E"); If (slashEIndex == -1) returns "\\ Q" + s + "\\ E"; Stringbilder sb = new string builder (s.length () * 2); Sb.append ("\\ cue"); SlashEIndex = 0; int current = 0; while ((slashEIndex = s.indexOf ("\\ E", current)) -1 = {sb.append (s.sstring) (Current, slashEIndex)); current = slashindx + 2; sb.append ("\\ e \\\\ e \\ Q '); } Sb.append (s.sststring (current, s.length ())); Sb.append ("\\ e"); Return sb.toString (); } Actually it depends on \ Q, nothing, but not all quotes of \ E \ E are quoted, but The quote ends \ Q and there is a special type of case that is present in the \ E string.

naming conventions - Is there advantage of using in CSS #image-box vs #image_box (hyphen vs underscore)? -

Or is it primarily a personal preference? As a programmer, I always use underscores, but seen it as - and so I have to do it in order to work in that project. I understand hyphen as more SEO friendly for URL. <00> Both are valid I << p> I think it just breaks down in personal preference.

Drupal Exposed Views Filter custom date -

I have a date filter that I have come to my view. I want to make the interface more user friendly and I'm tightening it. Last year Last date li> All This will then filter on the date fields. Is this possible? How will you go about doing this? The proper way to do this is ($ Form_id == 'views_exposed_form') {$ view = & amp; ; $ Form_state ['view']; $ Display = and $ form_state ['display']; If ($ view-> name == 'YOURVIEWNAME' & amp; amp; $ display-> ID == 'YOURDISPLAYID') {// Optionally $ form here, dpm ($ Form)}}} $ form is an array whose description format is using Drupal. You can inspect this array from the module.

wpf - Setter in property trigger fails if target property already has an explicit value -

I currently try to create a ControlTemplate for button I'm replacing the class in WPF, instead of the normal view tree which looks like a small (X) close icon on the tab of Google Chrome. I decided to use the path object in XAML to achieve the effect, setting the red background of the icon icon, using the property trigger, IsMouseOver responds to the change in property. Here's a XAML test app: & lt; Window X: orbit = "widget.index1" xmlns = "http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns: x = "http://schemas.microsoft.com/winfx/2006 / Xaml "title =" window 1 "height =" 300 "width =" 300 "& gt; & Lt; Window.Resources & gt; & Lt; Style x: key = "border style" target type = "border" & gt; & Lt; Style.Triggers & gt; & Lt; Trigger Property = "Ismouth Over" Value = "True" & gt; & Lt; Setter Property = "Ba

error handling - C++: Return NULL instead of struct -

मेरे पास एक struct Foo है Pseudocode में: def FindFoo: foo = खोज के परिणाम मिले foo = true अगर एक वैध foo मिल गया है रिटर्न foo अगर foundFoo else someErrorCode कैसे कर सकते हैं मैं इसे सी ++ में पूरा करता हूं? कई गलतताओं को दूर करने के लिए संपादित सी ++ ऑब्जेक्ट रिक्त या रिक्त नहीं हो सकते संकेतक एक अशक्त सूचक मान रख सकते हैं जिससे वे इंगित करते हैं कि कुछ भी नहीं है। ठेठ समाधान एक अपवाद फेंकना होगा। अन्यथा, एक सूचक का उपयोग करें; बस सुनिश्चित कर लें कि आप अस्थायी का पता नहीं लौट रहे हैं। मैं अन्य भाषाओं से ज्ञान के साथ सी ++ को पढ़ाने की कोशिश नहीं करूँगा, तो आप खुद को नुकसान पहुंचाएंगे पकड़ो, यह जानने का सबसे अच्छा तरीका है

sql server 2005 - Using FOR XML AUTO against a synonym -

We switched to the synonyms for the linked server stuff, and it has been found that our XML output is no longer correct is. When returning XML results from one view, we can nick the view and this element will be designated as the name. With synonyms, however, it seems to neglect the nickname? We are still mostly on SQL 2005 - this bug does not appear on our 2008 example. Is this a known problem, and any ideas for work around? For example, this was what we were able to do: Select the top 3 numbers from number as the element name for XML Auto; & Lt; Elementname number = "0" /> gt; & Lt; Elementname number = "1" /> gt; & Lt; Elementname number = "2" /> And it happens with one of the options: number as elementname for XML auto_ Select the top 3 numbers from the Sinemine < Dbo Number number = "0" /> & lt. Dbo.Numbers number = "1" /> & lt; Dbo Number number = "2" /> As you c

target="_blank" link using jQuery UI Tabs -

I would like to use my existing junkie UI tab to shoot my users in a new browser window Do anyone have any ideas? The default tab code has been found here & lt; Div id = "tabs" & gt; & Lt; Ul & gt; & Lt; Li & gt; & Lt; A href = "# tabs-1" & gt; New Texas & lt; / A & gt; & Lt; / Li & gt; & Lt; Li & gt; & Lt; A href = "# Tab2" & gt; Preine drill & lt; / A & gt; & Lt; / Li & gt; & Lt; Li & gt; & Lt; A href = "# Tabs-3" & gt; Anne Licinias & lt; / A & gt; & Lt; / Li & gt; & Lt; / Ul & gt; & Lt; Div id = "tabs-1" & gt; & Lt; P & gt; Value-added value, Remover Commodo, Vehicle Time, Commodo A, Rhesus Curabitur nec arcu I'm thinking about my friends First name is known by the first name Normally many things and interpretations are Morris dipibus lacs oak rhesus ai temp Ullamcorper Information a