2
Answers

Silverlight 4: Out of the browser

David Smith

David Smith

13y
1.3k
1
At the moment I using ASP.net to Host the website. Silverlight piece is embedding within the host. With in the body of my asp.net host. I have a background.


Is it possible to right logic to say

if ( Out of the browser application )
{
    Set background image to the out brower application.

}


My goal is to have the out brower look exactly like the in browser application. That way I wont have to worry about disabling the minimize and maximize button. If this is possible I can ultimately position and margin the out of browser application to look just like the in browser application. Can someone assist me?
Answers (2)
0
Vulpes

Vulpes

NA 98.3k 1.5m 10y
Accepted
1
Niranjan Poddar

Niranjan Poddar

NA 308 39.7k 10y
try this........

 public static string ConvertNumbertoWords ( int number )
    {
        if ( number == 0 )
            return "Zero";
        if ( number < 0 )
            return "minus" + ConvertNumbertoWords ( Math.Abs ( number ) );

        string words = "";
        if ( ( number / 1000000 ) > 0 )
        {
            words += ConvertNumbertoWords ( number / 1000000 ) + " MILLION ";
            number %= 1000000;
        }
        if ( ( number / 1000 ) > 0 )
        {
            words += ConvertNumbertoWords ( number / 1000 ) + " THOUSAND ";
            number %= 1000;
        }
        if ( ( number / 100 ) > 0 )
        {
            words += ConvertNumbertoWords ( number / 100 ) + " HUNDRED ";
            number %= 100;
        }
        if ( number > 0 )
        {
            if ( words != "" )
                words += "AND ";
            var unitsMap = new[] { "ZERO", "ONE", "TWO", "THREE", "FOUR", "FIVE", "SIX", "SEVEN", "EIGHT", "NINE", "TEN", "ELEVEN", "TWELVE", "THIRTEEN",
                "FOURTEEN", "FIFTEEN", "SIXTEEN", "SEVENTEEN", "EIGHTEEN", "NINETEEN" };
            var tensMap = new[] { "ZERO", "TEN", "TWENTY", "THIRTY", "FORTY", "FIFTY", "SIXTY", "SEVENTY", "EIGHTY", "NINETY" };

            if ( number < 20 )
                words += unitsMap[number];
            else
            {
                words += tensMap[number / 10];
                if ( ( number % 10 ) > 0 )
                    words += " " + unitsMap[number % 10];
            }
        }
        return words;

    }
    protected void btnConvert_Click1 ( object sender, EventArgs e )
    {
        string word = ConvertNumbertoWords ( Convert.ToInt32 ( txtFig.Text ) );
        lblWord.Text = word;
    }