Posts

Showing posts from February, 2013

Include Elements in XSD Complex Type Without New Element -

मेरे पास यह जटिल प्रकार है: & lt; xsd: जटिल टाइप नाम = "आइडेंटिफ़ायर" & gt; & LT; XSD: अनुक्रम & gt; & Lt; xsd: तत्व का नाम = "आईडी" प्रकार = "xsd: स्ट्रिंग" / & gt; & Lt; xsd: तत्व का नाम = "संस्करण" प्रकार = "xsd: स्ट्रिंग" / & gt; & Lt; / XSD: अनुक्रम & gt; & Lt; / XSD: complexType & gt; अब मैं इसे एक और जटिल प्रकार में शामिल करना चाहता हूं और मैं ऐसा कर रहा हूं: & lt; xsd: जटिल टाइप & gt; & LT; XSD: अनुक्रम & gt; & Lt; xsd: तत्व का नाम = "आईडी" प्रकार = "पहचानकर्ता" / & gt; & Lt;! - यहां अतिरिक्त तत्व - & gt; & Lt; / XSD: अनुक्रम & gt; & Lt; / XSD: complexType & gt; यह नहीं है कि मैं वास्तव में हालांकि चाहता हूं। मैं एक नए तत्व के बिना पहचानकर्ता प्रकार के तत्वों को सीधे अपने दूसरे जटिल प्रकार में शामिल करना चाहता हूं। जैसे ऐसा करने के समान ही: & lt; xsd: जटिल टाइप & gt; & LT; XSD: अनुक्र...

image processing - .Net - Argument Exception When Trying to Convert Bitmap to JPEG -

Then I was trying to convert a bitmap image to JPEG in code and I found this error: Additional information: The parameter is not valid. Here is the related code all the paths are correct and the encodermator is not zero, and what could be the reason for this? ImageCodecInfo codecInfo = null; Foreach (ImageCodecInfo codec ImageCodecInfo.GetImageEncoders ()) {if (codec.MimeType! = "Image / jpeg") {continue; } CodecInfo = codec; break; } EncoderParameter EncoderParamets = new encoder parameter (); Encoder parameters. Palm [0] = new encoder parameter (encoder quality, 85); (Bitmap bitmapioconvert = use new bitmap (filepathine)) {bitmapToConvert.Save (filePathOut, codecInfo, encoderParameters); } two! Encoder parameters. Paragraph [0] = new encoder parameter (encoder quality, 85); should be: encoder parameter. Paragraph [0] = new encoder parameter (encoder quality, 85L); // or encoder parameter. Paragraph [0] = new encoder parameter (encoder quality, (l...

jboss - How do you unwar a .war file with ant on windows? -

I'm only familiar with the ant, but apparently I have to set up a service running on jealousy and Should put in a deployment directory ... The problem is the .war file - I only have Winzip 7zip and ant and I do not know how. Thank you for your help! // Edit / P> The problem is that the .war file should be kept intact. And I do not know how to do this via JBOSS or any other medium. // Edit The 7zip file is Pomegranate-Ed but I'm not sure where to place the content in jboss. / server /? Thank you for your help as I am totally unaware that this is my first time. Usually you can place the war in the directory and enter the container will take care of unpacking it . However, a war file is just a zip file with a different extension, so you can manually open any popular unzip tool (WinZip, WinRAR, 7Zip, etc.) manually Open The ant also has a task.

java - Shortest path (fewest nodes) for unweighted graph -

I am trying to create a method that is a non-great graph from one node to another Returns the short cut. I used to consider the use of the dzstra, but it seems a bit because I only want a couple. Instead I have applied a fourth-first discovery, but the problem is that there are some nodes in my return list that I do not want - how can I achieve my goal? Public listing & lt; Node & gt; GetDirections (node ​​start, end node) {list & lt; Node & gt; Directions = new linked list & lt; Node & gt; (); From queue & lt; Node & gt; Q = new linked list & lt; Node & gt; (); Node current = start; Q.add (current); While (! Q.isEmpty ()) {current = q.remove (); Directions.add (current); If (current. Angle (finish)) {break; } Else {for (node ​​node: current.getout nodes ()) {if (! Q.contains (node)) {q.add (node); }}}} If (! Current.exls (end)) {System.out.println ("can not access destination"); } Returning directions; } Actually your code ...

c# - Free Windows Forms Components Similar to jQuery UI Draggables -

edit: Therefore, I'm making my own basic solution to this problem, and it can be found in your answer to the question below. Original Post I am doing some UI programming for a small NIT application. The app has some collections that need to be displayed in the grid sort format (X columns by the Y rows) and need to be able to drag the grid elements to different grid locations, and possibly all the grids from a grid with . The UI is the most comparable type of design elements that I can think of. Do I have to roll my roll or are there people who are already written to act like this? Even better, are there any free components? Or an easy way to do this is that I just do not know about (do not do too many .NET UI programming ..) Besides these "grid items" need to enable windows Include form components of Close what I want for it, except that it only supports horizontal or vertical alignment, there is no grid of items. Here is a visual example of wh...

apache - Using mod_rewrite to bypass an "invalid SSL cert" error -

I have a certificate that is registered on the server's fully qualified domain name on our intranet (webserver.domain.com) . When our internal users hit this site through a fully qualified name, they go right and it is not indicated that this is an invalid certificate. If they browse the web server through the host server (non-fully qualified), they are redirected to the https version and there is no indication either part of my mod_rewrite which I am missing Connects to a web server via an HTTP server 'Hostname' I think it can not be rewritten by FQDN, it does not have to be rewritten and always indicates that the certificate is invalid. Any help is appreciated thanks! Here's an example that can not match me: http s : //webserver/pubs/index.html I need it Rewrite: http s : // webservers domain.com /pubs/index.html If they point out correctly, you can rewrite the FQDN.

Scheme How to Take the first item in the List? -

Say I want to get the first items of lists '(4 3 1)' (5 6 8) I want something like this (first '(4 3 1)' (5 6 8)) I should return the first item (4 3 1) as a result. The car does not work, because it only gives me the first item inside the 1 list The list-reef does not work, the only reason above, I have 1 item inside the list How can I do this? If I want to write it myself first? You can use the process to get an element from a list, using its index By example, for example: (two ((L ((4,3 1) (5 6 8))) (List-specified L0)); Get element at index 0 However, if you want only the first element, you can use it: (two ((' (4 3 1) (5 6 8)))) (Car L)) The snippet is running.

SQL Need a query that returns every field that contains a specified letter -

I have a SQL table with 11000 keywords. I need a query that can find a field that contains a fixed letter. So if I include the query "a" and "b" then all the fields will be selected which will have the letter "a" and "b" in the field. from the selection table * where the keyword '% a%' and '% b%' Like the keyword ps it would be super slow you might want to check the full text indexing solution.

sql - Not unique table/alias: 'usertns_group'1066 Please tell me if you spot the error -

The code below looks a lot ... but if you can find the error, then let me know .. I do not see any duplicates of 'usertns_group', so I wonder why the error is happening .. after the post Post 2 as Category 2 post 2 (post.category2_id = postcategory2.category2_id) LEFT JOIN Category as Category 1 Category 2 Category 1_ (1) Category 1 Category 1 Category 1_igd) 1 In Category 1 on TNS_Group (Category 2 Serial 1) 1 NCIDTE_Giz_ID = Category 1tns_group.tns_group_id) Add the user as PostUuser (post.user_id = postuser.user_id) LEFT JOIN tns_group as usertns_group ON (postuser.tns_group_id = usertns_group.tns_group_id ) Leave the job status as poststatus_id = poststatus.status_id) on poststats (post.tns_group_id = posttns_group.tns_group_id) Thank you .. mei usertns_group these tables The name of a column in one of the switch to?

Java-like Collections in PHP -

I'm learning PHP5 (PHP4 days when I checked PHP) and I was happy to see that Java is more than PHP5 OO PHP4, but there is a problem that I have due to my Java background I feel quite nervous: ARRAYS I am reading "Professional PHP6" (WOX) and it shows my collection implementation. I have found a variety of other things based on SPL I have also found that A There is some kind of collection in PL (ArrayAbject) However, I'm surprised because I do not really see people using the collection in PHP, they like arrays. So, is it not a good idea to use archives in PHP like people are using ArrayLists instead of the original ARMs in Java? After all, PHP arrays are not really like Java arrays. Collections in Java make lots of emotions because it is a strongly typed language, it is a "car" There is a collection to say and the second part of "Motorbikes" is. However, due to the dynamically typed nature, in PHP, it is quite common to sacrifice the formali...

Why does bash sometime not flush output of a python program to a file -

I have a dragon script that calls a dragon script and outputs it in a file: Python Run.py & gt; Current_date.log Now sometimes when I do tail- f current_date.log I file Seeing fill with the output, but the log file is present for the second time, but remains empty for a long time. I'm sure the stuff is being printed after the dragon script starts moving, and the log file is has been made any idea why it remains empty for some time? Can not get any output right now You can configure your script to flush the output or you can add the dragon with the -u logic to get the output without any output. > python -h ... -u: Unbranded binary standout and stadder (also pithunbuffed = x) see man page for details of internal buffering related to '-u' ...

sql - SSIS and MySQL - Table Name Delimiter Issue -

I am trying to insert rows in a MySQL database from an Access database by using SQL Server 2008 SSIS. TITLE: Microsoft SQL Server Management Studio ------------------------------ Error [42000 ] [MySQL] [ODBC] 5.1 Driver] [mysqld-5.0.5aa-community-nt] You have an error in your SQL syntax; To use close "order" on line 1, check the manual related to your MySQL server version for the correct syntax. The problem is with the delimiter I am using 5.1 ODBC driver I can connect to MySQL and select a table from the ADOnet destination data source. MySql tables are shown in all SSIS package editors delimited with double quotes: "shippingto addresses" "use double quotation marks Removing a table or ado. See the text box on the net destination editor or do not take place in another place if there is a place in the table name when SSIS puts together the inserted query, it holds double quotes and adds single quote. The above error B is shown when I click on ...

sql - how to know if between 2 date's it past 5 days - Oracle 10g? -

I have two dates: 1) 01/05/2009 2) 06 / 05/2009 How do I know that there are 5 days between them? In your example, I think the date DD / MM / Y The YYY format is written in. You can do this: Select when the stomach (At DT ('01 / 05/2009 ',' DD / MM / YYYY ') - to_date ('06 / 05/200 9 '' DD / MM / YYYY ')) = 5 Then' yes' and 'no' ends in double form as ARE_DATES_5_DAYS_APART; If there are two columns in the two dates table, then use the table name instead of "double" in the above query.

jqgrid - CSS Container not growing with grid? -

