473,804 Members | 3,399 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Reading Books and some C#

Hi , i`ve been wondering how many days do you guys need to read an average
asp.net programming book, answer honestly please, for example 800 pages big,
how many pages a day? I just wanna see if i m reading too slow... :)

Next question, i have a simple function from my latest book here and the
authors of "Wrox Beginning Asp.net with c#" were not to eager to explain the
meanings of the theory of code they used in their example so i guess i
should figure it out on my own, maybe with the help from a good soul,
So there are some confusions in the function which i d appreciate being
clarified,

The code first...

<code>
private DateTime GetSafeDate(str ing proposedDate)
{
// Returns a non-null DateTime even if proposed date can't be parsed
DateTime safeDate;
try {
safeDate = DateTime.Parse( proposedDate,
DateTimeFormatI nfo.InvariantIn fo);
} catch (Exception e) {
Response.Write( "<!-- Failed to parse date: " + e.Message + " -->");
safeDate = DateTime.MinVal ue;
}
return safeDate;
}
</code>

What i m confused about is the "DateTime.Parse " which seems like a property
of an object or something, i know DateTime is a type of variable but i m not
sure what this means here,

Also, the "DateTimeFormat Info.InvariantI nfo" is not too clear to me either,
do you have any idea?

Thats it,
Thanx!

--
Its easier to stay out then get out.
Nov 15 '05 #1
9 1438
Well, if I have nothing else going, I could probably go through a book that
size in about a week or two.

Having said that, you should not make determinations on how fast others
read. The real question is, do you understand what you are reading and can
you apply it. Although I may read the book quickly, I don't read with the
expectation that I will be an expert (in fact, I don't even try the sample
code). My goal is usually to get a high-level understanding of the
technology and how it interacts with other systems. This is so that I know
what tools are available to solve particular problems. Only when a problem
needs solving do I dive into more detail.

DateTime is a structure (similar to a class). Parse is a method that takes
a string value and converts it into a DateTime instance. Pretty much all
your datatype have a Parse method.

I have not done much with formatting, but generally formatting allows you to
specify the culture the string was formatted in. Each country has their own
delimiters. Now, looking at that example, I think that you could have
probably just run the Parse without the second parameter and received the
same results.

"Worker" <wo****@work.ne t> wrote in message
news:bn******** **@ls219.htnet. hr...
Hi , i`ve been wondering how many days do you guys need to read an average
asp.net programming book, answer honestly please, for example 800 pages big, how many pages a day? I just wanna see if i m reading too slow... :)

Next question, i have a simple function from my latest book here and the
authors of "Wrox Beginning Asp.net with c#" were not to eager to explain the meanings of the theory of code they used in their example so i guess i
should figure it out on my own, maybe with the help from a good soul,
So there are some confusions in the function which i d appreciate being
clarified,

The code first...

<code>
private DateTime GetSafeDate(str ing proposedDate)
{
// Returns a non-null DateTime even if proposed date can't be parsed
DateTime safeDate;
try {
safeDate = DateTime.Parse( proposedDate,
DateTimeFormatI nfo.InvariantIn fo);
} catch (Exception e) {
Response.Write( "<!-- Failed to parse date: " + e.Message + " -->");
safeDate = DateTime.MinVal ue;
}
return safeDate;
}
</code>

What i m confused about is the "DateTime.Parse " which seems like a property of an object or something, i know DateTime is a type of variable but i m not sure what this means here,

Also, the "DateTimeFormat Info.InvariantI nfo" is not too clear to me either, do you have any idea?

Thats it,
Thanx!

--
Its easier to stay out then get out.

Nov 15 '05 #2
I% SAY :::
Hi , i`ve been wondering how many days do you guys need to read an average
asp.net programming book, answer honestly please, for example 800 pages big,
how many pages a day? I just wanna see if i m reading too slow... :)

not a lot, but i read a little bit each day
of the book, "c# class design, coding effective
classes". i think i know the basics of asp.net
web mechanics, i have programmed services, client
applications and console application, so now i
want to learn how to really design using OOP.

isn't that the poing of languages like c# and
java, to liberate us from the mechanics so we
can concentrate on design?



Next question, i have a simple function from my latest book here and the
authors of "Wrox Beginning Asp.net with c#" were not to eager to explain the
What i m confused about is the "DateTime.Parse " which seems like a property
of an object or something, i know DateTime is a type of variable but i m not
sure what this means here,


funny you should ask, because if you read
the book above you would know.

in the .Net framework, while there are many
'primitive' datatypes, the point of .Net is
that it supports many object datatypes, which
are not only datatypes but carry with them
methods and properties that apply to data and
that datatype.
Nov 15 '05 #3
I R BABOON wrote:
Next question, i have a simple function from my latest book here
and the authors of "Wrox Beginning Asp.net with c#" were not to
eager to explain the
What i m confused about is the "DateTime.Parse " which seems like a
property of an object or something, i know DateTime is a type of
variable but i m not sure what this means here,


funny you should ask, because if you read
the book above you would know.


Correct me if i m wrong but i have seen no explanation of DateTime.Parse in
the whole book.
I`ve read it, and i dont remember it being explained, i ve also searched the
index and theres no such
thing mentioned there either, i might be wrong though.

