控件会在iPhone上自动调整ASP.NET的大小 [英] Controls are resized automatically ASP.NET on iPhone

查看:65
本文介绍了控件会在iPhone上自动调整ASP.NET的大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为iPhone开发一个asp.net Web应用程序.当我第一次在iPhone上启动该应用程序时,它看起来还不错,但几分钟后,尽管此后我指定了尺寸,但页面上的所有控件都非常小.将应用程序重新上传到我的服务器并不能解决问题-仅发生在iPhone上.

例如,这是按钮之一:< asp:Button ID ="Button1" runat ="server" Font-Size ="12" OnClick ="Button1_Click1" Text ="Upload" Height ="39px" Width ="82px "/>

开头就是这样: http://i1168.photobucket.com/albums/r493/washingtion1 /2_zps92546931.png [ ^ ]
现在是这样的:
http://i1168.photobucket.com/albums/r493/washingtion1/1_zps82eb6d13.png [ ^ ]

I am working on an asp.net webapp for the iPhone. When I first started the app on my iPhone it looked fine but after a few minutes, and since then, all the controls on the page are very small although I specified sizes. Re-uploading the app to my server didn''t solve the problem - which only occures on the iPhone.

This is one of the buttons for example: <asp:Button ID="Button1" runat="server" Font-Size="12" OnClick="Button1_Click1" Text="Upload" Height="39px" Width="82px" />

This is how it looked at the beginning: http://i1168.photobucket.com/albums/r493/washingtion1/2_zps92546931.png[^]
This is how it looks now:
http://i1168.photobucket.com/albums/r493/washingtion1/1_zps82eb6d13.png[^]

推荐答案

似乎,您已拖动控件,这使css文件受到影响.

您可以快速浏览一下样式表吗?可能您有一些输入类会受到影响.

让我知道是否可以解决.

欢呼
It seems, you have dragged the controls and that gets your css file affected.

Can you have a quick look into the stylesheet. Probably you have some input class that gets affected.

Let me know, if this solves.

cheers


确定-当我查看页面源代码时,我注意到样式属性已添加到页面上的每个控件.我可以通过在原始代码中添加相同的style属性来解决问题.
(顺便说一句,我仍然不明白为什么我的解决方案可以正常工作.)
OK - When I looked at the page source I noticed that a style property was added to every control on the page. I was able to fix my problem by adding the same style property to my original code.
(By the way, I still don''t understand why my solution works exactly.)


这篇关于控件会在iPhone上自动调整ASP.NET的大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