I have a container background that is defined in CSS as follows; .container {background: #fff; Margin-left: auto; Margin-Correct: Auto; Status: Relative; Width: 970px; Limit: 1px solid # 000; Padding: 5px 10px; } The problem is that I have placed a jqGrid (near the bottom edge) of a container and at the beginning it looks fit and fit inside the container panel. Something like this (please excuse your non-l33t graphic skillz): But then when I populate the grid with the rows, the container gets out and it It's really easy, something like that (I captured the original container background edges): I am sure that I am doing something wrong with CSS. Any advice will be appreciated. Edit: The problem is not the width. Its container height is now overlapping with the new height of the population grid. I have noticed that this happens many times when you float in. Add a clearing unit before closing the container. You should always clean after floats. & lt; Div c...

wpf - How to implement DataTable property with INotifyPropertyChanged -

I have created a WPF MVVM application, and WPToolkit has created DataGrid for DataTable so that I can know that the DataTable property To inform how to be implemented, changed. Currently my code is like below. Public Data Test Test {get {this.testTable; } Set {... ... base.OnPropertyChanged ("Test"); }} Public Zero X () {this.Test.Add (...); // I think this line will call the recipient first (get it Test = test) and then it is called Joint Letter, this means that the setter will never be scope. Base.OnPropertyChanged ("Test"); // My solution is here :) but I hope there are better ways to do this} Is there another solution to this problem? You can change 2 ways in your table data: either an element can be added / removed from the archive Or some properties can change from within an element. The first scenario is easy to handle: Make your collection to include a . (T item) or . View deleted items (by you) on your table (and the table will update acco...

WPF TextBox - programatically select text while preserving "selection direction" -

While editing text, the user can use the keyboard shift button and direction keys to modify the selection - in a situation The anchor stays left by the other tricks, it is possible to obtain the running portion of the anchor portion on the left side. I am trying to be dynamic, to modify the selection of users in the WPF text box (for the purposes of discussion, want to select characters in pairs, such as: pressing shift + left , 2 letters will not be selected for one, only). However, while selecting the selection / selection index / careindex / selection of "running end" is always selected at the right end of the selection, the change renders the left combination unusable. Any way to preserve the "selection direction"? This is not the answer that you want but this work. Invite the command and the way WPF does it. Editing Commands Select bedding Exquisite (empty, text box 1);

Simple C array declaration / assignment question -

In high level languages ​​I might be able to do something similar to this example in C and it will be fine. int value [3]; If (1) value = {1,2,3}; Printf ("% i", value [0]); Thanks. You can declare a static array with data, start with: Fixed intervals [3] = {1,2,3}; ... if (1) memv (value, initialize, size);

objective c - How can i tell if an object has a key value observer attached -

If you tell objects object to deleting Objects: for an important path and not registering that key path It has been, SADS. As - A supervisor can not be removed for the main path of 'Kepath' because he is not registered as a supervisor. ' Is there a way to determine whether an object is registered supervisor, so I can do this if (object supervisor) (remove supervisor) Other {go on my way to pleasure} around your deleted Observer call Hold a try @try {[someObject removeObserver: SomeObserver forKeyPath: somePath]; } @chitch (id an exposition) {// nothing, obviously it was not attached because an exception was thrown)

Fetching additional response codes in LDAP (OpenDS) from Java -

OpenAds has a password policy that prevents many login failures. If user is taken to cross the border , Then the log of the LDAP server will be shown, i.e.: [17 / Oct / 2009: 17: 51: 11 +0200] BIND RES conn = 91 op = 0 msgID = 1 result = 49 authFailureID = 197126 AuthFailureReason = "UIId = XXXXXXXX, o = users, DC = XXXXXXX, DC = HR to refuse the request because the account has too many failed authentication attempts The warning has been locked "How to get an LDAP response code on any Java Client API (Tie) other than" Atetime = 1 " Any ideas? Best regards, the burden The solution seems to be that you can not get a numerical response, but you can turn on the bind in the error message (in OpenDes Config), and then you can log in The response to the application code has to be parsed. Ridiculous.

algorithm - Complexity class -

Assume that the methods m1 and m2 are static void and calculate the same result by processing the argument of an object [] From we find that M1 -> T (N) = 100 N and M2 -> T (N) = 10Nlog2N where times are in microseconds. Which type of input is better to use M1 and M2? So I will use M1 for a large number, while I'll use the m2 for a small number right? Just check the answers You can call N & gt; 0 is such that 100N> 10 n log 2 n , so this is just an algebra problem. Divide both sides by 10N and give you the 10 & gt; Log2 N , i.e., N & lt; 2 ** 10 , meaning N & lt; 1024 . It's not like this! -)

Does d3d9.h include windows.h? (C++) -

When I enter #include & lt; D3d9.h & gt; , I no longer need to use the window function like windows.h to WinMain , and CreateWindow for. This is because d3d9 .h & amp; C windows.h ? Primarily, I'm thinking that with windows.h d3d9.h , and still I if you open D3DH Will see . #include & lt; Windows.h & gt; .

jquery - Asset URLs without cache timestamps in Rails -

I am using a transparent PNG with the library. This fix works only on "URLs" which are "-trans." Ends in. Railway timestamp-based caching is causing problems with this when I use image_path () to generate the URL for the image, this file's last-modified timestamp will display the image's query Adds to string. Since the URL does not end in "-trans.png" (instead there is a longer integer in "?"), Google's Javascript fails to activate. I do not want to; On just a few pictures I also do not want to root code the hardcod to relative URL. I want to use the rail to make the URL correctly if the site is posted in root or an (unknown) subdirectory. What options do I have? # Sorry I stopped cuff and this code has not been run - alias_method_chain : Image_path ,: google_sense def image_path_with_google_sense (source) raw_image_path = image_path_without_google_sense (source) if source.end_with? ('- trans.png') # Time stops...

php - Value as the key -

मेरे पास इस तरह एक सरणी है: $ विकल्प [0] = 1; $ विकल्प [1] = 2; $ विकल्प [2] = 3; $ विकल्प [3] = 'कुछ'; कुंजी के रूप में रखे प्रत्येक सरणी तत्व का मान कैसे हो सकता है, तो सरणी इस प्रकार दिखती है: $ विकल्प [1] = 1 ; $ विकल्प [2] = 2; $ विकल्प [3] = 3; $ विकल्प ['कुछ'] = 'कुछ'; क्या इसके लिए एक फ़ंक्शन निर्मित है? $ new = array_combine (array_values ​​($ पुराना), array_values ​​($ पुराना));

javascript - How can I simplify this repetitive jquery? -

यह कोड मुझे एक कस्टम संदेश प्रदर्शित / छुपा देता है msg_one msg_two msg_three जब उचित डिवी कवर किया गया है / छिपा हुआ है उपयुक्त संदेश को #screen div में इंजेक्ट किया जाता है और दिखाता है / छिपाना तब लागू होता है कोड लगभग 2 लाइनों #one vs #two vs #three और संदेश प्रदर्शित किए जाने के अलावा लगभग समान है msg_one msg_two msg_three । मैं पुनरावृत्ति से छुटकारा पाने के लिए इसे कम लाइन में कैसे सरल कर सकता हूं? var msg_one = "message 1"; Var msg_two = "संदेश 2"; Var msg_three = "संदेश 3"; $ ("# एक")। होवर (फ़ंक्शन () {$ ("# स्क्रीन")। Html (msg_one)। दिखाएं ();}, फ़ंक्शन () {$ ("# screen")। Html ("") ।छिपाना(); }); $ ("# दो")। होवर (फ़ंक्शन () {$ ("# स्क्रीन")। Html (msg_two)। दिखाएं ();}, फ़ंक्शन () {$ ("# screen")। Html ("") ।छिपाना(); }); $ ("# तीन")। हॉवर (फ़ंक्शन () {$ ("# स्क्रीन")। Html (msg_three)। दिखाएं ();}, फ़ंक्शन () {$ ("# ...

c# - Would like some modelling tips for dependent values -

I am working on a model for a simple fishing contest and there are some problems with my design. The main class for the fishing game is Capture and it looks like this: Public category imprisonment: unit {public virtual difference weight {receipt; Set; } Public Virtual Inks Length {Received; Set; } Public Virtual DateTime Dataparture {get; Set; } Public Virtual User Captured {Received; Set; } Receive public virtual species species; Set; }} There is no problem yet, but I am not really sure how to make the game a model. Each species is related to a reference that changes year after year The number of points for capture is divided by the current reference weight for species. Problems connecting the species to the capture Wight instead of species Public category species reference: Object {public virtual species species (get set; ;} Public Virtual Ent ReferenceWeight {get; set;} Public Virtual Int Year {Received; Set;}} But in such a way that capturing is related to...

boolean - Python things which are neither True nor False -

मैंने इसे अभी पाया: a = (none,) प्रिंट (a true है ) प्रिंट (ए झूठी) प्रिंट (ए == ट्रू) प्रिंट (ए == फॉल्स) प्रिंट (ए == कोई नहीं) प्रिंट (ए कोई नहीं है) अगर: प्रिंट "हैलो" यदि नहीं तो: प्रिंट "अलविदा" / Code> जो उत्पादन करता है: झूठी झूठी झूठी झूठी झूठी झूठी झूठी हैलो ऐसा न तो है, न ही सही और न ही बराबर है झूठी, लेकिन एक बयान में सच के रूप में कार्य करता है। क्यों? अपडेट: वास्तव में, मैंने अभी महसूस किया है कि यह उतना अस्पष्ट नहीं है जितना मैंने सोचा था। मुझे एक = 2 ​​के लिए एक ही परिणाम मिलता है (यद्यपि एक = 0 या a = 1 के लिए नहीं, जो कि क्रमशः फल्स और ट्रू के बराबर माना जाता है) a एक सदस्यीय ट्यूपल है, जो True के लिए मूल्यांकन करता है ऑब्जेक्ट की है है, इसलिए, आपको उन सभी परीक्षणों में गलत मिलता है == वस्तुओं की समानता का परीक्षण करें, इसलिए, आपको गलत फिर से मिलता है। में यदि कथन __bool __ (या __ नाजरोज़ा __ ) ऑब्जेक्ट का मूल्यांकन करने के लिए प्रयोग किया जाता है, एक गैर खाली ट्यूपल के लिए इसे true वापस करना चाहिए,...

Add strings to array PHP -

Hello I have string 1, array [] and $ string2. I want to create an Arrayue [], such as array [0] = $ string1 array [1] = array [0]. . Arraynew [n-1] = array [n] Arraynew [n] = $ string2 The problem is that I do not know how many elements are in the array [] because it is parsed Please help me. Thank you. In the beginning of the array, insert one or more elements. At the end of the array, one or more elements will be added. Therefore: $ new_array = $ array; Array_unshift ($ new_array, $ string1); Array_push ($ new_error, $ string2);

ant - Apache Ivy multiple resolvers -

