SilverLight

Silverlight and the layout management. (Grid, Canvas, StackPanel or ?)

If you have done any Silverlight development, then you are familiar with the Canvas, the Grid and the StackPanel.

All 3 containers are unique in their own way. But they all have some limitations/drawbacks. Let's see:

1: The Canvas:

<Canvas Background="Blue">

<TextBlock Height="50" Width="50" Canvas.Left="15" Canvas.Top="15" />
</Canvas>

I don't want to pixelate my items.

2: The StackPanel:

<StackPanel>
<TextBlock Height="50" Width="50" />

<TextBlock Height="50" Width="50" />

</StackPanel>

Just not rich enough to do any complex layouts.

3: The Grid:
<Grid Background="Silver">

<Grid.ColumnDefinitions>
<ColumnDefinition Width="*2" />
<ColumnDefinition Width="*1" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="50" />
<RowDefinition Height="100" />
</Grid.RowDefinitions>

<TextBlock Height="50" Width="50" Grid.Row="1" Grid.Column="1"/>

</Grid>


I don't want to pixelate my items.

Yes, I can define a very complex layout using the Grid. But I am still required to place my items inside "a" cell by specifying

the Grid.Row and Grid.Column attributes on each individual item. I also need to decide, how may rows and columns my page has.

This just does not feel natural.

To address this, Developer Express is working on a special LayoutControl container that will eliminate these hassles. All you have to do is specify where you want

your items placed. Left, Right, Top or Bottom.


<DockedLayoutControl x:Name="layoutItems" DockedLayoutControl.Dock="Client">
<TextBlock Text="My Top Text" DockedLayoutControl.Dock="Left"/>
<TextBlock Text="My Bottom Text" DockedLayoutControl.Dock="Bottom"/>
</DockedLayoutControl>

Here is a screen shot of a layout done using a DockedLayoutControl.

Just not rich enough to do any complex layouts.


the Grid.Row and Grid.Column attributes on each individual item. I also need to decide, how may rows and columns my page has.

This just does not feel natural.

To address this, Developer Express is working on a special LayoutControl container that will eliminate these hassles. All you have to do is specify where you want

your items placed. Left, Right, Top or Bottom.


Here is a screen shot of a layout done using a DockedLayoutControl.




FAQS

ASP.NET:

1.The page cannot be found" Error With ASP.NET On Windows Server 2003?


When you have installed ASP.NET on Windows Server 2003, you may receive the following 404 - Page Not Found error:

The normal html pages can be accessed normally but the aspx pages will give this error. Visual studio.net 2005 has inbuilt server hence you would normally not face this issue since you would not really be using IIS. But in case you deploy the application in IIS and try accessing the application using the localhost or 127.0.0.1, you are bound to find this error.

This error is caused as the IIS 6 disallows the ASP.NET 2.0 Web Service Extension. To fix this, follow these steps:

Open up the Internet Information Services (IIS) Manager (which you find under Administrative Tools)

Expand your server

Select Web Service Extensions

In the right hand pane, click ASPNET v2.0.50727 (or a later version number) and then click the Allow button.


Follow the Below Images:

These images give you the clarity.






















WebServices:

Why WebService Access Denied?

The .NET Framework 1.1 defines a new protocol that is named HttpPostLocalhost. By default, this new protocol is enabled. This protocol permits invoking Web services that use HTTP POST requests from applications on the same computer. This is true provided the POST URL uses http://localhost, not http://hostname. This permits Web service developers to use the HTML-based test form to invoke the Web service from the same computer where the Web service resides.

When you try to access the Web service from a remote computer you do not see the Invoke button. And, you receive the following error message:

The test form is only available for requests from the local machine

Solution:
-->> Web.config file level <<--

HTTP GET and HTTP POST may be enabled by editing the Web.config file for the vroot where the Web service resides. The following configuration enables both HTTP GET and HTTP POST:








-->> Machine.config File Level <<--


Alternatively, you can enable these protocols for all Web services on the computer by editing the section in Machine.config. The following example enables HTTP GET, HTTP POST, and also SOAP and HTTP POST from localhost:








How to Use transactions with LINQ-to-SQL?

To use TransactionScope first we have to add a reference to System.Transactions like below.




















After adding the transaction we need to drag and drop the tables into Linq-To-SQL Classes it will create entities for that. Below is the code for transaction scope to use mange transaction with Linq Context.
After adding the transaction we need to drag and drop the tables into Linq-To-SQL Classes it will create entities for that. Below is the code for transaction scope to use mange transaction with Linq Context.

using (EmployeeRegistrationDataContext db = new EmployeeRegistrationDataContext())
{
using (TransactionScope Tran = new TransactionScope(TransactionScopeOption.Required))
{
dbtblemployeeDetails.InsertOnSubmit(objemployeeDetails);
dbtblempAddress.InsertOnSumbit(ObjempAddress);
db.SubmitChanges();

Tran.Complete();//indicates that all operations within the scope are completed successfully.
}
}
It will commit transaction only if using blocks will run successfully.