--
Its easier to stay out then get out.
Nov 15 '05 #4
I% SAY :::
I R BABOON wrote:
Next question, i have a simple function from my latest book here
and the authors of "Wrox Beginning Asp.net with c#" were not to
eager to explain the
What i m confused about is the "DateTime.Parse " which seems like a
property of an object or something, i know DateTime is a type of
variable but i m not sure what this means here,
funny you should ask, because if you read
the book above you would know.


Correct me if i m wrong but i have seen no explanation of DateTime.Parse

in
ok, did you look it up here:

http://msdn.microsoft.com/library/de...arsetopic1.asp

there's some code at the bottom.
the whole book.
I`ve read it, and i dont remember it being explained, i ve also searched the
index and theres no such
thing mentioned there either, i might be wrong though.

--
Its easier to stay out then get out.


Nov 15 '05 #5
>Having said that, you should not make determinations on how fast others
read. The real question is, do you understand what you are reading and can
you apply it. Although I may read the book quickly, I don't read with the

I agree with Peter. If yuu went by my answer, you would never finish
a book. :)

As Peter says, what you should do is take as long as you need to read
a book and understand the material as you go along. What is what
learning is all about.

I am studying for the 70-316 exam right now. I had planned originally
to take it this week, but things have changed. I need to do more
studying. :)

Nov 15 '05 #6
Don't know if this would help u or not. Here's the
link to source code implements the "InvariantI nfo"

Browse around it and other c# test code for the "InvariantI nfo"
might help you understand it better.

http://www.slink-software.com/W/SL_T...0/LN_264#L_261
--
The "source" is out there.
"Worker" <wo****@work.ne t> wrote in message news:<bn******* ***@ls219.htnet .hr>...
Hi , i`ve been wondering how many days do you guys need to read an average
asp.net programming book, answer honestly please, for example 800 pages big,
how many pages a day? I just wanna see if i m reading too slow... :)

Next question, i have a simple function from my latest book here and the
authors of "Wrox Beginning Asp.net with c#" were not to eager to explain the
meanings of the theory of code they used in their example so i guess i
should figure it out on my own, maybe with the help from a good soul,
So there are some confusions in the function which i d appreciate being
clarified,

The code first...

<code>
private DateTime GetSafeDate(str ing proposedDate)
{
// Returns a non-null DateTime even if proposed date can't be parsed
DateTime safeDate;
try {
safeDate = DateTime.Parse( proposedDate,
DateTimeFormatI nfo.InvariantIn fo);
} catch (Exception e) {
Response.Write( "<!-- Failed to parse date: " + e.Message + " -->");
safeDate = DateTime.MinVal ue;
}
return safeDate;
}
</code>

What i m confused about is the "DateTime.Parse " which seems like a property
of an object or something, i know DateTime is a type of variable but i m not
sure what this means here,

Also, the "DateTimeFormat Info.InvariantI nfo" is not too clear to me either,
do you have any idea?

Thats it,
Thanx!

Nov 15 '05 #7
DateTime.Parse is a *static* method, meaning to call it you don't use an
instance of DateTime, but the DateTime class itself. DateTime.Parse takes a
String parameter and returns a DateTime (or throws an exception).

The InvariantInfo bit has to do with the culture. You want to use the
Invariant culture.

