|
Christian,
Seems like you have two independent issues here. For the purpose of troubleshooting, can you separate the two, to allow us to work the WPF height issue. By that I mean, can you place a button in the tab control, set its size in code and then allow the resize code to run. This is one simple way of separating the two.
Christian Graus wrote: which is in the load event for our tab control.
Is this a custom tab control, or the standard tab control?
Christian Graus wrote: Application.Current.MainWindow.MinHeight = ActualHeight + 100;
What UIElement does ActualHeight point to?
Is the tab control is on the MainWindow or another window?
Christian Graus wrote: It's worked fine for ages, but suddenly, there is an intermittent crash.
Was this after a framework upgrade, Windows Update or media player update?
Do you have a machine that has your older configuration that you can run the code on? Say an older Windows XP box?
Have you thought about setting the Window property ResizeSizeToContent="WidthAndHeight" . With the use of Margins, this will give you the additional height you need automatically.
Failing the above, can you send me the project so I can see all the code, XAML and step through it?
modified 27-Feb-21 21:01pm.
|
|
|
|
|
Karl Shifflett wrote: Was this after a framework upgrade, Windows Update or media player update?
No, it was after a code change, and happens on all machines.
Karl Shifflett wrote: Do you have a machine that has your older configuration that you can run the code on? Say an older Windows XP box?
I have the old code base, I intend on doing a diff and working through the changes to see which caused it, although nothing major has changed.
Karl Shifflett wrote: Have you thought about setting the Window property ResizeSizeToContent="WidthAndHeight". With the use of Margins, this will give you the additional height you need automatically.
Thanks - I will look into this.
Karl Shifflett wrote: Failing the above, can you send me the project so I can see all the code, XAML and step through it?
It's a big project, thanks for the offer, I'll take you up on it if I need to.,
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Sorry to come back to an ancient thread, but did you resolve/locate the cause of this issue?
I am currently experiencing the same MDA error problem and I beleive it is the result of COM interop issues.
Do you have any pointers for me?
Error:
DisconnectedContext was detected
Message: Context 0x2736e8' is disconnected. Releasing the interfaces from the current context (context 0x2737a0).This may cause corruption or data loss. To avoid this problem, please ensure that all contexts/apartments stay alive until the application is completely done with the RuntimeCallableWrappers that represent COM components that live inside them.
|
|
|
|
|
hi,
i am very new to silverlight, can you suggest me any site that will give basic information abt silverlight app, how to run them and usage
thaknx in advance
koolprasad2003
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|
|
How about this...[^]
Best regards,
Paul.
Jesus Christ is LOVE! Please tell somebody.
|
|
|
|
|
|
thankx many ...
as you say...
Michael Sync wrote: - Silverlight is web technology so you can run the application on browser.
it is different from asp.Net web aplication 2.0 ????
regards
koolprasad2003
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|
|
koolprasad2003 wrote: it is different from asp.Net web aplication 2.0 ????
There are a lot of differences between ASP.NET and Silverlight.
- Silverlight is like Flash. You will see it as embedded object on the browser. For ASP.NET, it's just normal HTML page.
- ASP.NET is the server-side technology. Silverlight is client-side technology that works on browser.
- You don't need any extra plugin to view the ASP.NET website but you will need Silverlight plugin to view the Silverlight content.
- You will need Microsoft .NET and Windows server to host ASP.NET web site but you don't need anything for Silverlight. You can host the silverlight application on Linux server or any server that you like.
- ASP.NET uses HTML and Silverlight uses XAML.
- You won't get the same view for ASP.NET in different browsers. (If you have some experiences in Ajax-enabled website development, you will know how to fix something for IE6 and other thing for Firefox or other browsers). But with Silverlight, you will get the same view for all browsers.
- and there may be more...
There are only one same thing. Both website can be viewed with browsers.
Hope that you will get some ideas about that.
|
|
|
|
|
Michael Sync wrote: you will need Silverlight plugin to view the Silverlight content.
For Viewing It's fine but what about Interface to develop a Silverlight Powered Application?
Michael Sync wrote: You will see it as embedded object on the browser.
Is it going to be done through a browser?
Michael Sync wrote: But with Silverlight, you will get the same view for all browsers.
Sounds Gooood , That is going to save our lots of efforts and time that we spend for all browser compatible application.
Believe Yourself™ ™
|
|
|
|
|
Hello,
Gandalf - The White wrote: what about Interface to develop a Silverlight Powered Application?
I already answered this question in this post[^].
Gandalf - The White wrote: Is it going to be done through a browser?
For development? no. What I was saying is that when Silverlight object is the embedded object...
Gandalf - The White wrote: That is going to save our lots of efforts and time that we spend for all browser compatible application.
Yes. It's really good. but MS need to take some times to make this happen. For the time being, Silverlight works on IE and Firefox on IE and Saferi on Mac. Moonlight will come for Linux users but it might take some time... I think SL will support Opera in next release beta1... but not like Javascript, there are only two options... SL will work or won't work at all.
|
|
|
|
|
Hey guys,
I've got a client with a 3d desktop application and a 3d ActiveX web browser plugin.
They're asking about Silverlight - instead of an ActiveX control, could their browser plug-in be a Silverlight application? For this to be possible, Silverlight must support their existing 3d engine (a COM object) - is this possible? Can I write a Silverlight application that uses a 3rd party COM object to do 3d rendering?
|
|
|
|
|
Judah Himango wrote: is this possible? Can I write a Silverlight application that uses a 3rd party COM object to do 3d rendering?
No.
but Silverlight beta will have build-in 3D support.. And it will be released around March. (maybe, with MIX08)
|
|
|
|
|
Interesting, thanks for the answer. I had heard several months back that Silverlight would not have WPF's 3d support. This has changed?
|
|
|
|
|
Judah Himango wrote: Interesting, thanks for the answer. I had heard several months back that Silverlight would not have WPF's 3d support. This has changed?
Initially, I also heard that 3D won't be supported in Silverlight in order to make SL "cross-browsers". but I read it somewhere mentioned that we may get 3D with a few limitations in Silverlight since a lot of people request this feature... As I'm not from UX team, I can't say about this for sure. but for the time being, Silverlight need to have a lot of things (data-binding, controls, layout and etc) so 3D won't be on high priority.
I think we might heard something about this in MIX08..
|
|
|
|
|
I am working in the latest preview of blend 2 and i am getting an error that i can't seem to figure out. I have a data template for a gridview column and i am the following error:
Mapping URI 'clr-namespace:Ups_Trak_System;assembly=Ups Trak System' is not valid.
However, in visual studio it compiles fine w/o any errors.
When i take out the Foreground attribute the error goes away so i'm thinking that it somehow can't find the "BrushConverter". Could someone please take a look at this Image[^] of the markup and see if i am doing it right? i would have just posted the markup but when i previewed it it wouldn't display correctly.
Don't be overcome by evil, but overcome evil with good
|
|
|
|
|
I noticed that you're setting the Path to "*".
Any reason you not setting the Path to a DependencyProperty name?
modified 27-Feb-21 21:01pm.
|
|
|
|
|
Hey Karl (btw mole rocks!),
When determining the foreground color i have to look at a couple properties of the object that i am binding to the listview. I found that adding 'Path=.' or 'Path=*' will pass the entire object to the converter class. Just to be sure, I tried it with 'Path=Status' but it didn't resolve the issue.
Don't be overcome by evil, but overcome evil with good
|
|
|
|
|
Thanks for the comments on Mole, really appreciate them.
I just learned more about the WPF Path statement too, thanks!
Can you posted your XAML and Converter code here or just make a screen shot and provide a link so that I can see everything in context.
I'm out for about 2 hours but will get back to you when I return.
modified 27-Feb-21 21:01pm.
|
|
|
|
|
Here you go (thanks again).
using System;
using System.Windows.Media;
using System.Windows.Data;
namespace Ups_Trak_System
{
public class BrushConverter : IValueConverter
{
#region IValueConverter Members
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
SalesAssociate associate = value as SalesAssociate;
if (associate == null) return Brushes.Black;
if (associate.Status.Contains("WITH")) return Brushes.DarkGreen;
else if (associate.Status.Contains("LUNCH")) return Brushes.Blue;
else if (associate.Status.Contains("GUEST")) return Brushes.DarkOrange;
else if (associate.Status.Contains("OFF") && !String.IsNullOrEmpty(associate.ClockOut)) return Brushes.DarkRed;
return Brushes.Black;
}
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
throw new NotImplementedException();
}
#endregion
}
}
Don't be overcome by evil, but overcome evil with good
|
|
|
|
|
Can you post the XAML code too.
modified 27-Feb-21 21:01pm.
|
|
|
|
|
Here you Go[^]. Sorry about that.
Don't be overcome by evil, but overcome evil with good
|
|
|
|
|
I have built a C# project just like yours and it is working here. Didn't have any issues.
What is the exact message you are getting from the Blend?
modified 27-Feb-21 21:01pm.
|
|
|
|
|
Here[^] Is the error message i am getting in blend. If you see the xaml screenshot posted earlier you'll see where the errors are. However, the DataTemplate does actually work and build. but with these errors i can't go rightclick on the listview and edit the other templates or styles.
Don't be overcome by evil, but overcome evil with good
|
|
|
|
|
I see what's up.
Your assembly name is, "Ups Trak System"
Your namespace is, "Ups_Trak_System"
What is the name of your output .dll?
Suggestion.
Name your assembly and name space either, "UpsTrakSystem" or "Ups_Trak_System"
This may be where Blend is all confused.
modified 27-Feb-21 21:01pm.
|
|
|
|
|
Karl, you are the man! I changed the assembly to "Ups", recompiled it, and opened it in blend and it displayed the listviews correctly w/ no errors. Blend doesn't like spaces in the assembly name. Thank you so much for your help i would have never figured it out!
Don't be overcome by evil, but overcome evil with good
|
|
|
|