About Me

Hi, i am Brahmam and I write C#.Net,ASP.Net and C# Console Applications Samples and Problem Solving. This is useful who have interest in Microsoft .Net and MSSQL. I am very eager to Learn New things in Dot Net. I am always ready to discus things in dot net.

My Hobbies:
A person needs some activity to keep themselves involved - and something interesting or fun makes it more pleasant too! Crafts and great hobbies promise this. With today’s stressful lifestyles, it’s important to have time, that you take, to do something just for the fun of it. Not only can a hobby be fun, some can even relieve stress.

* Reading Books
* Listening Music
* Dancing
* Making Good Friends



Contact Me:

Brahmaiah Koduri
Software Engineer/ Cigniti, Hyd,India,
brahmam@cigniti.com,brahmam.04@gmail.com,
Cigniti Software Services(P) Ltd,
Module 1 Q 3-A3,
1st floor, Cyber Towers,
HITEC CITY, Madhapur,
Hyderabad-500 081.

web

business woman and her team isolated on white photo


Gallery













I Love C# Language............


What is C#?

C# is a new language created by Microsoft.
This new language was created by a team of people at Microsoft led by Anders Hejlsberg.C# is a powerful and flexible programming language. Like all programming languages, it can be used to create a variety of applications. Your potential with C# is limited only by your imagination. The language does not place constraints on what you can do. C# has already been used for projects as diverse as dynamic Web sites, development tools, and even compilers.C# was created as an object-oriented programming (OOP) language. Other programming languages include object-oriented features, but very few are fully object-oriented.

Why C#?

Many people believed that there was no need for a new programming language. Java, C++, Perl, Microsoft Visual Basic, and other existing languages were believed to offer all the functionality needed.
C# is a language derived from C and C++, but it was created from the ground up. Microsoft started with what worked in C and C++ and included new features that would make these languages easier to use. Many of these features are very similar to what can be found in Java. Ultimately, Microsoft had a number of objectives when building the language.

C# Is Modern

What makes a modern language? Features such as exception handling, garbage collection, extensible data types, and code security are features that are expected in a modern language. C# contains all of these.

C# Is Object-Oriented

The keys to an object-oriented language are encapsulation, inheritance, and polymorphism. C# supports all of these. Encapsulation is the placing of functionality into a single package. Inheritance is a structured way of extending existing code and functionality into new programs and packages. Polymorphism is the capability of adapting to what needs to be done. Understand, these are very simplistic definitions. The implementation of these is a bit more complicated.

Some  C# Keywords:

abstract as base bool break
byte case catch char checked
class const continue decimal default
delegate do double else enum
event explicit extern false finally
fixed float for foreach
goto if implicit in int
interface internal is lock long
namespace new null object operator
out override params private protected
public readonly ref return sbyte
sealed short sizeof stackalloc
static string struct switch this
throw true try typeof uint
ulong unchecked unsafe ushort using
virtual void while

Some Topics in C#

Loops in C#.Net
Garbage Collection

..........................................
..........................................
Valuable E-Books Down Load Now

Caching in asp.net 3.5
Types Of Chaching:
ASP.NET has several kinds of caching that can be used by Web applications:

Output Caching: Output caching is useful when the contents of an entire page can be cached. While a page is cached by the output cache, subsequent requests for that page are served from the output page without executing the code that created it.

Fragment Caching: Sometimes it is not practical to cache an entire page - perhaps portions of the page must be created or customized for each request. In this case, it is often worthwhile to identify objects or data that are expensive to construct and are eligible for caching. Once these items are identified, they can be created once and then cached for some period of time. Additionally, fragment caching can be used to cache regions of a page's output.

Data Caching: Data caching is storing data in memory for quick access. Typically information that is costly to obtain (in terms of performance) is stored in the cache. One of the more common items stored in a cache is commonly displayed database values; by caching such information, rather than relying on repeated database calls, the demand on the Web server and database server's system resources are decreased and the Web application's scalability increased. The cache items can be given an expiration policy that causes them to be removed from the cache when they have expired. Code that accesses the cache item simply checks for the absence of the item and recreates it, if necessary.


Learn More From People

  • God helps those who help themselves

God only helps those people who work hard and make an honest effort.


  • "HELP EVER HURT NEVER"&"IMPOSSIBLE AS POSSIBLE"

  • Empty vessels make the most noise

Those people who have a little knowledge usually talk the most and make the greatest fuss.

  • A rolling stone gathers no moss

A person who never settles in one place or who often changes his job will not succeed in life ; one who is always changing his mind will never get anything done.

  • Actions speak louder than words

Children usually learn more from the examples set by their elders than from what they are told ; a person's character is judged by the thing she does and not by what he says; actions give evidence or proof of.