The IvyRoundUp packageer is trying to get the repository and to work with chain revolvers in Apache IV, the Meowon repository can be used The following & lt; Settings default Resolver = "Roundup" /> & Lt; Resolver & gt; & Lt; Chain name = "solution" & gt; & Lt; Url name = "cukes" m2compatible = "true" & gt; & Lt; Artifact Pattern = "http://cukes.info/maven/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" / & gt; & Lt; / URL & gt; & Lt; Packager name = "roundup" buildRoot = "$ {user.home} /. Ivy2 / packager / build" resourceCache = "$ {user.home} /. Ivy2 / packager / cache" & gt; & Lt; IV pattern = "http://ivyroundup.googlecode.com/svn/trunk/repo/modules/[organisation]/[module]/[revision]/ivy.xml" /> & Lt; Artifact Pattern = "http://ivyroundup.googlecode.com/svn/trunk/repo/modules/[organization]/[module...

javascript - How can I change the location of a page and not redirect the user? -

I want to be able to change the address of a page but does not want to issue any HTTP requests to that change. How can javascript be used? you mean, i http: //www.fakebank.example And you want to show the address bar to http: //www.yourbank.example ? I think there are obvious reasons that this would not be possible.

iphone - Synchronize Core Data with SQL or MySQL Via SQLite -

I am trying to create an iPhone application using core data created in table management. I want to synchronize the data with an MSSQL or MySQL database. Core data is consistent with SQLite, so I thought it could work as a bridge. Can someone think of how this functionality can be achieved? You are thinking about this wrong thinking, "Implementation" is not compatible with the CoreData SQLite Its a banking store type using SQLite as a description. The actual content of that SQLite DB is undocumented and internal to CoreData. This is a key point, you can not use an arbitrary SQLite3 DB with CoreData, CoreData creates a SQLite3 DB for a particular model. If you want to sync data from another DB in CoreData, then you need a query that you get DB, feedback data, then create and update NSManagedObjects based on that data. The exact description of this (depending on the exact nature of the server) with a DB client library, a webservice and an app server with a DB client l...

Inserting php array data into mysql isn't working -

Hi, I have an array $ name [] that I am trying to include in the other area of ​​my desk but it is not working $ username = "us"; $ Password = "pw"; $ Database = "db"; Mysql_connect (local host, $ user name, $ password); @ Mascil_sact_db ($ database) or die ("error"); $ I = =; While ($ i & lt; 5) {$ query = "Include table values ​​('', '$ name [i]', '', '')"; Mysql_query ($ query); $ I ++} mysql_close (); Any thoughts please? Thank you You used $ instead of i For the key of $ name then try: "Insert table values ​​('' '. $ Name [$ i].' ', Insert in the table values ​​('', ''. Mysql_real_escape_string ($ name [$ i]), '', '', '', '') "" ',' ') "

vb.net how to check if a network drive is mapped persistently -

I use the following code to layout the network drive on a system. I want to add a third column for perseverance, but in vb.net I do not know if there is a continuous map of the drive or not. any suggestion? DriveInfo.GetDrives in DriveInfo for each Drive_info () if drive_info.DriveType (). ToString = "network" then with map ITEM Add (drive_info.Name) .SubItems (Drive_Info.driv type). Toasting) ends with the end if the next drive_info You always get in WMI without any (Well just fine) could do this without the dirty eyes. Example Import System Import System. Management Public Module Modem sub-main () Finder New Management Object Search ("SELECT * FROM Win32_NetworkConnection WHERE LocalName = 'Z:'") Dimmer as a management object for each obj in the explorer. Get Console.WriteLine ("{0} {1}", obj.Item ("LocalName"). ToString, Obj.Item ("continuous")) The next end sub-end module The system can add context to Mnat...

sql - PHP timestamp time function: 2008 is larger than 2009? -

I do not get this. I want to know that the time of the database is before or after the present time, so I have written it: $ qVraagCodeOp = "SELECT * FROM` code` WHERE 'codecod = '$ Value' "; $ RVraagCodeOp = mysql_query ($ qVraagCodeOp); $ AVraagCodeOp = mysql_fetch_assoc ($ rVraagCodeOp); $ Old time = mktime ($ aVraagCodeOp ["Code_Expdate"]); $ Abatement = time (); Echo "database time = $ aVraagCodeOp [Code_Expdate] "; Echo "mktime =" $ longtime " "; Echo "is now timestamp = $ abatement ; The echo is 'today:'. Date ('Y-M-D', $ Auburn). "& Lt; br / & gt;"; Echo "new loan old =" ($ now time - $ old time); Because the database says that the date is somewhere in 2008 and the current date is in 2009, the result of subtraction should be positive. However, this output is: database timing = 2008-12-01 mktime = 1263136596 timestamp now = 1255907796 today: 2009-10-19 new ...

Silverlight 3 with Weborb for Java -

For some reason, I can not open the Java method posted under the Tomcat / Weborb application. When I run Weborb console and call on the method from there, there is no problem. However, when I try to call the Silverlight 3 client, it does not respond completely. There is a possibility that is the wrong service gateway. But I have checked the server path to make sure that it is correct. I also tried different ways to invite server calls such as proxy and class interface mentioned in Weborb documentation. I have already stuck with this problem for two days and can not make further progress. Is this a problem when this problem occurs? I got the solution. The reason for this is that entrance mapping is wrong. For example, when deployed under Weborb, the client uses the localhost: 8080 / Weborb.Dwo However, when you deploy the underworld, then the gateway mapping now changes like a localhost: 8080 / weborb / console / weborb.wo something like this Hope for this help. Cheers, Kh...

javascript - Why are JS scripts usually place in the header of a document? -

Why do JS scripts usually put in the header of a document? Is it necessary for standards or is there any special reason? This is just a conference. It is usually recommended to insert the script at the end of the body so that the pages can display them before loading, which is always a plus. In addition, document.body should not be used until then. Until the document is loaded or if you put the script in the body.

php - unbindModel call in CakePhp. How does it work? -

कैसे केक में unbindModel हो सकता है? $ this- & gt; उपयोगकर्ता- & gt; UnbindModel (सरणी ('हैऔरबल्ंग्सटोमेनी' = & gt; सरणी ('मित्र'))); मैंने एक समारोह की शुरुआत में यह लिखा था। लेकिन फिर भी यह 'मित्र' मॉडल को पूछता है। फ़ंक्शन के मध्य में पृष्ठांकित करें () को कॉल करना था इसलिए मैंने सोचा था कि पेजरनेटर प्रश्नों का सृजन कर सकता है। मैंने पृष्ठबाह्य होने से पहले एक अनबंन्डमोडल कॉल जोड़ा था और यह अब काम करता है। $ this-> User-> ; UnbindModel (सरणी ('हैऔरबल्ंग्सटोमेनी' = & gt; सरणी ('मित्र'))); $ उपयोगकर्ता = $ इस- & gt; पृष्ठांकित करें ("उपयोगकर्ता", सरणी ("उपयोगकर्ता.प्रथम_नाम की तरह" = & gt; $ उपयोगकर्ता ["उपयोगकर्ता"] ["प्रथम_नाव"])); क्या unbindModel हर क्वेरी को खोल देता है? या क्या यह पूरे फ़ंक्शन कॉल के दौरान खोलता है? : Bind- और unbindModel () का उपयोग करके संघों को निकालना या जोड़ना केवल अगला मॉडल ऑपरेशन के लिए काम करता है जब तक कि दूसरे पैरामीट...

vb6 - Replacing a filename problem? -