"Worker" <wo****@work.ne t> wrote in message
news:bn******** **@ls219.htnet. hr...
Hi , i`ve been wondering how many days do you guys need to read an average
asp.net programming book, answer honestly please, for example 800 pages big, how many pages a day? I just wanna see if i m reading too slow... :)

Next question, i have a simple function from my latest book here and the
authors of "Wrox Beginning Asp.net with c#" were not to eager to explain the meanings of the theory of code they used in their example so i guess i
should figure it out on my own, maybe with the help from a good soul,
So there are some confusions in the function which i d appreciate being
clarified,

The code first...

<code>
private DateTime GetSafeDate(str ing proposedDate)
{
// Returns a non-null DateTime even if proposed date can't be parsed
DateTime safeDate;
try {
safeDate = DateTime.Parse( proposedDate,
DateTimeFormatI nfo.InvariantIn fo);
} catch (Exception e) {
Response.Write( "<!-- Failed to parse date: " + e.Message + " -->");
safeDate = DateTime.MinVal ue;
}
return safeDate;
}
</code>

What i m confused about is the "DateTime.Parse " which seems like a property of an object or something, i know DateTime is a type of variable but i m not sure what this means here,

Also, the "DateTimeFormat Info.InvariantI nfo" is not too clear to me either, do you have any idea?

Thats it,
Thanx!

--
Its easier to stay out then get out.

Nov 15 '05 #8
K_Lee wrote:
Don't know if this would help u or not. Here's the
link to source code implements the "InvariantI nfo"

Browse around it and other c# test code for the "InvariantI nfo"
might help you understand it better.

http://www.slink-software.com/W/SL_T..._InvariantInfo
/FILE_clr/src/bcl/system/globalization/datetimeformati nfo.cs/L_300/LN_264#L_
261

Thanx alot.
Nov 15 '05 #9
General Protection Fault wrote:
DateTime.Parse is a *static* method, meaning to call it you don't use
an instance of DateTime, but the DateTime class itself.
DateTime.Parse takes a String parameter and returns a DateTime (or
throws an exception).

The InvariantInfo bit has to do with the culture. You want to use the
Invariant culture.


Thank you General Protection Fault,
thank you all for assistance.
Nov 15 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
2551
by: Brian Ward | last post by:
First: sorry as a relative newbie for previously not including code. My question: Reading C++ books I almost always find programs such as the one below give the following type of code for reading a file : //********* BUM CODE ************************************* infile.open ("test.dat" , ios::in); while (!infile.eof()) {
6
1781
by: The_Kingpin | last post by:
Hi again guys, I've decided to cut my project in section and I found it way easier like this. I'm having a little problem reading struct in a file though. I think after this I'll be able to handle it on my own. Right now the file is opened correctly and I'm able to read each line and print them in a new file. My problem is to insert each struct (which are made of 6 consecutive lines) as an item in my array.
7
6065
by: John Dann | last post by:
I'm trying to read some binary data from a file created by another program. I know the binary file format but can't change or control the format. The binary data is organised such that it should populate a series of structures of specified variable composition. I have the structures created OK, but actually reading the files is giving me an error. Can I ask a simple question to start with: I'm trying to read the file using the...
7
2959
by: fakeprogress | last post by:
For a homework assignment in my Data Structures/C++ class, I have to create the interface and implementation for a class called Book, create objects within the class, and process transactions that manipulate (and report on) members of the class. Interface consists of: - 5 private variables char author; char title; char code;
3
1778
by: darren via AccessMonster.com | last post by:
Hi I'm based in the UK and I've drifted into Access from building a simple db for myself, to then being asked to build a simple db for someone else, to now spending time building increasingly more sophisticated (for me)databases. So far my learning curve has been based upon a handleful of books and this forum (which I think is fantastic and the level of help and knowledge sharing has astounded me). Aside from the very basic dummies...
10
1711
by: vfunc | last post by:
OK, after reading some C++ books and writing some programs that cover the core, where do I go from there, to say be able to read some open source code ? How do you unravel other peoples code when you are not familiar with the calls, style etc ? Are there any tools for analysing / displaying a program structure ? Are there any forums that discuss such topics, because I guess this is not really the right group.
1
1616
by: Dave | last post by:
Hello, I'm new to SQL Server, have alot of experience with DB2 and Oracle, and have been tasked with supporting SQL Server. Could anyone suggest a good administrator book? Thanks!! Dave Schaeffer
7
11795
by: ianenis.tiryaki | last post by:
well i got this assignment which i dont even have a clue what i am supposed to do. it is about reading me data from the file and load them into a parallel array here is the question: Step (1) Your first task is to write a program which reads this file into two parallel arrays in memory. One array contains the titles, and the other array contains the authors. The arrays are 'parallel' in the sense that the n-th element of the authors...
11
5146
by: downwitch | last post by:
Hi, I'm using a 3rd-party app's back end which stores SQL statements in a table, so I have no choice but to use dynamic SQL to call them (unless someone else knows a workaround...) Problem is, I can't get the statement to run properly, and I can't see why. If I execute even a hard-coded variation like DECLARE @sql nvarchar(MAX)
8
1824
by: boki_pfc | last post by:
Hi Everybody, I am looking for an advice on following: I have that "pleasure" of reading C++ codes that have been written by person(s) that have not attended the same C++ classes that I did or have not read the same C++ books that I have read. This kind of people has written some parts of the code that use notations that I am not familiar with (and that probably also includes also 50 % of other C ++ programmers). While everybody who...
0
9705
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9576
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10323
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10310
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7613
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5515
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5647
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3809
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2983
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.