|
Working around in some XAML lately and have come across some odd stuff in the way commented code seems to be handled, or rather actually, not handled.
Note: Apparently writing XAML code in the editor is a PITA to get it formatted looking well so you may have to look at my examples a bit...
Just being able to add some typical comments inside some basic XAML looks like so:
<!-- Name Portion [Application Name] -->
<Border x:Name="BrandingBorder" Style="{StaticResource BrandingBorderStyle}">
<StackPanel x:Name="BrandingStackPanel" Style="{StaticResource BrandingStackPanelStyle}">
<!-- Logo Picture -->
<ContentControl Style="{StaticResource LogoIcon}"/>
<!-- Logo Name -->
<TextBlock x:Name="ApplicationNameTextBlock" Style="{StaticResource ApplicationNameStyle}" Text="Application Title Name"/>
</StackPanel>
</Border>
So now, I want to comment out my code as a whole and I try to just wrap my start and end tag inside of its own set of XML comment tags and I get:
<!-- Name Portion [Application Name] -->
<!--
<Border x:Name="BrandingBorder" Style="{StaticResource BrandingBorderStyle}">;
<StackPanel x:Name="BrandingStackPanel" Style="{StaticResource BrandingStackPanelStyle}">;
<!-- Logo Picture -->
<ContentControl Style="{StaticResource LogoIcon}"/>
<!-- Logo Name -->
<TextBlock x:Name="ApplicationNameTextBlock" Style="{StaticResource ApplicationNameStyle}" Text="Application Title Name"/>
</StackPanel>
</Border>
-->
Error = Comments cannot contain two adjacent hyphens '--', Two adjacent hyphens '--' must be followed by a close angle bracket character '>' to terminate the comment.
This however is just fine apparently:
<!-- Name Portion [Application Name] -->
<!--
<Border x:Name="BrandingBorder" Style="{StaticResource BrandingBorderStyle}">
<StackPanel x:Name="BrandingStackPanel" Style="{StaticResource BrandingStackPanelStyle}">
<ContentControl Style="{StaticResource LogoIcon}">
<TextBlock x:Name="ApplicationNameTextBlock" Style="{StaticResource ApplicationNameStyle}" Text="Application Title Name"/>
<StackPanel>
</Border>
-->
It just seems really odd that the editor seems to have such an issue with the commenting stuff when you are using multiple comment lines:
<!-- Name Portion [Application Name] -->
<!-- <Border x:Name="BrandingBorder" Style="{StaticResource BrandingBorderStyle}"> -->
<!-- <StackPanel x:Name="BrandingStackPanel" Style="{StaticResource BrandingStackPanelStyle}"> -->
<!-- Logo Picture -->
<!-- <ContentControl Style="{StaticResource LogoIcon}"> -->
<!-- Logo Name -->
<!-- <TextBlock x:Name="ApplicationNameTextBlock" Style="{StaticResource ApplicationNameStyle}" Text="Application Title Name"> -->
<!-- </StackPanel> -->
<!-- </Border> -->
What a real pain...
|
|
|
|
|
It isn't the editor - it is the XML specification that deems it not possible to have -- within a comment.
I agree, it is a PITA
___________________________________________
.\\axxx
(That's an 'M')
|
|
|
|
|
That is very well spotted, I must admit I had never noticed it before either.
------------------------------------
I will never again mention that I was the poster of the One Millionth Lounge Post, nor that it was complete drivel. Dalek Dave
CCC League Table Link
CCC Link[ ^]
|
|
|
|
|
Guys, I use a style sheet to display a div as a modal dialog.
It used to work correct but it goes under objects other than HTML just like Flash objects.
i used:
.modalBackground {
background-color:Gray;
filter:alpha(opacity=70);
opacity:0.7;
}
Help people,so poeple can help you.
|
|
|
|
|
I have updated your CSS class
.modalBackground {
background-color:Gray;
filter:alpha(opacity=70);
opacity:0.7;
position:absolute;
z-index:1000;
}
Thanks,
Imdadhusen
sunaSaRa Imdadhusen
+91 99095 44184
+91 02767 284464
|
|
|
|
|
Thank you, man.
But as you might notice, I have sent 'A hundred of flowers' and you face them with only one.
the remaining will be 99 . Send them back to me!
Help people,so poeple can help you.
|
|
|
|
|
now you got the solution?
sunaSaRa Imdadhusen
+91 99095 44184
|
|
|
|
|
Sir;
I wasn't aware about z-index then as i was new to web development. So, thank you!
100 , man!!
Help people,so poeple can help you.
|
|
|
|
|
Hello,
I'm struggling with my login form.
http://www.softkom.cz/Schedule/Login.aspx
Why the SELECT element has a different width than other INPUT elements?
Thank you for any idea.
Best regards,
Milan Kotaska
info@softkom.cz
|
|
|
|
|
Seems odd too.. have not noticed that recently...
You could try just setting the width of the container it is in and then setting the width of each thing that goes into the grid space to be 100% of that. Might help keep things more consistent.
|
|
|
|
|
Problem is in DOCTYPE, I replaced DOCTYPE in the source of the link provided by you with the following :
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
and it makes "select" elements of same width as the input element.
|
|
|
|
|
Dear All,
I have to displayed Indian rupee symbol in my crystal report. i have style sheet which convert "Rs." and ~ to Indian rupee.
currently I am displaying in Rs.. how to incorporate javascript or stylesheet in crystal report.
Pl help you would appreciated.
Regards,
Pankaj
|
|
|
|
|
|
The team I am part of has been developing data visualization tools for desktop environment for more than a couple of decades now and has been extremely successful with it. Now we are planning to move into the web world.
The graphics module uses many statistical routines, which we plan to expose as a web service owing to several requests from potential clients. That means the graphics engine would also use the very same web services.
Keeping all these in mind along with how interactive the tools must be, I thought Silverlight would be the best choice. Also because we need the tools to run on Apple and Linux distros, like desktop versions, it seems attractive to code just once.
However, googling some phrases like "is silverlight dead" etc makes me wonder if it is going to be worthy to invest in. Yet, I can't see any other solution.
What do you recommend?
FYI, all our tools are in C++ and using Silverlight would mean rewriting in C# but that's acceptable.
Signature is a waste of time. I'll have one when I've got enough time to create. Well, I had enough a few seconds back.
|
|
|
|
|
Silverlight is not dead. The rumors are generally from disgruntled and/or uninformed people. IMO Silverlight is an excellent platform for your requirements. Something else to consider is JavaScript and the rise of HTML5. There is a considerable amount that can be done with JavaScript without the need to have Plugins such as Silverlight. HTML5 is gaining more acceptance and availability in browser support also.
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
I would take a look at the HTML5 canvas tag.
Chris J
www.redash.org
|
|
|
|
|
I have a menu on a webpage that I'm starting to develop. When the user hovers over certain menu items it pops up a horizontal menu/image. The popup is an image split via Map Area tags. The reason being is if the user clicks on the top of the image they get redirected to one link, if they click the bottom of the image they go to a different link.
My problem occurs when the user is in the popup menu and moves the cursor from Map area to Map area. The popup menu disapears when you go inbetween them
I have the meta code up and running if someone wants to take a look at it here[^] I commented the code so its easier to understand.
Heres a breakdown of the flow of code:
Someone hovers over the image:
<tr> <td><a href="#" onMouseOver="display_menu(this,'menuLocations',-40,210,'menuMenu',0)"><img src="images/TabLocations.jpg" alt="Locations" name="Locations" width="235" height="42" border="0"></a></td> </tr>
Which calls this JScript Sub upon onMouseOver. The Sub displays a popup image
function display_menu(parent,named,xOffset,yOffset,HideMe,HideMe2)
{
var menu_element = document.getElementById(named);
menu_element.style.display = "";
var placement = findPos(parent);
menu_element.style.top = (placement[1] + xOffset ) +"px";
menu_element.style.left = (placement[0] + yOffset) +"px";
Above JScript displays this Div popup:
<div class="popup" id="menuLocations" style="display:none;">
<table width="161" height="68" border="0" align="left" cellpadding="0" cellspacing="0" id="Table_300">
<tr><td><a href="#" onMouseOut="hide_menu('menuLocations')"><IMG SRC="images/TabKuCalMap.jpg" ALT="" BORDER=0 WIDTH=161 HEIGHT=68 USEMAP="#mapHome"></a></td></tr>
</table>
</div>
Which is split via this Map Area:
<MAP NAME="mapHome">
<area shape="rect" coords="0,0,161,34" alt="Ku_Home" href="Ku_Home.html" />
<area shape="rect" coords="0,34,68,161" alt="Cal_Home" href="Cal_Home.html" />
</MAP>
When the user is hovering in one Area and moves to the other Area the popup closes. . .
Does anyone know what I can do to debug this?
|
|
|
|
|
I mean,the url sent back from server should be
http:
But,my program shows
http:
The question is,how should I hide the extension name ".com" of my cgi application under IIS?
|
|
|
|
|
|
I have some table gaps that I can't get rid of and it's driving me insane. Can someone shed some light on why this is happening?
I've simplified my code to just a boarder and nothing else:
<table width="1160" height="600" border="0" align="left" cellpadding="0" cellspacing="0" id="Table_blah">
<tr><td rowspan ="1" colspan="15"><img src="images/HorSeparator.jpg" width="1160" height="16" alt=""></td></tr>
<tr><td rowspan="14"><img src="images/VertSeparator.jpg" alt="" width="11" height="584"></td></tr>
</table>
SOLVED:
Turns out the gap was caused by my opening tags:
<!DOCTYPE html>
<html lang="en">
Does anyone know how they can cause table gaps
modified on Sunday, January 30, 2011 9:32 PM
|
|
|
|
|
I took your markup, made a couple of images to match yours and took a look. I don't see any gaps. Perhaps you have a style sheet that's affecting things?
If that's not the case, maybe you could describe what you're seeing - that may help diagnose the problem.
Cheers,
Drew.
|
|
|
|
|
Thanks for the reply My style sheet is very simple, I doubt that is affecting it, but I'll look into it.
Here's a snapshot of Explorers' and Chromes' rendering of my table:
http://tinypic.com/r/2guei2s/7[^]
It dosent look like much but that 3 pixle gap on the left really messes things up.
Thanks for the input Drew. If you didnt suggest that the problem could be outside of the table I wouldn't of figured out that the problem was caused by my opening tags
<!DOCTYPE html><html lang="en">
modified on Sunday, January 30, 2011 10:46 PM
|
|
|
|
|
Glad I could help!
Cheers,
Drew.
|
|
|
|
|
I am developing a web site that is going to be heavy in custom content and is very database driven. I want all the features (and some smartphone specific features) of the web site available to hand held devices. Now I have been absent from the programing scene for many years now. Ok So my question is what would be the best language to develop everything in. can I do it all in php and ajax or should I use c# and asp.net so I can use C# to develop the handheld apps. I know it's a loaded question but I really am at a loss on witch would be best and why.
|
|
|
|
|
There is no correct answer to a which language is best question. There are far too many variables. What language are you most comfortable with? Who will maintain the code in the future? What does the host support? Are there features one language supports and the other does not? Plus many, many more.
A database driven content management web application with mobile support describes what SharePoint is. There are also other pre-built packages and frameworks to do this so the question may be not which language to use but rather is it more economical to use one of these packages (don't forgot to factor in maintenance and support) or write it yourself.
I know the language. I've read a book. - _Madmatt
|
|
|
|