Use of VB6 In a folder, there is a number of text files, the file name is similar to abc. Mis-.txt, def.fin @ .txt, so I want to rename the filenames like abcmis.txt, deffin.txt. I used a function to change the name. code String file name 3 as 3-Dir $ (txtSourceDatabaseFile and "\ * .txt", vb directory), while filename 3 & lt; & Gt; "" Function to rename " String dim strutput as string dimension stroke as string dimension structure as string dim intChhar as integer dim intro like integer strInput = filename3 IntLoop = 1 for strings (strInput) = mer $ (strInput, intLoop, 1) intChar = asc (strChar) if ((intChar> = 48) and (intChar & lt; = 57) or _ ((intChar & Gt; = 65) and (the initials = 97) and (intChar & lt; = 122)) or _ (intChar = 95) then the strutput = strutput & strchar end If jugal The name txtSourceDatabaseFile & amp; "\" & amp; filename3 = Dir $ Loop txtSourceDatabaseFile & amp; "\...

iphone - How to get the list of all announced bonjour services on all available domains? -

This is not a problem of viewing in all domains, but I do not find the right way to look for any service network . One way to find old threads but local services is to get you the type of results in the right format There will be some need to manipulate. It works on Mac & amp; However, if no WiFi connection is found on the iPhone, then no service is available. NSNetServiceBrowser * domainBrowser = [[NSNetServiceBrowser alloc] init]; DomainBrowser.delegate = self; [Domain Brace SearchForce ServicesOpt Type: @ "_ services._dns-sd._udp." InDomain: @], "local."

c# - How should I gracefully handle faulty AppDomains? -

