tutorials from www.asp.net not fully explained (i want know codes,how to apply example codes)
thanks
Suthesan
Razoblade@dotnet.itags.org.LinuxMail.OrgYou may go to MSDN Library and type in key word you are looking for.
tutorials from www.asp.net not fully explained (i want know codes,how to apply example codes)
thanks
Suthesan
Razoblade@dotnet.itags.org.LinuxMail.OrgYou may go to MSDN Library and type in key word you are looking for.
Hi guys, first of all please excuse me if I post this topic in the wrong section. I have two questions. First of all I am new in web development and I really want to learn asp.net, one thing I am not sure of is that, what is the the languages that I need to learn before learning asp.net? currentlly I am all most done with HTML and CSS, is there anything I need to learn also? XML maybe?
Another thing is that, I know that I can use C sharp or VB with ASP.net. should I learn C sharp or VB before ASP.net or after?
And thank you in advance.
Please take a look at this pagehttp://asp.net/getstarted/default.aspx?tabid=61
and sure you need to learn C# or VB before
learning ASP.NET and VB.NET ( C#) goes simulantenously.....
because whenever you create web-forms , you need to write inline code or code behind to execute form for various things like validation of data,insertion,deletion etc.
HTML & CSS is used only in User Interface layer, there are other layes involved like Business layer,Database layer...
for you best is to start from here :
http://quickstarts.asp.net/QuickStartv20/aspnet/doc/
start with all kinds of server controls....
all the best !
Hi,
In my opinion, both of the VB and C# are good, you can choose the one you like better. They are supported by the CTS of .NET Framework. They have the same FCL in the .NET Framework. The difference between them is just syntax. When you learn ASP.NET, you should be familiar with C# or VB. They are used to implement the business logic, and HTML and CSS are used to manipulate the presention of the page.
Here is the getting started introduction article of ASP.NEThttp://www.sitepoint.com/article/getting-started-asp-net/4
Hope it helps,
Jessica
int tempA;
...
ViewState["TEMPA"] = tempA;
...
tempA = (int)ViewState["TEMPA"];
--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
"Vivian" <wkichu@.hotmail.comwrote in message
news:e69UdhWpGHA.4988@.TK2MSFTNGP04.phx.gbl...
Quote:
Originally Posted by
>I have an aspx page with C# with several "post" button. Each button will do
>sth, and return some data to the same page. The problem is I have a public
>variable, say tmpA in C# in which data will set while the first button is
>clicked. I need to get the value of tmpA when pressing other button, the
>problem is how can I save the value of tmpA?
Do I need to add a hidden field on the form to do that?
Or is there any better approach? Thanks
>
"Eliyahu Goldin" <removemeegoldin@.monarchmed.comglsD:uVtA7 RYpGHA.4268@.TK2MSFTNGP04.phx.gbl...
Quote:
Originally Posted by
Are you asking how to preserve variables between postbacks? If this is
what you mean, put them in the VewState:
>
int tempA;
...
ViewState["TEMPA"] = tempA;
...
tempA = (int)ViewState["TEMPA"];
--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
>
"Vivian" <wkichu@.hotmail.comwrote in message
news:e69UdhWpGHA.4988@.TK2MSFTNGP04.phx.gbl...
Quote:
Originally Posted by
>>I have an aspx page with C# with several "post" button. Each button will
>>do sth, and return some data to the same page. The problem is I have a
>>public variable, say tmpA in C# in which data will set while the first
>>button is clicked. I need to get the value of tmpA when pressing other
>>button, the problem is how can I save the value of tmpA?
>Do I need to add a hidden field on the form to do that?
>Or is there any better approach? Thanks
>>
The case I have here is I need to keep business hours in my sql database. Apparently I only need hh:mm. The way that I did was:
1. create 2 datetime fields in sql table to stroe the from and to.
2. in the maintenance form, create text fields to capture only hh:mm from user.
First of all, is it a right way to do? I mean, is it appropriate to use datetime field to store or I should use a string field to do so? Please note that the data are not used for display only.
I entered the hours thru Server Explorer in vs2003 prior to the maintenance form was created. It did allow me to enter only hh:mm to the cells. But when I examined the data in those fields during debugging, I found actually there is a date prior to the time.
My question is when I use vb code to update those fields, what should I put in the date portion. I don't think I can simply code like "table.FromField=txtFrom.text" and do a sql update.
Can someone advice me what is the proper way to get this done? Thanks a million.You can certianly do it the way you've done it thus far. However, date/time fields in sql have all kinds of additional features on them to calculate the date and time.
If you're simply looking for time in a specific format I would setup a char(5) or a VarChar(5) field and put the string in there. Then use a regular expression to validate it at the user interface.
But, like I previously said, you can certianly do it the way you did without issues.
Hope this help,
But then my issue is how to update the sql table in the future. As I said, I entered the dates thru vs2003 in the first set up. Down the road, if the user needs to change, I think the web form will crash out because trying to populate a datetime field without data in date portion. Would you agree with me?
Are you saying that you auto generated a form off of an sql table?
Sorry I confused you. I mean I created the table first and because there is just only one record in it so I simply entered data thru vs2003.
Now I am creating a form for my user to maintain info in that table. So if the user brings up the form, the text field will show 10:45 in that text fields.
Apparently when the user click save button, I'd have update the table with what is on the form. Then how am I going to update the datetime field with just a time. I have though about to concatenate it with a dummy date but it sounds very stupid and unprofessional.
Use the full date time functionality in SQL -
and format the output (displayed) to what you need...
thats the real way to accomplish the task...
good luck
take care
tony
Thanks Tony. I'm going to do research to see what the function you mentioned really does 'cause I'm at not well-versed in SQL. But I got a feeling that you meant to populate the entire date and time to the table, if this is true then what date I should put it in? Is my case very rare?
I couldn't find any date time functionalities to handle this situation except I found a page in MSDN about using data and time. It said ...
There are no separate time and date data types for storing only times or only dates. If only a time is specified when setting a datetime or smalldatetime value, the date defaults to January 1, 1900. If only a date is specified, the time defaults to 12:00 A.M. (Midnight).
In the mean time, I can only concatenate 1/1/1990 with user's input while updating the database. Does anybody have a better idea? Thanks.