3
голосов
1ответов
1012 просмотров

DataBinding with a DataRow - problems

I am currently coding a project under c# and am experiencing problems. I'll give a brief description of my form: It has a datagridview on the bottom half of the form with single row selection, and is read only. On the top half of the form I have various components which are databound to the sele...

0
голосов
1ответов
157 просмотров

Copy of "Format Document" function in Visual Studio?

I am looking for an app that can do what the "Format Document" function does in Visual Studio. Something really stupid (maybe even an add-on to a normal text editor) that will basically turn this: <div><table><tr><td><?php echo 'earth'; ?></td></tr></...

2
голосов
4ответов
1850 просмотров

Human-readable binary data using Python

My work requires that I perform a mathematical simulation whose parameters come from a binary file. The simulator can read such binary file without a problem. However, I need to peek inside the binary file to make sure the parameters are what I need them to be, and I cannot seem to be able to do...

0
голосов
5ответов
3415 просмотров

Output in two rows for multiple columns in python

I'm working with an output list that contains the following information: [start position, stop position, chromosome, [('sample name', 'sample value'), ('sample name','sample value')...]] [[59000, 59500, chr1, [('cn_04', '1.362352462'), ('cn_01', '1.802001235')]], [100000, ...

11
голосов
4ответов
36277 просмотров

How can I know if a TIFF image is in the format CCITT T.6(Group 4)?

How can I know if a TIFF image is in the format CCITT T.6(Group 4)?

4
голосов
3ответов
2540 просмотров

String.format()

"%11.2lf" of C++ is equivalent to ? You guys have any resource that shows the equivalent formats for both Java and C++?

2
голосов
6ответов
19396 просмотров

c# datetime format

I wish to have a specific format for my DateTime depending on the current culture. So I try this: dateTime.ToString("dd/MM/yyyy hh:mm"); This is partially OK, the / gets replaced by the culture-specific separator. But the day and month order are not switched (like MM/dd) depending on the cul...

3
голосов
5ответов
13490 просмотров

php money_format

i am trying to remove the .00 at the end of the price function getMoney($mon) { setlocale(LC_MONETARY, 'en_US'); return money_format('%.2n', $mon); } Thank You,

24
голосов
5ответов
89761 просмотров

Format date from database?

When I pull the date out of the db, it comes back like this: 2009-10-14T19:00:00 I want to format it in two different ways... The first: F d, Y The second h:m (12 hour format) Everything I try returns December 1969... Help?! I feel so confused...

3
голосов
3ответов
2998 просмотров

mysql select concat(charfield, format(doublefield,8)) gives error 1267