Is this code snippet poorly designed? Basically, there was only one AppDomain.Unload , finally in the block. Due to its unfathenetate side effects, other threads could keep running in the AppDomain while UnhandledException was running, which uses user input from other things and therefore is very slow on the computing scale (average actual Runtime can be> 1min), possibly throwing other exceptions and generally causing more problems. I am stuck on thinking about a 'better' way of doing it, therefore, I lend it to my mind. Note: I realized that there are also synchronization issues. Yes, I know what they are, stay focused. mainApp = AppDomain.CreateDomain (ChildAppDomain, Blank, AppDomain.CurrentDomain.SetupInformation); Try {mainApp.ExecuteAssembly (assembly.net Entry Assembly (.).); Ends = true; } Hold (Exception Pre) {AppDomain.Unload (mainApp); MainApp = null; Unrestricted Exception (this, new unfade expansion event (pre, wrong)); } Finally {if (mainApp! = Ta...

visual studio 2008 - How to prevent auto-closing of curly braces in ReSharper? -

A simple question. I am trying to get riders and it closes my curl braces for me as soon as I open them, I really dislike this "feature" and I have about the settings window Three look tall and I do not know how to disable it! Am I missing a clear check box somewhere? Edit: Uncheck the "Auto Clothessis" after completing No } To appear for If (true) {I it does not seem to do anything with completing intellisense. To turn off this behavior, open the ReSharper option and click the Editor tab On, uncheck the Auto insert end brace option. There should be no need to resume the visual studio.

wpf events and chain of responsibility pattern -

Is there something similar with a series of responsibility patterns in events being rooted by WPF? I googled for this and I am not talking to anyone about this: s, although I though the event with that routite is the implementation of that pattern Ok, I think this is such, the events occurring in WPF are the implementation of the chain of responsibility system / Html>

python - Django: How to model a MySQL VARBINARY HEX Field? -

I am trying to model a VARBINARY MySQL field in Django v1.1.1. Binary field represents a hexadecimal data (i.e. any one will use INSERT INTO test (bin_val) VALUES X'4D7953514C ' ) Reading Django document [1] I came With this solution: class MyTest (models.Model): bin_val = BinValField () class BinValField (models.Field): __metaclass__ = models.SubfieldBase def to_python (self, value): " "Db -> For the value of the byte ('% x% X'% ((ord (byte))> 4) & amp; 0xF, ord (byte) and 0xF)) Def ('' Latin 1 '') ) However, this does not work correctly because Django makes a Unicode change of binary data from MySQL When saving a new MyTest object, called get_db_prep_value () twice (I think this is a bug in Django?) The question is How would you prepare such an area? PS: Related to this problem The ticket is [2] which has still been opened after 3 years: ( [1] Django: Writing custom model field [2] The problem cr...

c# - Get Data Value From ListView ItemDataBound -

I'm sure I did it before, but really do not remember how. In the ItemDataBound event of a ListView I need to get the actual data value. I find it in the list of theVITIM events in the Argus object which passes it. Thanks I think what you are doing after this

osx - Is OS X Installer package postflight localization supported? -

मैंने एक ओएस एक्स इंस्टॉलर पैकेज बनाया है जिसमें स्थानीय संसाधन (License.html, Readme.html, आदि) शामिल हैं विशेष रूप से, इसमें एक स्थानीयकृत पोस्टफ़्लइट स्क्रिप्ट शामिल है, चूंकि पोस्ट-इंस्टॉल कार्रवाइयों में से कुछ भाषा से भाषा में भिन्न है; इंस्टॉलेशन पूर्ण होने के बाद प्रति-भाषा फाइल खोलना, उदाहरण के लिए। पैकेज स्वचालित निर्माता के हिस्से के रूप में बनाया गया है, पैकेज मेकर के माध्यम से नहीं। मूल रूप से मैंने 'पूर्ण' लोकेल नाम को स्थानीय संसाधन फ़ोल्डर नाम के रूप में प्रयोग किया; उदाहरण के लिए, अंग्रेजी। सब कुछ ठीक काम किया हाल ही में, मैंने आईएसओ नाम, अर्थात एनएएलपीआरयू के लिए स्विच किया, क्योंकि मुझे पता चला कि पैकेज मेकर क्या इस्तेमाल कर रहा था, और यह इंगित करता है कि फॉर्म को प्राथमिकता दी जाती है। सब कुछ ठीक उसी तरह काम करता था, सिवाय इसके कि पोस्टफ़्लाइट स्क्रिप्ट अब निष्पादित नहीं की गई है। मैंने कुछ और परीक्षण किए, और देखा कि, जब भी यह काम करता है (फ़ोल्डर के नाम के रूप में पूर्ण भाषा नाम का उपयोग करके) , यह इस संदेश को कंसोल में लॉग करता है: स्थानीय इंस्ट...

java - HTML page to XHTML with TagSoup -

Sorry, if this is very easy, but I could not find the tutorial only, nor did I get the documentation of Java version of TagSoup. Actually I want to download an HTML webpage from the Internet and it is contained in the string XHTML Want to change How can I do this with TagSoup? Thank you! something like this: wget-o - example.com/ Bad.html | Java -jar tagsoup.jar Or, from Java: To parse the HTML: Create an example org.ccil.cowan.tagsoup.Parser Provide your SAX2 content handler Provide an input source HTML Is referring to and pars () !

sql - sp_FuzzyLookupTableMaintenanceInstall not found while running SSIS package -

I have an error while running an SSIS package: DTS_E_OLEDBERROR returned an OLE DB error Is ..... "could not get stored functionality system. SP_FuzzyLookupTableMaintenanceInstall" I connect to my DB and I am able to find the stored function. sp_FuzzyLookupTableMaintenanceInstall sys assembly stored procedure 2008-11-24 14: 23: 08.930 I do not know what is happening. I have installed: Microsoft SQL Server Management Studio 9.00.4035.00 Microsoft Analysis Service Client Tools 2005.090.4035.00 Microsoft Data Access Components (MDAC) 2000.086.3 9 59.00 Microsoft MSXML 2.6 3.0 4.0 6.0 Microsoft Internet Explorer 6.0 .3790.3959 Microsoft. Net Framework 2.0.50727.3082 Operating System 5.2.3790 Thank you for your support! A very quick check value: Which version of SQL Server is running? Fuzzy lookup is one of the only features I'm thinking of.

flex - Flash Player Internals Diagram -

A part of the components of flash player such as AVM1, AVM2, graphics renderer, text layout engine, video to be shown Ordinary drawing player, etc. Can somebody help me out? Thank you. You can read, anyone who has edited for AVM1. Here.

javascript - Tooltip using Prototype.js -

The tooltip for the prototype library seems easy to use. People who are outside are so bloated. What I see is simple in this way. & lt; A class = "tooltip" & gt; This is my sentence & lt; Span & gt; Tooltip is here & lt; / Span & gt; Which ends in sadness. & Lt; / A & gt; & Lt; A class = "tooltip" & gt; How can I do this & lt; Span & gt; Like how? & Lt; / Span & gt; Without killing people & Lt; / A & gt; I have a CSS solution but the problem is one time, tooltip is close to the browser, it gets farthest from the corner. I like to be smart and by the side of the browser window Do not go Anyway? I was thinking about using the prototype to find and move the X-W coordinates of the pop-up. But how to do it? This is what I am using for CSS .date_info a: hover {background: #ffffff; Text-decoration: None;} / * For IG6 * BG color is required. / Dat_info a.tooltip span {display: none; Padding: ...

Python| How can I make this variable global without initializing it as 'global' -

I have this code here. After the 'I = 1' line, the code can be added to main_____ only one part. This script will execute several times and there may be some variables in it (maybe 'i', 'xy', 'var', anything can happen), every time we need to increase from 1. I have found it to work by declaring 'I' worldwide, but unfortunately, I can not keep it like this. Is there a way in which I can act as 'I' within a above mentioned parameters a global variable? DIF main ______ (): Try: Excluding I + = 1, NameError: i = 1 main ______ () If you want to use global variables, you have to declare it in the global form. What's wrong with that? If you need to store state between calls, then you should use a class & gt; & Gt; & Gt; Square F (): ... def __init __ (self): ... self.i = 0 ... def __call __ (self): ... print self.i ... self.i + = 1. .. & gt; & Gt; & Gt; F = F ()> gt; & Gt; & Gt; F () 0 ...

return from a JMP in assembly x86? -

I am calling a proxy to test two values ​​in assembly x86 16bits and then being larger than zoomman I jumped on, so I'm doing something like this: Inquiry Process CMP X, 1GG FU Reset Tested ENDP Food: Do Something, eat Main: Call Test. Ext and Main and My question is simple, I eat again by pointing back to MEIN, which is called testit. I do not want to eat JMM from FOO, The phone will be called again when I try to put the REET at the end of the food, the command window gets trapped with a blinking cursor. Note: I know that the pseudo session can be obtained using . ADIF Instead of JG, but I want to achieve and achieve the same results without a pseudo session, which does some magic in the background, I do not know how to get it manually. The food should be called as a suboutin. To do this, use the call instruction to overturn the logic of your leap, and call FOO. Give an RET instruction at the end of regular eating. Inquiry Process CMP X, 1 Jelly Bar Call Fu Ba...

php - building first custom CMS and have been told to use Dreamweaver and a plug in called Horizontal Looper -

So I'm just a bit over my head and want to verify that I have been given good advice on how to This is a book site for creating a simple CMS site, and some image galleries (for example, for one letter) where the user clicks on different thumbnails and displays a span with text descriptions and large images . Here the plug-in was instructed to buy me: Has anyone used this before? Or does anyone have any other ideas, about how to do it as soon as possible? The deadline is approximately 2 weeks away, and I came to know how to make my database phpmyadmin Thank you for reading :) At this time I strongly recommend I do not try to make it from scratch. Go with "Something" from the shelf. Drujo Drupal div>

c# - Reasons for windows service to stop -

I have designed a Windows service in C #, which runs continuously and creates three threads. The first thread runs every 15 seconds The second thread runs every minute and thirs only runs once. My problem is that these windows are somehow closed after a few days. Nothing is logged in the eventlog on the day of the stop. And it did not write anything logging file. I want to know that several reasons for a windows can be suddenly shut down and this service is not on my DEV box, it is on the QA server. Hope this makes sense! You probably have an unused exception on one of your threads - since the .NET 2.0, Unscrupulous exceptions will take the process down suddenly like this. Ensure that there is a catch block to handle errors above the stack for any thing running on a thread (log, swallow, martial to the other thread, whatever). You can temporarily stop this behavior by adding the following to your service .exe.config file (such as returning to pre-.NET 2.0 behavior): ...

C# - Minimize to tray at system startup -

In my application, I have an option to start the application when Windows starts, this works great I also have That is, when minimized, the app is reduced to the system tray. Is there any way on which it can be automatically reduced at the same time as Windows? The way I could think, it is to regain the amount of time at which the system is running and uses that data to decide if the machine has started recently or not. Obviously there are a lot of flaws with that theory. Do you have any other ideas about how this can be done? Apply a command line switch to your program that causes your program to reduce from the tray When you start the program with Windows startup, just include the switch.

c# - how to delete file -

Hi, I have a Winform that uses this to display this configuration (which I load into the image box, I create this image box in runtime). ) When I select any of this image and delete it (I Folder), but problem when I delete it: file. Delete (path_OF_Image); C # gives me the message that can not delete this file because the process uses this file. But I settle all the picture boxes or containers (my entire picture box is) But the problem still exists. I'm assuming that you're loading the file name directly by using (ie Image.FfrFile ); This can be caused by troubleshooting because NIIT being hanged on resources used by GDI + Library, so I recommend loading file bytes for the first time, and then I will initialize that image. For example: byte [] imageBytes = File.ReadAllBytes (fileName); Image image; (MemoryStream MS = New MemoryStream (ImageBits)) {image = Image.FromStream (ms); }

javascript - ASP.Net Display Different Text in Label Control At Interval -

I have an old web application written in ASP.NET 2.0+ AJAX. I have a text box control in my page and a button and a label control that is inside an updated panel. A text will be entered in the textbox and later, on the textworld event of control, some server-side processing and data validation are included. I am using label control as a control so that the progress of the user can be progressed. Different messages can appear in the label control. In the current scenario, only the last string labeled for the label control is displayed on the control. I'm looking for ways to be able to display different text on label control, say at a 5 second interval. Is there an AJAX control for this (or something that I could use), where I can specify the text to appear at intervals of seconds? How do I get it? The input is highly appreciated thanks. Edit I think I may need to make a phrase again to simplify this question. After posting an Asp.net page, how will I be able ...

.NET Conditional Compiler Symbols and Unit Test Libraries -

My team has a set of unit testing libraries that run against our application code - unfortunately they are throwing exceptions (unexpected) exceptions. The reason for this is that our logging code is being called and the items have not been setup. The logging code has been implemented through a method attribute, which we have setup using PostSharp (which is said before and after the method body). This feature should not be called. Here is where PostSharp helps us out: it searches for a conditional compiler directive (SIPPOSSTSHRAP) which asks for it not to be executed. In other words, if we define the instruction, while the unit tests are executed, then we can independently examine the desired code with the logging aspect - on the way, avoiding unnecessary dependencies and complex joke codes successfully. This is great! Except for a catch ... a conditional compiler directive defined for our test project is not being defined for the project - which means that under the test our code...

Unable add namespace with PHPs SimpleXML -

I am creating an Atom feed when I add xmlns: i as an attribute Tried below - $ node-> Add Add ("xmlns: i", "http://www.w3.org/2001/XMLSchema-instance"); I found it as output - i = "http://www.w3.org/2001/XMLSchema-instance" "xmlns:" part was cut. I need to avoid : - character? Or is there any other way of adding this namespace? If you want to add an attribute from the namespace / prefix i $ node Not already disturbed in declaring the namespace in the first parameter, use the third parameter of addAttribute () to provide the namespace Yuri for the prefix. $ node = new SimpleXMLElement ('& lt; root & gt; & lt; / root & gt;'); $ Node- & gt; Add Junk ("i: somename", "somevalue", 'http://www.w3.org/2001/XMLSchema-instance'); Echo $ node-> AsXml (); Print & lt ;? Xml version = "1.0"? & Gt; & Lt; Root xmlns: i = "http://www.w3.or...

java - When is messaging (e.g. JMS) an alternative for multithreading? -

I work on a data processing application, wherein several units of work on a country are given concurrency, in which many Examples are a message inspired bean (MDB). Others, in order to obtain concurrency, we have no specific reason to use messaging infrastructure and MDB. It motivated me to think about why it could not be obtained using multiple threads. So my question is, in what circumstances can asynchronous messaging (eg. JMS) be used as a means of conversion as an instrument for aggregation? It can not be used as a multithreading option, to implement multithreading One way is to provide three basic types of solutions: You are responsible for both ends of the queue; You are responsible for sending data; You are responsible for getting the data. The kicker is here to get the data because there really is no way to do this, without multi-threading, multi-threading / multiprocessing will process only one request at a time. Sending data is more viable, but there y...

stl - hash_map on AIX? -

I am porting A program to AX which uses hash_map in many places. Linux and Solaris are included in the hash_map _gnu_cxx package and stlport. However, I can not find the hash_map on the Ax platform. anyone know? > I think you want & lt; Unordered_map> The reason for the Ax xlc compiler is that & lt; Hash_map & gt; is a GCC extension. You have to change your code to make a few different names (or picks up with the translation layer).

How can i test tilt efftect? - IPhone Simulator -

I'm trying to write a game, this game uses the inclination effect, but I do not know whether it's an iPhone simulator How to test at 3.0 I search it on the internet, but the result is zero. How do I ...? short answer: You can not directly do that you have to use a real device. Long answer: You can subcategory UIAccelerometer and do as much as you like. You can simulate the input or send acceleration information to the app that runs the client and server pair from a real device to the simulator or accelerometer from your MacBook if you imagine your laptop waving around it

ms access - DateTime picker control, problematic behavior -

A datetime control on a form, linked to a table field, works fine. If I add a picker inside I get this error when I control the tab when I load the form: There was an error in the call for the Windows Date and Timer picker control. Anyone have the solution to this problem? If you are starting the value of DTPC and it is not visible, Receive: // If it is not in the selected tab, then a shortcut to make it visible: DTPicker.SetFocus DTPicker.Value = Now

c# - a simple Regex question -

I'm trying to learn about im regex, and how it uses braking some logs and the results With some text boxes populated If I have such a simple line Port status: tro-S-02-av1 0/23 and tro-S- 02 All names on Eva 1 end, thus regular axis should be based on this. I was thinking that I wanted to become a string-s-02-av1 string text box, but I can not get it properly, how can I do this? Regex r; Match Me; R = new regenges ("$` \ av1 "); Me = R. Match ("Port Status: ST-S-02-AV1 0/23"); Nodetbx.Text = m.Value; Using groups with the following regex (for example, you can probably clear it) will give you two named groups, Id 1 and ID2, then you can populate. I found using nominated groups when learning for the first time is regex, then you can actually see what is happening. regex r = new regex ("Port Status: (? Id> [\ d \ w \ -] +) \ s (& lt ;; Id2> [\ s \ s] +) "); Matchcolene MC = RMacente (Mytext); Foreach (Match M in MC...

How can I autoincrement a Perl hash value? -

डेटाबेस डेटा: पासपोर्ट_नहीं बैंक स्टेटमेंट_no क्रेडिट_आईडी 4126897 एचएसबीसी 2948608 0 4126897 एचएसबीसी 294860 9 1 4126858 एचएसबीसी 2948591 0 4126858 बार्कलेज 29485 9 0 4126858 बार्कलेज 2948596 1 4126858 बार्कलेज 2948597 2 क्रेडिट आईडी बैंक पर आधारित है। Credit_id (यह मुझे भरने की ज़रूरत है) 0,1,2,3,4 मैं इस तरह से स्वचालित करने की कोशिश कर रहा था अगर ($ क्रेडिट {$ passport_no} {$ bank}) {$ क्रेडिट { $ passport_no} {$ बैंक} - & gt; {$ बयान} ++; } और {$ क्रेडिट {$ passport_no} {$ bank} - & gt; {$ statement} = 0; } और मुझे इसे बाहर निकाला गया है: VAR1 = '4126897'; $ VAR2 = {'एचएसबीसी' = & gt; {'2948608' = & gt; 0, '2 9 4860 9' = & gt; '1'}}; $ VAR3 = '4126858'; $ VAR4 = {'एचएसबीसी' = & gt; {'2948591' = & gt; 0}, 'बार्कलेज' = & gt; {'2948595' = & gt; 0, '2948596' = & gt; '1', '2948597' = & gt; '1'}}; लेकिन मैं ...

date - javascript conversion of yyyy-mm-dd hh:mm:ss aa help -

Can anyone make a mistake in this ceremony? .. It is a function that receives a string of yyyy-mm-dd hh: mm: ss A and converts to UTC and a string yyyy-mm-dd hh: mm: ss. Function localizedUUTC (local time) {var time = localTime.split (""); // received: - yyyy-mm-dd hh: mm: ss aa var yearday = time [0] .split ("-"); Var dateTime = time [1] .split (":"); Var ampm = time [2]; Var hour = 0; Var year = Yerde [0]; Var Finer = Yerde [1] -1; Var day = Yerde [2]; Hours = date time [0]; Var minutes = Date time [1]; Var seconds = Datetime [2]; / * We need to convert it to 24 hours format for the first time * 12:00:00 AM: 00:00:00 * 12:00:00 PM: 12:00:00 * 12 * 1:00 AM AM Even time: 1:00:00 * 1:00:00 PM: 13:00:00 * / if (PM == "PM") {// If it is 12 PM, then 12 will be causing problems (hours! = 12) {hours + = 12; }} And // am case {if (hour == 12) {hours = 00; }} Var = = new date (year, month, day, hour, minute, second); Var utcString = now.getUTCFull...

asp.net - fileUpload control appearance -

I use the fileUpload control in the asp.net web page, so I use the "Browse" button as any other How can I control the button? etc. I want to change the "browse button" back color, border style Thank you in advance. How can I control the "Browse" button like any other button? Are you sure there will be a browse button? It depends on web browser; Some may not have text-plus-browse arrangements at all. Specifically arranges safari control in a different way. For security reasons, and because there is no standardization about what the file upload control should look like, CSS does not give almost control about the style of file upload control. Although the opacity hack described in the links of phonics works, I will not recommend it at all. There is no guarantee of receiving the 'clickable' portion of the input control, which is standing with the part of your ErtatControl, which looks clickable. Even on the same browser, different f...

linq to sql - How can I clone (or copy) a object to another one, but don't copy PK attribute? -

I'm trying to copy all object attributes to another object, FOX example: person p1 = new person (); P1.name = "John"; P1.sex = 'M'; Person p2 = new person (); P2 = Utill. Clone (p1); The problem is that the person unit has an identity PK 'codprison' and I do not want to copy this PK. Is there a way to clone / copy an object, but it does not have a copy of its PK attribute ?? Thank you! Make sure that Util.Clone (person p) codeproduction attribute Clear the attribute after the clone method Create a new person object, especially starting the special properties.

c++ - Is there any free or commercal jpeg decode which is really fast -

I am using c ++, libjpeg to decode jpeg file. I think it's not fast enough, is there a way to make it faster by setting up a compiling parameter? Or can any other Linux JPEG files open faster? Now a 4368 * 2912 4m JPEG takes approximately 750 mm to open the image. I want it to be reduced to 150 mms. thanks a lot! Added: IJL seems faster than libjpeg :) Most The faster the way it is not decoded at all. Generally you can use a low-res preview first; That requires only fewer frequencies to preview 546 x 289 pixels, you actually only need (0,0) (DC) component.

xml - Alternative in ActionScript for "DataMember" in C# -

Currently I am translating the app from C # to Action Script (Silverlight to Flex) and I have some action script XML content must be serialized. Now, unfortunately, I need a variable in the XML file to keep the other names from the nodes. I tried an alternative solution with gates and setters to work on setting this variable, but I failed on gates, because when you make the variable personal, the original AS3 'Simplex Xmlencoder' ignores it. The best solution would be, if I variable The way it worked in C #. Just like this: [datamember (name = "something")) Some types of public type {get; Set; } Is there any way to do something in the action process? I have only found one, which is for classes: [remote class (alias = "user")] I hope I described my first question well and my English is fine. Thank you. :) This is strange because I have not used any of these After writing how easy it was to have C #. We can release it as a library ...

python - How should I optimize this filesystem I/O bound program? -

I have a Python program that does something like: Read a line from Make some changes on this. Break it into real lines as they will be written in the database. Write those lines to individual CSV files. Back to step 1, until the file is completely read. Run the SQL * loader and load those files in the database. Step 6 is actually not taking too much time It seems that the highest time in step 4 is taking up for the most part, I have a quad with any type of RAID setup I want to optimize this to handle a set of records in the millions of dollars running on the Core server. There are some ideas that I have to solve: Read the whole file from one step (or at least read it in a great deal) and the file is full in the disk Or write as a very large volume It is being thought that it will spend less time going back and forth between hard disk files and files. Will it do something that will not buffering? Parameters 1, 2 and 3, and 4 in separate process. It will not have ...

what is the SQL to display a number (200909) as Sep 2009 in Teradata 12 -

What is SQL to display a number (200 9) in TerraData 12 in September 2009 Teratata Store dates as integer as follows: (year - 1900) * 10000 + (months) * 100) + day Then you remove 1900 from the year and add one day to make the number one valid date, then that Enter the format that only shows months and years. Choose Cast (CAST ((2009-09-1900) * 100 + 1 AS DATE format 'm3by4') as (8));

c# - passing css class name to asp.mvc view helper -

In ASP.NET MVC view assistant, you can do something like & lt ;% = Html.ActionLink ("Click me", "DoSomething", blank, new {someAttribute = "a value"})%> which will produce the following HTML & lt; A href = "doSomething" some attribute = "one value" & gt; Click me & lt; / A & gt; My question is ... What if I want to set the "class" attribute? & lt;% = Html.ActionLink ("click me", "doodonting", blank, new {class = "a-class-name"})%> This will not compile because "class" is a reserved word. Is there a work-around? Yes, using this:

sql server - SQL update value to highest date in table -

I have the following problem: Suppose I have a table with the following fields: [ [ID] [start date] [status date] [status description] [ID] is not unique, and therefore I may have: introduced ID Date Status Position Position 123 01 / 01/2009 01/01/2009 Start 123 01/01/2009 01/02/2009 Change 123 01/01/2009 01/03/2009 Change 123 01/01/2009 01/07 / 2009 Pause What I want to do is the following: all on one record Alen, where [status] = 'Start'. When this is done, the part that I do not know is the following: I want to update [status date] and [status] with the last status date. To wit. What do I need: ID start date position status status 123 01/01/2009 01/07/2009 Stop Any suggestions? [edit] I am using SQL Server 2008 By putting it in, I mean create a new table and In it there are only those records which "to get a table with unique ID I'm not sure if Do you want the latest date and status for any ID? It will: SELECT a.ID, a.StatusDat...

c# - Manipulate Referenced Object -

Is there any way that I can pass in the context of an object, manipulate it within my method which is straight Replaces the referenced object? For example, I want to pass a dropdown list in my method, it should be manipulated and done. This method is being taken to any dropdown list: public static void mismatched (dropdown list list 1, ref dropdown list list 2) {// just manipulating the dropdown here ... There is no need to come back just add or remove some values ​​from the list 2} Obviously I can not just pass the dropdownlist object to list2, how can I do this? I am going to delete some values ​​in the list and it will be a good utility method, so I do not have to repeat this code everywhere for this functionality that I am performing in the law. If you are manipulating the internal data of a single reference type, then you have some special Do not want. When passing an object there is a reference type for a method that you do not copy, instead you pass the context...

Create a dropdown list in Sharepoint containing List Documents with links to them -

I'm looking to create a dropdown list on my default .aspx page, which I want to list / Include pages and the document / page is selected, the page needs to be redirected to the selected document / page. How can this be done, any suggestions of this? Any examples / specimens will be appreciated? thanks :) A selected value in AA drop down and one selected Text is property This will display the selected text. Store a name or some type of string that recognizes the document as the selected text. Store the actual document hyperlink where this document resides or where the link should be taken to the value you have selected. Set autopost right on the drop down. Throw this code into an on-the-selected index event: Response Redirect (Me.ddlLinks.SelectedValue)

Share session data between Rails and PHP -

I have a Rail application that uses ActiveRecordStore for sessions to share the session with me running a subdomain A PHP application is required I have given the session permission to access session cookies in the subdomain, but I do not know what the php application should do to reach the session data, can someone help me in the next step? Thank you in advance I believe the best solution is to memkach For both sessions to handle PHP and Rail will be for both. If you type a simple cover (a number online actually available) for each, you will be able to access the same data from either application.

c++ - Network File Streaming Performance Vista -

How do I get the best file streaming performance in Vista? My goal is to read a large file (several hundred MB) directly on the network in one memory. I've allotted the same size as the memory block file. It is also my destination buffer. I tried ReadFile , _read , fread , , and boost :: Iostreams :: Mapped_file :: const_data - _O_SEQUENTIAL or FILE_FLAG_SEQUENTIAL_SCAN is appropriate when specifying However, I could not match the throughput through the simple cut-paste file copy. I receive only 50% of the file copy performance regularly - What is the explorer done by the task manager differently, and how can I get the same level of performance? How big is the chunks that you read every time? If they are too small or too big, then you are not using the network for your full potential