To share the value across, global variables are required. Similarly, if a value has to be passed from one XAML to another global variable concept can be used.
Steps:
1) Create property in APP.XAML
Private _gloVar As String
Property gloVar() As String
Get
Return _gloVar
End Get
Set(ByVal value As String)
_gloVar = value
End Set
End Property
2) From one XAML's code behind, create object for APP and then get the current instance.
3) Using that object, property created in step 1 is accessible. Using this set the value.
'Setting value from one xaml
'get the current application object
Dim objApp As App = App.Current
'set the value to the app var
objApp.gloVar = "Value you want to store"
4) From where (XAML) you want value to be used, get current instance of the APP like described in step 2 and access the property value from that object.
'Reading the value from another xaml
'get the current Application object
Dim objApp As App = App.Current
'read the application variable
TextBlock.Text = "Content loaded from global variable: " + objApp.gloVar
Monday, March 8, 2010
Thursday, July 9, 2009
How to find SQL Server Property using query
Here’s a quick trick the will allow you to easily retrieve information about the Microsoft SQL Server version that you are currently running. This quick how-to was written using SQL Server 2005, but it’s applicable to SQL Server 2000 as well.
Login to the Microsoft SQL Server Management Studio (Query Analyzer in SQL Server 2000)
Click New Query
Type and Execute the following SQL command:
SELECT SERVERPROPERTY (’productlevel’) as ‘Product Level’, SERVERPROPERTY(’productversion’) as ‘Product Version’, SERVERPROPERTY (’edition’) as ‘SQL Server Edition’
Login to the Microsoft SQL Server Management Studio (Query Analyzer in SQL Server 2000)
Click New Query
Type and Execute the following SQL command:
SELECT SERVERPROPERTY (’productlevel’) as ‘Product Level’, SERVERPROPERTY(’productversion’) as ‘Product Version’, SERVERPROPERTY (’edition’) as ‘SQL Server Edition’
Wednesday, July 8, 2009
Deploy .NET Assembly to GAC
3 steps to deploy an assembly in the GAC:
- Create or locate Key File for signing: sn -k "Path to SNK File"
- Assign the Key to your Project (AssemblyInfo File):
- Deploy the dll: gacutil -I "Path to DLL"
Saturday, May 3, 2008
Million in Maths ... ;)
Number of zeros | U.S. & scientific community | Other countries |
3 | thousand | thousand |
6 | million | million |
9 | billion | 1000 million (1 milliard) |
12 | trillion | billion |
15 | quadrillion | 1000 billion |
18 | quintillion | trillion |
21 | sextillion | 1000 trillion |
24 | septillion | quadrillion |
27 | octillion | 1000 quadrillion |
30 | nonillion | quintillion |
33 | decillion | 1000 quintillion |
36 | undecillion | sextillion |
39 | duodecillion | 1000 sextillion |
42 | tredecillion | septillion |
45 | quattuordecillion | 1000 septillion |
48 | quindecillion | octillion |
51 | sexdecillion | 1000 octillion |
54 | septendecillion | nonillion |
57 | octodecillion | 1000 nonillion |
60 | novemdecillion | decillion |
63 | vigintillion | 1000 decillion |
66 - 120 | undecillion - vigintillion | |
303 | centillion | |
600 | centillion |
Sunday, April 27, 2008
Vitamins for...
Vitamins are only required in very small quantities. There is no chemical similarity between these chemicals; the similarity between them is entirely biological.
Vitamin A: good for your eyes.
Vitamin B: about 12 different chemicals.
Vitamin C: needed for your body to repair itself.
Vitamin D: can be made in your skin, needed for absorption of Calcium.
Vitamin E: the nice one - reproduction?
Vitamin A: good for your eyes.
Vitamin B: about 12 different chemicals.
Vitamin C: needed for your body to repair itself.
Vitamin D: can be made in your skin, needed for absorption of Calcium.
Vitamin E: the nice one - reproduction?
Tuesday, April 22, 2008
Identify the service pack version
Simple Steps to know service pack version:
- Click Start, and then click Run.
- Type winver and press Enter to display a window with system information.
Friday, March 21, 2008
Subscribe to:
Posts (Atom)