which is ironic on two counts, 1) because concat(charfield, doublefield) works (it doesn't mind when one of the fields to be concatenated is numeric) and 2) because the mysql reference shows this: CONCAT(str1,str2,...) as the prototype for CONCAT and for FORMAT this: "FORMAT(X,D) Formats the num...

2
голосов
6ответов
1548 просмотров

Which text editors have a format code option?

I'm looking for a basic text-editor with code format like NetBeans or Intellij. In NetBeans IDE and Intellij IDE you have the option format code. Something like this, if( a == b ) { bla; bla; bla; } after using this feature it will look like this: if...

3
голосов
2ответов
945 просмотров

WCF service to return iCal

How do I get my service written with WCF to return an iCal? The examples I see use either xml or json as the way to format the response. What is the best way to return other types of response bodies?

20
голосов
4ответов
47762 просмотров

Django: How to format a DateField's date representation?

I have a form with a DateField. The existing date value is formatted to render like this: 2009-10-03 How can I format that so that it look like this: 03.10.2009 I found a widget which renders it like this, but validation doesn't allow the values I enter then.

2
голосов
2ответов
7359 просмотров

conversion from string yyyyMMdd to type integer is not valid

I have a dataset containing a datatable, and I enumerate all rows in that datatable. When trying to format a column in that row, I run into an exception. (Part of) the code is: For Each dr As DataRow In ds.Tables("records").Rows file = dr("timestamp").ToString("yyyyMMdd") & "~.wav" Next ...

0
голосов
4ответов
2148 просмотров

save Linked List in Notepad.txt

I draw many triangle polygons and store it in Linked List. My problem is that, when I store the drawing in a Notepad file, the data is unreadable (weird symbol). When I try to print it using println the output is like this [email protected] How to store the coordinate of the polygon in ...

1
голосов
2ответов
2633 просмотров

String Format Does Not Works For string

I have a serial number which is String type. Like This; String.Format("{0:####-####-####-####}", "1234567891234567" ); I need to see Like This, 1234-5678-9123-4567; Bu this Code does not work? Can you help me?

0
голосов
3ответов
4998 просмотров

how to write a batch file to format excel?

i'd like to write a batch file that would open a static Excel document and format it (from say 10 pages to 2 pages, taking out the empty columns) so that it is print ready. any ideas on how to format the excel document using my batch file? It could be a .VBS file as well I suppose.

3
голосов
4ответов
17768 просмотров

PHP mail line break problem

I want to format content of the mail to show the content in different line. here is my message contetn. bu the \n and \r is not working in this case. it just shows all the content in one line. $message = 'Thank you for using . We really appreciate your business.'."\r\n".'If you are making yo...

2
голосов
2ответов
1589 просмотров

Delphi function to convert a string to DOS format

I'm using the FINDSTR function to filter text files, but it's failling on extended ASCII characters. I tried using the CharToOEM function, but I still have characters such as 'à', which FINDSTR doesn't seems to recognize. I want to use FINDSTR because the text files I work with are 100MB big, s...

1
голосов
3ответов
186 просмотров

PHP: strtotime()... again

How do I have to write "+3 days at 12:34:56" to make strtotime() parse it properly?

16
голосов
5ответов
9068 просмотров

What is the difference between plaintext and binary data?

Many languages have functions which only process "plaintext", not binary. Does this mean that only characters within the ASCII range will be allowed? Binary is just a series of bytes, isn't it similar to plaintext which is just a series of bytes interpreted as characters? So, can plaintext stor...

1
голосов
4ответов
328 просмотров

How to output floating point numbers in the original format in C++?

It's a coding practice. I read these numbers as double from a file: 112233 445566 8717829120000 2.4 16000000 1307674.368 10000 2092278988.8 1234567 890123 After some computation, I should output some of them. I want to make them appear just the same as in the file, no filling zeros, no scientific...

0
голосов
2ответов
2957 просмотров

c# Datagridview cell not accepting currency format change

I am trying to change the format of a cell in a datagridview using the following code. this.dataGridView[2, 1].ValueType = typeof(decimal); this.dataGridView[2, 1].Value = 500; this.dataGridView[2, 1].Style.BackColor = System.Drawing.Color.OrangeRed; this.dataGrid...

1
голосов
1ответов
564 просмотров

OpenXML - CellFormats - Do I really need to configure one for every single permutation?

I'm currently working with v2.0 of the SDK to generate an Excel workbook and it was all going well until I came to apply the cell formatting. I've created a few CellFormats and successfully applied them but there are a few more permutations that I need to configure: 4 fonts (normal, bold, ital...

35
голосов
6ответов
52164 просмотров

Set Default DateTime Format c#

Is there a way of setting or overriding the default DateTime format for an entire application. I am writing an app in C# .Net MVC 1.0 and use alot of generics and reflection. Would be much simpler if I could override the default DateTime.ToString() format to be "dd-MMM-yyyy". I do not want thi...

1
голосов
1ответов
862 просмотров

Iphone detect Region Format

I want to to deliver different iTunes buy links to a user depending on where there Region Format is set (in general settings). Is there a way to detect that and then deliver a separate database to each users region? Thanks for the help. GS.

11
голосов
3ответов
14977 просмотров

Is there a way to format a String in Flex

Is it possible to do something like this: var s:String = format("%20d %-10s %s", time, type, message); In languages like C, C++, C#, Python, and Perl there is something similar to my example, but I can't seem to find it for Flex. I don't want to create special class Formatter for every string...

22
голосов
3ответов
20898 просмотров

How to format traceback objects in Python

I have a traceback object that I want to show in the nice format I get when calling traceback.format_exc(). Is there a builtin function for this? Or a few lines of code?

0
голосов
1ответов
4798 просмотров

C# form custom textbox format binding

I haev an object with a DateTime property. I want to map the time to a textbox (thus want the user enter the time, it's directly reverberated to my property). However I just want to display the time. How can I say this (ie the format should be something like hh:mm to be correct). Less specifcl...

3
голосов
3ответов
10875 просмотров

c#, Set datagridview column format after datasource has been set

i have a datagridview that i have populated programmatically and i was wondering how i can make one of the columns conform to a specified format - "C2". Can this be done after the datasource has been assigned? Cheers.