Search Results

Search found 2178 results on 88 pages for 'directors cut'.

Page 5/88 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Printing Pdf using AirPrint causes cut-off content

    - by Jatin Patel
    Here i am printing pdf with size 'pageSize = CGSizeMake(640, 832);'. this size is larget then A4 size page aspected. so i will cut-off some text(means it will not print whole page). while printing same pdf using MAC, it will print whole page with help of option (scale to fit). so can any one help me to come out from this problem.. is there any option in IOS sdk for scale to fit. here is my code.. -(void)printItem { NSArray *aArrPaths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) ; NSString *aStr = [[aArrPaths objectAtIndex:0] stringByAppendingPathComponent:[NSString stringWithFormat:@"PropertyReport_%d.pdf",self.propertyId]]; // NSString *aStr = [[NSBundle mainBundle] pathForResource:@"TRADUZIONE HELP SECTIONS REV2" ofType:@"pdf"]; NSURL *url=[[NSURL alloc] initFileURLWithPath:aStr]; NSData *data=[[NSData alloc] initWithContentsOfURL:url]; printController = [UIPrintInteractionController sharedPrintController]; if(printController && [UIPrintInteractionController canPrintData:data]) { printController.delegate = self; UIPrintInfo *printInfo = [UIPrintInfo printInfo]; printInfo.outputType = UIPrintInfoOutputGeneral; //printInfo.jobName = [NSString stringWithFormat:@"New Image"]; printInfo.duplex = UIPrintInfoDuplexLongEdge; printController.printInfo = printInfo; printController.showsPageRange = YES; printController.printingItem = data; void (^completionHandler)(UIPrintInteractionController *, BOOL, NSError *) = ^(UIPrintInteractionController *printController, BOOL completed, NSError *error) { if (!completed && error) { //NSLog(@"FAILED! due to error in domain %@ with error code %u", error.domain, error.code); } }; // aWebViewPDF.hidden=FALSE; [printController presentAnimated:YES completionHandler:completionHandler]; } } Thanks Jatin Patel

    Read the article

  • Silverlight: Button template with texttrimming cut off

    - by dex3703
    I'm replacing the default Button template's ContentPresenter with a TextBlock, so the text can be trimmed when it's too long. Works fine in WPF. In Silverlight the text gets pushed to one edge and cut off on the left, even when there's space on the right: Template is nothing special, just replaced the ContentPresenter with the TextBlock: <Border x:Name="bdrBackground" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" /> <Rectangle x:Name="rectMouseOverVisualElement" Opacity="0"> <Rectangle.Fill> <SolidColorBrush x:Name="rectMouseOverColor" Color="{StaticResource MouseOverItemBgColor}"/> </Rectangle.Fill> </Rectangle> <Rectangle x:Name="rectPressedVisualElement" Opacity="0" Style="{TemplateBinding Tag}"/> <TextBlock x:Name="textblock" Text="{TemplateBinding Content}" TextTrimming="WordEllipsis" TextWrapping="NoWrap" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/> <Rectangle x:Name="rectDisabledVisualElement" Opacity="0" Style="{StaticResource RectangleDisabledStyle}"/> <Rectangle x:Name="rectFocusVisualElement" Opacity="0" Style="{StaticResource RectangleFocusStyle}"/> </Grid> </ControlTemplate> How do I fix this? More info: With the latest comment about HorizontalAlignment, it's clear that SL's implementation of TextTrimming differs from WPF's. In SL, TextTrimming only really works if the text is aligned left. SL isn't smart enough to align the text the way WPF does. For instance: WPF button: SL button with the textblock horizontalalignment = left: SL button with textblock horizontalalignment = center:

    Read the article

  • Choosing between Facebook iframe scrollbar or page cut off halfway

    - by pg.
    I have an iframe tab in facebook. I used "overflow:hidden" in the body tag and this code at the bottom of my page: <div id="fb-root"></div> <script type="text/javascript"> window.fbAsyncInit = function() { FB.init({ appId : 'MY_APP_ID', status : true, // check login status cookie : true, // enable cookies to allow the server to access the session xfbml : true // parse XFBML }); FB.Canvas.setAutoResize(100); }; (function() { var e = document.createElement('script'); e.async = true; e.src = document.location.protocol + '//connect.facebook.net/en_US/all.js'; document.getElementById('fb-root').appendChild(e); }()); </script> This removes the scrollbars and resizes the iframe. The problem is that my page is cut off after about 800px (that leaves about 400px). I've set the height in facebook to "fluid". It works absolutely fine in every other browser but not in IE8. As a side question, why does IE still exist? It's the absolute worst thing. Anyways, I added this to the head: <!--[if IE]> <style> body{overflow-y:scroll;} </style> <![endif]--> But that just gets me back to having the scrollbars again.

    Read the article

  • selected area to cut an image

    - by Oskar Marciniak
    Hi I would do the selected area to cut an image on picturebox control. I have the following code: using System; using System.Drawing; using System.Windows.Forms; namespace WindowsFormsApplication1 { public partial class Form1 : Form { private Rectangle rect; private Pen p; public Form1() { InitializeComponent(); } private void pictureBox1_Paint(object sender, PaintEventArgs e) { if (this.p == null) this.p = new Pen(Color.FromArgb(100, 200, 200, 200), 5); if (this.rect.Width > 0) e.Graphics.DrawRectangle(this.p, this.rect); } private void pictureBox1_MouseUp(object sender, MouseEventArgs e) { if (e.X < this.rect.X) { this.rect.Width = this.rect.X - e.X; this.rect.X = e.X; } else { this.rect.Width = e.X - this.rect.X; } if (e.Y < this.rect.Y) { this.rect.Height = this.rect.Y - e.Y; this.rect.Y = e.Y; } else { this.rect.Height = e.Y - this.rect.Y; } this.Invalidate(this.rect); } private void pictureBox1_MouseDown(object sender, MouseEventArgs e) { this.rect.X = e.X; this.rect.Y = e.Y; } } } It returns an error here: Application.Run(new Form1()); Why? thanks for all replies ;p

    Read the article

  • Finding minimum cut-sets between bounded subgraphs

    - by Tore
    If a game map is partitioned into subgraphs, how to minimize edges between subgraphs? I have a problem, Im trying to make A* searches through a grid based game like pacman or sokoban, but i need to find "enclosures". What do i mean by enclosures? subgraphs with as few cut edges as possible given a maximum size and minimum size for number of vertices for each subgraph that act as a soft constraints. Alternatively you could say i am looking to find bridges between subgraphs, but its generally the same problem. Given a game that looks like this, what i want to do is find enclosures so that i can properly find entrances to them and thus get a good heuristic for reaching vertices inside these enclosures. So what i want is to find these colored regions on any given map. My Motivation The reason for me bothering to do this and not just staying content with the performance of a simple manhattan distance heuristic is that an enclosure heuristic can give more optimal results and i would not have to actually do the A* to get some proper distance calculations and also for later adding competitive blocking of opponents within these enclosures when playing sokoban type games. Also the enclosure heuristic can be used for a minimax approach to finding goal vertices more properly. A possible solution to the problem is the Kernighan-Lin algorithm: function Kernighan-Lin(G(V,E)): determine a balanced initial partition of the nodes into sets A and B do A1 := A; B1 := B compute D values for all a in A1 and b in B1 for (i := 1 to |V|/2) find a[i] from A1 and b[i] from B1, such that g[i] = D[a[i]] + D[b[i]] - 2*c[a][b] is maximal move a[i] to B1 and b[i] to A1 remove a[i] and b[i] from further consideration in this pass update D values for the elements of A1 = A1 / a[i] and B1 = B1 / b[i] end for find k which maximizes g_max, the sum of g[1],...,g[k] if (g_max > 0) then Exchange a[1],a[2],...,a[k] with b[1],b[2],...,b[k] until (g_max <= 0) return G(V,E) My problem with this algorithm is its runtime at O(n^2 * lg(n)), i am thinking of limiting the nodes in A1 and B1 to the border of each subgraph to reduce the amount of work done. I also dont understand the c[a][b] cost in the algorithm, if a and b do not have an edge between them is the cost assumed to be 0 or infinity, or should i create an edge based on some heuristic. Do you know what c[a][b] is supposed to be when there is no edge between a and b? Do you think my problem is suitable to use a multi level problem? Why or why not? Do you have a good idea for how to reduce the work done with the kernighan-lin algorithm for my problem?

    Read the article

  • After HTTP GET request, the resulting string is cut-off - content has been consumed

    - by Jayomat
    hi all, I'm making a http get request like this: try { HttpClient client = new DefaultHttpClient(); String getURL = "http://busspur02.aseag.de/bs.exe?SID=5FC39&ScreenX=1440&ScreenY=900&CMD=CR&Karten=true&DatumT="+day+"&DatumM="+month+"&DatumJ="+year+"&ZeitH="+hour+"&ZeitM="+min+"&Intervall=60&Suchen=(S)uchen&GT0=Aachen&T0=H&HT0="+start_from+"&GT1=Aachen&T0=H&HT1="+destination+""; HttpGet get = new HttpGet(getURL); HttpResponse responseGet = client.execute(get); HttpEntity resEntityGet = responseGet.getEntity(); if (resEntityGet != null) { //do something with the response Log.i("GET RESPONSE",EntityUtils.toString(resEntityGet)); } ........ It all works well... the only problem: the output from Log.i is cut-off... It's not the complete html page. If I make the same request in a browser, I get 3x the output in opposition to making the request in the emulator and using the above code.... what's wrong? ERROR: 04-30 14:01:01.287: WARN/System.err(1088): java.lang.IllegalStateException: Content has been consumed 04-30 14:01:01.297: WARN/System.err(1088): at org.apache.http.entity.BasicHttpEntity.getContent(BasicHttpEntity.java:84) 04-30 14:01:01.297: WARN/System.err(1088): at org.apache.http.conn.BasicManagedEntity.getContent(BasicManagedEntity.java:100) 04-30 14:01:01.307: WARN/System.err(1088): at org.apache.http.util.EntityUtils.toString(EntityUtils.java:112) 04-30 14:01:01.307: WARN/System.err(1088): at org.apache.http.util.EntityUtils.toString(EntityUtils.java:146) 04-30 14:01:01.307: WARN/System.err(1088): at mjb.project.AVV.ParseHTML.start(ParseHTML.java:177) 04-30 14:01:01.307: WARN/System.err(1088): at mjb.project.AVV.ParseHTML.onCreate(ParseHTML.java:139) 04-30 14:01:01.307: WARN/System.err(1088): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047) 04-30 14:01:01.327: WARN/System.err(1088): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2459) 04-30 14:01:01.327: WARN/System.err(1088): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2512) 04-30 14:01:01.327: WARN/System.err(1088): at android.app.ActivityThread.access$2200(ActivityThread.java:119) 04-30 14:01:01.347: WARN/System.err(1088): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1863) 04-30 14:01:01.347: WARN/System.err(1088): at android.os.Handler.dispatchMessage(Handler.java:99) 04-30 14:01:01.347: WARN/System.err(1088): at android.os.Looper.loop(Looper.java:123) 04-30 14:01:01.347: WARN/System.err(1088): at android.app.ActivityThread.main(ActivityThread.java:4363) 04-30 14:01:01.347: WARN/System.err(1088): at java.lang.reflect.Method.invokeNative(Native Method) 04-30 14:01:01.357: WARN/System.err(1088): at java.lang.reflect.Method.invoke(Method.java:521) 04-30 14:01:01.357: WARN/System.err(1088): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860) 04-30 14:01:01.357: WARN/System.err(1088): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618) 04-30 14:01:01.357: WARN/System.err(1088): at dalvik.system.NativeStart.main(Native Method )

    Read the article

  • HttpClient POST fails to submit the form + resulting string is cut-off (incomplete)

    - by Jayomat
    Hi, I'm writing an app to check for the bus timetable's. Therefor I need to post some data to a html page, submit it, and parse the resulting page with htmlparser. Though it may be asked a lot, can some one help me identify if 1) this page does support post/get (I think it does) 2) which fields I need to use? 3) How to make the actual request? this is my code so far: String url = "http://busspur02.aseag.de/bs.exe?Cmd=RV&Karten=true&DatumT=30&DatumM=4&DatumJ=2010&ZeitH=&ZeitM=&Suchen=%28S%29uchen&GT0=&HT0=&GT1=&HT1="; String charset = "CP1252"; System.out.println("startFrom: "+start_from); System.out.println("goTo: "+destination); //String tag.v List<NameValuePair> params = new ArrayList<NameValuePair>(); params.add(new BasicNameValuePair("HTO", start_from)); params.add(new BasicNameValuePair("HT1", destination)); params.add(new BasicNameValuePair("GTO", "Aachen")); params.add(new BasicNameValuePair("GT1", "Aachen")); params.add(new BasicNameValuePair("DatumT", day)); params.add(new BasicNameValuePair("DatumM", month)); params.add(new BasicNameValuePair("DatumJ", year)); params.add(new BasicNameValuePair("ZeitH", hour)); params.add(new BasicNameValuePair("ZeitM", min)); UrlEncodedFormEntity query = new UrlEncodedFormEntity(params, charset); HttpPost post = new HttpPost(url); post.setEntity(query); InputStream response = new DefaultHttpClient().execute(post).getEntity().getContent(); // Now do your thing with the facebook response. String source = readText(response,"CP1252"); Log.d(TAG_AVV,response.toString()); System.out.println("STREAM "+source); EDIT: This is my new code: try { HttpClient client = new DefaultHttpClient(); String getURL = "http://busspur02.aseag.de/bs.exe?SID=5FC39&ScreenX=1440&ScreenY=900&CMD=CR&Karten=true&DatumT="+day+"&DatumM="+month+"&DatumJ="+year+"&ZeitH="+hour+"&ZeitM="+min+"&Intervall=60&Suchen=(S)uchen&GT0=Aachen&T0=H&HT0="+start_from+"&GT1=Aachen&T0=H&HT1="+destination+""; HttpGet get = new HttpGet(getURL); HttpResponse responseGet = client.execute(get); HttpEntity resEntityGet = responseGet.getEntity(); if (resEntityGet != null) { //do something with the response Log.i("GET RESPONSE",EntityUtils.toString(resEntityGet)); } } catch (Exception e) { e.printStackTrace(); } But the output file is cut-off. If I do the same request in a browser I get like 14 different routes. Now the file suddenly stops and I only get 3 routes.... what's wrong? 04-30 12:19:12.362: INFO/GET RESPONSE(256): <!-- Ausgabebereich (automatisch erzeugt) --> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <div align="center"> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <p></p> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <p>Ihr Fahrplan für die Verbindung von Aachen, Kaiserplatz nach Aachen, Karlsgraben am Freitag, den 30.04.2010 (Koniginnedag), Abfahrten ab 12:19 Uhr</p> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <table class="Result"> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="fussnote">Fussnote</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="fahrzeug">Fahrzeug</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="abfahrt">Abfahrt</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="haltestellean">Haltestelle</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="linie">Linie</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="haltestelleab">Haltestelle</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="ankunft">Ankunft</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <th class="fahrzeit">Fahrzeit/Tarif</th> 04-30 12:19:12.362: INFO/GET RESPONSE(256): </tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <td>&nbsp;</td><td>&nbsp;<img src="http://www.busspur.de/logos/efa-bus.gif" title="Niederflurbus"></td><td>12:23</td><td title="lc0">Aachen, Kaiserplatz [Heinrichsalle Ri. Hansemannplatz]&nbsp;<a href="http://download.avv.de/Umgebungsplaene/hlp_ac_kaiserplatz.pdf">Umgebungsplan</a></td><td>45</td><td title="lc0">Aachen, Karlsgraben&nbsp;<a href="http://download.avv.de/Umgebungsplaene/hlp_ac_karlsgraben.pdf">Umgebungsplan</a></td><td>12:34</td><td>00:11 /  1,00</td><td>&nbsp;</td> 04-30 12:19:12.362: INFO/GET RESPONSE(256): </tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr><td colspan="9"><a href="/bs.exe?RI=0&amp;SID=5FC39">Fahrtbegleiter</a>&nbsp;&nbsp;</td></tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr><td colspan="9"><hr></td></tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <td>&nbsp;</td><td>&nbsp;<img src="http://www.busspur.de/logos/efa-bus.gif" title="Niederflurbus"></td><td>12:26</td><td title="lc0">Aachen, Kaiserplatz [Heinrichsalle Ri. Hansemannplatz]&nbsp;<a href="http://download.avv.de/Umgebungsplaene/hlp_ac_kaiserplatz.pdf">Umgebungsplan</a></td><td>22</td><td title="lc0">Aachen, Karlsgraben&nbsp;<a href="http://download.avv.de/Umgebungsplaene/hlp_ac_karlsgraben.pdf">Umgebungsplan</a></td><td>12:37</td><td>00:11 /  1,00</td><td>&nbsp;</td> 04-30 12:19:12.362: INFO/GET RESPONSE(256): </tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr><td colspan="9"><a href="/bs.exe?RI=1&amp;SID=5FC39">Fahrtbegleiter</a>&nbsp;&nbsp;</td></tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr><td colspan="9"><hr></td></tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <td>&nbsp;</td><td>&nbsp;<img src="http://www.busspur.de/logos/efa-bus.gif" title="Niederflurbus"></td><td>12:28</td><td title="lc0">Aachen, Kaiserplatz [Heinrichsalle Ri. Hansemannplatz]&nbsp;<a href="http://download.avv.de/Umgebungsplaene/hlp_ac_kaiserplatz.pdf">Umgebungsplan</a></td><td>25</td><td title="lc0">Aachen, Karlsgraben&nbsp;<a href="http://download.avv.de/Umgebungsplaene/hlp_ac_karlsgraben.pdf">Umgebungsplan</a></td><td>12:39</td><td>00:11 /  1,00</td><td>&nbsp;</td> 04-30 12:19:12.362: INFO/GET RESPONSE(256): </tr> 04-30 12:19:12.362: INFO/GET RESPONSE(256): <tr><td colspan="9"><a href="/bs.exe?RI=2&amp;SID=5FC39">Fahrtbegl

    Read the article

  • How to use a string as a delimiter shell script

    - by Dan
    I am reading a line and am using regex to match it in my script. (/bin/bash) echo $line | grep -E '[Ss][Uu][Bb][Jj][Ee][Cc][Tt]: [Hh][Ee][Ll][Pp]' > /dev/null 2>&1 if [[ $? = "0" && -z $subject ]]; then subject=`echo $line | cut -d: -f2` > /dev/null echo "Was able to grab a SUBJECT $line and the actual subject is -> $subject" >> $logfile fi now my problem is that i use the colon as the delimiter. but sometimes the email will have multiple colons in the subject and so I am not able to grab the whole subject because of that. I am looking for a way to grab everything after the colon following subject. even is there is a way to loop through and check for a colon or what. maybe cut allows you to cut with a string as delimiter? Not sure...any ideas? Thanks!

    Read the article

  • How to cut a URL with regular expression

    - by AhmadAssaf
    Hello, i am trying to chop a string that contains several information in java .. the text is something like that : <a href="http://www.hootsuite.com" rel="nofollow">HootSuite</a> i am thinking of using the .split method that need regular expression .. what i want it to split this string into the URL without quotes .. http://...... .com and then the text between the tags .. this case HootSuite .. i will appreciate the help Thank you

    Read the article

  • Crontab: cut line to many lines?

    - by Heoa
    Hard-to-read-line @daily export sunshine="~/logs/Sunshine-`date '+\%F'`" && export sunshineUrl="http://www.sunshine.net/main/search_results.asp?currency_id=1&min_price=&max_price=50000&country_id=241&region_id=&Submit=Search" && mkdir -p $sunshine && cd $sunshine && wget --mirror -l 1 $sunshineUrl Which mark do I need to have it on many lines? @daily <SOME MARK HERE> export sunshine="~/logs/Sunshine-`date '+\%F'`" && <SOME MARK HERE> export sunshineUrl="http://www.sunshine.net/main/search_results.asp?currency_id=1&min_price=&max_price=50000&country_id=241&region_id=&Submit=Search" && <SOME MARK HERE> mkdir -p $sunshine && <SOME MARK HERE> cd $sunshine && wget --mirror -l 1 $sunshineUrl No success by appending \, //, \n or /n.

    Read the article

  • UIWebView paging / line cut off

    - by John
    Hi, I am trying to page a webpage, so disable scrolling, then the second page is the same webpage scrolled down the page height. The problem I have is that the bottom of the first page often has 1/2 a line of text, then the second page has the bottom half of the line. Is there a way to ensure the entire line falls on one of the pages? Similar to Stanza etc? Thanks

    Read the article

  • [AS3] BitmapData cut-off

    - by Fristi
    Hello, I am writing a MovieClip rasterizer which rasterizes all the frames in the specified movieclip. Here's the code for rasterizing: for ( var i:int = start; i <= end; i++ ) { //goto the next frame clip.gotoAndStop( i ); //get the bounds bounds = clip.getBounds(clip); //create a new bitmapdata container bitmapData = new BitmapData( transformer.width == -1 ? bounds.width : transformer.width, transformer.height == -1 ? bounds.height : transformer.height, transformer.transparent, transformer.color ); //rotate the clip if (clip.rotation != 0) transformer.rotate( clip.rotation * (Math.PI / 180) ); //scale the clip if (clip.scaleX != 1 || clip.scaleY != 1) transformer.scale( clip.scaleX, clip.scaleY ); //translate the movieclip to its zero point if (transformer.matrix.tx == 0 && transformer.matrix.ty == 0) transformer.translateToZero( bounds ); //draw the bitmap data with the transformers bitmapData.draw( this._source, transformer.matrix, transformer.colorTransform, transformer.blendMode, transformer.clipRect, //new Rectangle(0, 0, bounds.width, bounds.height), transformer.smoothing ); //push the data on the array frames.push( bitmapData ); } Now the result is different - http://i42.tinypic.com/lfv52.jpg - (note the head and left shoe). Anyone knows what the problem is? I've seen people adding 'extra' pixels to their boundary box at the BitmapData constructor, but thats nasty imo.

    Read the article

  • Java Date Hibernate cut off time

    - by Vlad
    Hi folks, I have a Date type column in Oracle DB and it contains date and time for sure. But when I'm trying to get data in java application it will return date with bunch of zeros instead of real time. In code it'll be like: SQLQuery sqlQuery = session.createSQLQuery("SELECT table.id, table.date FROM table"); List<Object[]> resultArray = sqlQuery.list(); Date date = (Date)resultArray[1]; If it was 26-feb-2010 17:59:16 in DB I'll get 26-feb-2010 00:00:00 How to get it with time?

    Read the article

  • Actionscrips/Flex4: Display cut-off datapoints differently in LineChart

    - by Limited Atonement
    Dear Sirs, The issue arises when the user selects a range on the linechart that cuts off datapoints. When this happens, I would like the chart to tell the user somehow that there are data points three, just outside the range, perhaps by drawing a straight line across the top or bottom of the graph. How can I get Flex to do this for met? Let me know if you understand the question, or if you need more information, and of course, let me know the answer! Thanks! Sincerely, Aaron

    Read the article

  • Cannot execute cut-n-paste VBScripts

    - by IcedDante
    I have been going mad trying to figure out why my scripts weren't working, until I started copying and pasting sample source code directly from a few websites only to have it fail there as well. I am getting the following error in my VBScripts: C:\temp\vbs\script.vbs(19, 53) Microsoft VBScript compilation error: Expected statement' For a line of code that looks like this: wdoc.Application.Selection.Find.Execute Replace:=wdReplaceAll This is interfacing with Microsft Word in Office 2007 to conduct a search and replace. Index 53 point directly to the := part of the assignment. Since this type of syntax doesn't work on my machine and I am using it from several websites, I was wondering if the cscript.exe I use is out of date. Am I not calling cscript properly?

    Read the article

  • [Java] Cut <br/>-Tags from String end

    - by Robert M.
    Hello everybody, I am currently developing a Web-Application using Java EE where I'm using a Rich-Javascript-Editor (http://www.primefaces.org/showcase/ui/editor.jsf). As the user can easily add too many linebreaks that will be convertet to linebreak-tags, I need to remove all these Tags from the end of a String. Is there an elegant way of using Regex to accomplish this? An example String would be: "This is a test <b>bold</b><br/><br/>" Where obviously the last two tags have to be removed. Thank you in advance for any help Best Regards, Robert

    Read the article

  • Select a particular column using awk or cut or perl

    - by javed abbas
    Have a requirement to select the 7th column. eg: cat filename | awk '{print $7}' The issue is that the data in the 4th column has multiple values with blank in between. example - The last line in the below output: user \Adminis FL_vol Design 0 - 1 - group 0 FL_vol Design 19324481 - 3014 - user \MAK FL_vol Design 16875161 - 2618 - tree 826 FL_vol Out Global Doc Mark 16875162 - 9618 - /vol/FL_vol/Out Global Doc Mark

    Read the article

  • UITableView cell text is cut off.

    - by Mr. McPepperNuts
    I am having a problem with the UITableview cell cutting off strings whose characters are more than 12 chars. Any ideas why this would occur? I have not made a custom cell at all. I cannot find any solution to this problem through a Google search. Any ideas?

    Read the article

  • Aquaterm: titles and axis labels getting cut off

    - by VL3East
    I'm using aquaterm 1.0.1 through octave and gnuplot - on my mac - to generate printable plots. When aquaterm generates my plots, it has a habit of cutting off or cropping all of the titles and axis labels. Is there another imaging program that works with octave that won't have this problem? Or are there other fixes I haven't thought of?

    Read the article

  • I need to cut a portion of a string in linux

    - by Abeed Salam
    I have a file in a folder like this: installer-x86_64-XXX.XX-diagnostic.run The XXX.XX is a version number and I need the version number only. How to do it in linux? I have this code: #!/bin/bash current_ver=$(find /mnt/builds/current -name '*.run'|awk -F/ '{print $NF}') So this gives me just the name of the file correctly (minus the location, which I dont want). But how do I only get the XXX.XX version number into a variable such as $version

    Read the article

  • loop is cut one element of the array

    - by Walaa
    The problem is : Write a program that reads a number n and then declares an array of n elements. The program then fills the array with the first n numbers, where each number is two to the power of the previous. Finally, display array’s contents. My code : import java.util.*; public class Q1 { static Scanner scan = new Scanner (System.in); public static void main(String args [] ) { int num; int i = 0; System.out.println("Enter a number :"); num = scan.nextInt(); double [] a=new double[num]; a[0]= num ; for ( ;i<=a.length-1 ; i++) { a[i+1] = Math.pow(2,a[i]); System.out.println((int)(a[i]) ); } } } The error is : ----jGRASP exec: java Q1 Enter a number : 4 4 16 65536 Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 4 at Q1.main(Q1.java:16) ----jGRASP wedge2: exit code for process is 1. why it says that? And the number by user printed twice!

    Read the article

  • Inheriting a Base Form but Paste/Cut Commands Not Captured

    - by ohu812
    I created a base form that has a specific size and an icon as a base for all forms created in my project (to be consistent in looks). The problem is, for some reason if I add a Text box to the Child form, I can no longer execute shortcuts like Copy (CTRL+C) etc into the Textbox. What should I do to handle this OTHER THAN writing code to capture those on the KeyUp control? This is also the case for RichTextBox control as well. Thanks

    Read the article

  • cut text after (x) amount of characters

    - by Blackbird
    This is in wordpress (not sure that makes a difference) This bit of php outputs the post title <?php echo $data['nameofpost']; ?> It's simple text which can be anywhere up to 100 chars long. What i'd like is if the chars outputted are over 20 long to display '...' or simply nothing at all. Thanks

    Read the article

  • How do I cut and paste commands from your blog?

    - by Maria Colgan
    At the recent ODTUG  Kscope 12 conference several people told me that they really enjoyed our blog on the Optimizer but were frustrated because they couldn’t cut and paste the commands used in the blog posts straight into their environment. Typically I use screen shots in the blog posts to make the commands clear but it does mean that it is impossible to cut and paste the commands into your environment. In order to get around this I have created a downloadable .sql script for each of our blog posts. You should now see the sentence “You can get a copy of the script I used to generate this post here”, appearing at the bottom of each blog post. Clicking on the link will open the .sql script that contains all of the commands used in the post. You can either save the entire script or just cut and paste the particular command you are interested in! I have added scripts for all of this year’s blog posts and am slowly making my way through our old posts until we have a script for everything we have posted to date. Hopefully this will help! +Maria Colgan

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >