 |
|
 |
I am implementing a scenario where I'm loading 3 or 4 views inside the tabcontrol. My tabcontrol region is defined using the TabControlRegionAdapter. I am able to load these views into this region without any problems. However, I am unable to control the layout of the tab control once these views get loaded. Thus my views scroll out of my page (so to speak) and are not visible on the screen. I understand that the tab control uses ItemsControl to display its content. I tried defining the layout using ItemsTemplate but even that seemed to have no effect.
How can I control the layout of the content inside a tab so that all my views can be completely visible on the screen? Also, is there a solution such that as I resize my browser, this content too gets automatically resized? In my present scenario, as I resize my window, more and more of my view content gets clipped.
Thanks for any help or guidance in advance.
|
|
|
|
 |
 | How to download file from a physical location in Silverlight? urgent......... |  | salon | 18hrs 19mins ago |
|
 |
Hi all,
I want to download xml or any other file from physical location like C:\Documents and Settings\All Users\Documents\Test.xml and open a Save Dialog box to allow user to save it in desired location
Is it possible in Silverlight 2.0? Can we do it in xaml.cs file? If yes then plz share the code with me..... Its very urgent.........
Thanks in advance,
|
|
|
|
 |
|
 |
salon wrote: Is it possible in Silverlight 2.0?
Opening a file you can do using the OpenFileDialog class, so the user effectively needs to give permission first.
Saving a file, no, not in Silverlight 2.
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
|
 |
Another option (not elegant but works) could be to perform a ping pong using services:
- Send your file to the server again using a WCF service, store it in session. - Call a javascript method from SL that will make a request to a custom HTTP hanlder. - That custom HTTP hanlder would return the file that was in session as an attachment (first time the nasty bar from IE would appear... you are going to download something...).
In my application I needed to export a DB Diagram to JPEG and to perform an export as well to an HTML report, I used that approach (ping pong ), I could set an attribute (attachment) and IE would ask me to save the JPEG as a file.
If you want to take a look at how it behaves:
http://www.dbschemaeditor.com
HTH Braulio
/// ------------------------- Braulio Díez DBSchemaEditor.com Free Silverlight based DB Schema Modeling Tool /// -------------------------
|
|
|
|
 |
 | same Xaml to port a WPF app to Silverlight? |  | devvvy | 22hrs 18mins ago |
|
 |
so... can we simply write one set of Xaml to represent UI for a WPF app.
<StackPanel x:Name="sp1" Orientation="Vertical"> <StackPanel.Resources> <local:LocalClass x:Key="localClass1" AnIntProp="5"/> </StackPanel.Resources> ... more stuff.. </StackPanel>
Then just port it (i.e. use same Xaml) to Silverlight?
Can we do that?
I'm a silverlight newbie.
thanks
dev
|
|
|
|
 |
|
 |
Try it. Unless you use WPF-specific features, the XAML will work in both.
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
|
 |
dear Friend.
my silverlight project run successfully from solution.but i make setup of the project and deploy it.Then it's not working and Web Service is not found .after that i have change my Service references.clintconfig Endpoint setup name in address(FileConverstionBeta11) then it run successfully and i also add the clientaccesspolicy.xml with the project
After change EndPoint(its not working from local host):- (endpoint address="http://localhost/FileConverstionBeta11/WSFileConversion.asmx" binding="basicHttpBinding" bindingConfiguration="WSFileConversionSoap" contract="ServiceReference1.WSFileConversionSoap" name="WSFileConversionSoap" /)
Before change EndPoint(its not working from local host) :-
(endpoint address="http://localhost/FileConverstion/WSFileConversion.asmx" binding="basicHttpBinding" bindingConfiguration="WSFileConversionSoap" contract="ServiceReference1.WSFileConversionSoap" name="WSFileConversionSoap" /) and my application name is :-FileConverstion
then how to run application successfully without change of Service references.clintconfig Endpoint.Pleas help me to resolved this problem
Piyush Vardhan Singh p_vardhan14@rediffmail.com Eventure Technology http://holyschoolofvaranasi.blogspot.com http://holytravelsofvaranasi.blogspot.com
|
|
|
|
 |
|
 |
Piyush Vardhan Singh wrote: how to run application successfully without change
You can't. You have to change the endpoint address to match the host.
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
 | How bind 3 level master-detail scenario into datagrid? |  | enochenoch2k | 15:51 16 Apr '09 |
|
 |
first,see post http://bea.stollnitz.com/blog/?p=21 please.
in a factual application , this is very useful!
for describe clear ,add a new table into the database the new table have tow field: Run_ID , Value1(type int). The Run_ID is the key of the table. I want bind the new table to a datagrid in a silverlight application.
the datagrid have four columns: 1: Mountain_Name, represent as a combobox 2: Lift_Name, represent as a combobox 3: Run_Name, represent as a combobox 4: Value1, represent as a textbox
all columns is modify able.
the column 1 to 3 is Synchronized like as in the post http://bea.stollnitz.com/blog/?p=21
how I do this ?
and how set the column 1 to 3 when load the table into datagrid?
thaks very much!
|
|
|
|
 |
|
 |
I used image-gallary download form codeplex.com on my project. It was very very slow to open a picture. I did same throught flash, it is much faster.
Can any body tell me how to speed up silverlight application to better than flash as it can get data of my asp.net and process it, flash is harder to work for such manner. I want to use silverlight because of easily support with c# and asp.net
|
|
|
|
 |
|
 |
There's no reason Silverlight should be significantly slower than Flash opening a picture.
Without any details on what you're doing, it's difficult to help 
Mark
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
|
 |
I have 10 pictures. I created thumbnails of all, now I have 20 pictures.
I used Data.xml file for path containing full-size and thumbnail pictures. Configuration.xml file for settings [These files I got automatically from codeplex.com Image Gallery Project].
I created Gallery, you can view at: http://www.trannumdigitalstudio.com/[^]
Also you cn view flash Gallery at: http://www.flashgallery.org/demo.html[^]. Here image size is bigger still faster
All images in Silverlight Gallery are at 72 dpi, 500*500 px resolution
|
|
|
|
 |
|
 |
I'm not sure what you are seeing.
The Silverlight gallery loads and shows images faster than the flash one for me.
Once the images are cached (have been viewed) they load instantly.
Note I'm using Firefox 3.
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
 | WebMonthView Control in CLR |  | GomathiR | 2:49 15 Apr '09 |
|
 |
Hi,
I am using clr 3.5 for asp 2008. My aim is to enter daily task and to save it in that day's month view. WebMonthView control seems not to have any click events. The data i am adding for a particular date should be visible in that day in MonthView Control. Any Idea ? Pls help me urgent!!!
Gomathi R
|
|
|
|
 |
|
 |
Wrong message board!
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
|
 |
Then, this question comes under which board? It is silver light control only na?
Gomathi R
|
|
|
|
 |
|
 |
ASP.NET I would guess. I see no WebMonthView control in Silverlight
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
|
 |
Hi everybody.
How can I modify a XML file into Isolated Storage with silverlight 2 ? (without using LINQ)
For example : assume we have a XML file like this :
<CodeColorizer> <Settings> <IsVB>False</IsVB> <IsStriped>False</IsStriped> </Settings> </CodeColorizer>
Now , I wanna change the content of IsVB to True . How can I do it ?
By the way : I've already searched in Google, unfortunately I couldn't find anything special 
Thank in advance.
|
|
|
|
 |
 | Reading a XML file from IsolatedStorage ? [modified] |  | Mohammad Dayyan | 19:00 13 Apr '09 |
|
 |
Hi. I'm reading a XML file that has been stored in IsolatedStorage. But this Exception was occurring Root element is missing. I'm dead sure that there isn't any troubles in the XML file, So I don't the know the result of the Exception 
Could you guide me ? Thank you.
This is my snippet code :
using (IsolatedStorageFile isoStore = IsolatedStorageFile.GetUserStoreForApplication()) { . . . string SettingFilePath = "CodeColorizer\\setting.xml"; using (IsolatedStorageFileStream isoStream = new IsolatedStorageFileStream(SettingFilePath, FileMode.Create, isoStore)) { isoStream.Position = 0; XmlReader xmlReader; xmlReader = XmlReader.Create(isoStream); //Moves the reader to the root element. xmlReader.MoveToContent();//Exception was occurring here string value; while (xmlReader.Read()) { switch (xmlReader.NodeType) { case XmlNodeType.Element: { if (xmlReader.Name == "IsVB") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); if (value == "True") { this.IsVB.IsChecked = true; this.IsCsharp.IsChecked = false; } else if (value == "False") { this.IsVB.IsChecked = false; this.IsCsharp.IsChecked = true; } } else if (xmlReader.Name == "IsCsharp") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); if (value == "True") { this.IsVB.IsChecked = false; this.IsCsharp.IsChecked = true; } else if (value == "False") { this.IsVB.IsChecked = true; this.IsCsharp.IsChecked = false; } } else if (xmlReader.Name == "IsStriped") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); if (value == "True") { this.IsStriped.IsChecked = true; } else if (value == "False") { this.IsStriped.IsChecked = false; } } else if (xmlReader.Name == "HasLineNumber") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); if (value == "True") { this.HasLineNumber.IsChecked = true; } else if (value == "False") { this.HasLineNumber.IsChecked = false; } } else if (xmlReader.Name == "AddDefaultStylesWithinPreTags") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); if (value == "True") { this.addDefaultStylesWithinPreTags.IsChecked = true; } else if (value == "False") { this.addDefaultStylesWithinPreTags.IsChecked = false; } } else if (xmlReader.Name == "CssClassName") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); this.cssClassName.Text = value; } else if (xmlReader.Name == "AddPreTag") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); if (value == "True") { this.AddPreTag.IsChecked = true; } else if (value == "False") { this.AddPreTag.IsChecked = false; } } else if (xmlReader.Name == "AddBGColor") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); if (value == "True") { this.AddBGColor.IsChecked = true; } else if (value == "False") { this.AddBGColor.IsChecked = false; } } else if (xmlReader.Name == "TextBoxColor") { value = (string)xmlReader.ReadContentAs(Type.GetType("String"), null); this.TextBoxColor.Text = value; } break; } } } }
}
modified on Tuesday, April 14, 2009 12:08 AM
|
|
|
|
 |
|
 |
Is FileMode.Create really the mode you want to open the file in?
Mark
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
|
 |
Thanks Mark. I've altered it to FileMode.Open , but the Exception has occurred again :(
|
|
|
|
 |
|
 |
I've done it :
using (IsolatedStorageFile isoStore = IsolatedStorageFile.GetUserStoreForApplication()) { . . . string SettingFilePath = "CodeColorizer\\setting.xml"; using (IsolatedStorageFileStream isoStream = new IsolatedStorageFileStream(SettingFilePath, FileMode.Open, isoStore)) { isoStream.Position = 0; XmlReader xmlReader; xmlReader = XmlReader.Create(isoStream); Debug.WriteLine("\r\n" + isoStream); //Moves the reader to the root element. xmlReader.MoveToContent(); string value; while (xmlReader.Read()) { switch (xmlReader.NodeType) { case XmlNodeType.Element: { if (xmlReader.Name == "IsVB") { value = xmlReader.ReadElementContentAsString(); if (value == "True") { this.IsVB.IsChecked = true; this.IsCsharp.IsChecked = false; } else if (value == "False") { this.IsVB.IsChecked = false; this.IsCsharp.IsChecked = true; } } else if (xmlReader.Name == "IsCsharp") { value = xmlReader.ReadElementContentAsString(); if (value == "True") { this.IsVB.IsChecked = false; this.IsCsharp.IsChecked = true; } else if (value == "False") { this.IsVB.IsChecked = true; this.IsCsharp.IsChecked = false; } } else if (xmlReader.Name == "IsStriped") { value = xmlReader.ReadElementContentAsString(); if (value == "True") { this.IsStriped.IsChecked = true; } else if (value == "False") { this.IsStriped.IsChecked = false; } } else if (xmlReader.Name == "HasLineNumber") { value = xmlReader.ReadElementContentAsString(); if (value == "True") { this.HasLineNumber.IsChecked = true; } else if (value == "False") { this.HasLineNumber.IsChecked = false; } } else if (xmlReader.Name == "AddDefaultStylesWithinPreTags") { value = xmlReader.ReadElementContentAsString(); if (value == "True") { this.addDefaultStylesWithinPreTags.IsChecked = true; } else if (value == "False") { this.addDefaultStylesWithinPreTags.IsChecked = false; } } else if (xmlReader.Name == "CssClassName") { value = xmlReader.ReadElementContentAsString(); this.cssClassName.Text = value; } else if (xmlReader.Name == "AddPreTag") { value = xmlReader.ReadElementContentAsString(); if (value == "True") { this.AddPreTag.IsChecked = true; } else if (value == "False") { this.AddPreTag.IsChecked = false; } } else if (xmlReader.Name == "AddBGColor") { value = xmlReader.ReadElementContentAsString(); if (value == "True") { this.AddBGColor.IsChecked = true; } else if (value == "False") { this.AddBGColor.IsChecked = false; } } else if (xmlReader.Name == "TextBoxColor") { value = xmlReader.ReadElementContentAsString(); this.TextBoxColor.Text = value; } break; } } } } }
|
|
|
|
 |
|
 |
Is it working now?
Mark
Mark Salsbery Microsoft MVP - Visual C++
|
|
|
|
 |
|
|
 |
 | that very confusing in virtual directory and MIME Type................ |  | Piyush Vardhan Singh | 22:30 7 Apr '09 |
|
 |
Dear friends any body help me to host silverlight project from local host(Step by Step Processors). I have got lots of link but that are not help full . that very confusing in virtual directory and MIME Type. that link are not sufficient to understand of deployment of Silver Light Project please help me
Piyush Vardhan Singh p_vardhan14@rediffmail.com http://holyschoolofvaranasi.blogspot.com http://holytravelsofvaranasi.blogspot.com
|
|
|
|
 |