我按照本教程创建GridView:
这一行:
imageView.setLayoutParams(new GridView.LayoutParams(85, 85));
Run Code Online (Sandbox Code Playgroud)
尺寸85x85非常适合我的Wildfire,但在HTC Desire上看起来很小.如何根据屏幕更改图像大小?
我有2种不同的布局,但Gridview
XML文件中没有任何属性来更改图像大小.
Jrunscript有一个'print'
功能.然而,它没有打印任何有用的对象.例如:
js> var obj = {one:1, two:2}
Run Code Online (Sandbox Code Playgroud)
在评估对象Jrunscript
输出时,只需:
js> obj
[object Object]
Run Code Online (Sandbox Code Playgroud)
而且'print'
也不好:
js> print(obj)
[object Object]js>
Run Code Online (Sandbox Code Playgroud)
Jrunscript
可以使用哪些函数来打印对象结构?
在javascript上使用Regex验证tridion TCM ID,看起来很简单但不幸的是我没有这样做.
我尝试了所有可能的方法来验证tcm id.
以下是最后一次尝试的正则表达式: -
(tcm:(\d)+-(\d)+(-16|-4|-64))\W
Run Code Online (Sandbox Code Playgroud)
在这里,TCM ID
可以是component
或SG
或Page
.
有效的tcm id是
请建议最好的正则表达式来验证tcm id.
我尝试使用xml文件和代码将阴影添加到自定义字体,但没有任何成功
我的代码是
TextView text=(TextView)findViewById(R.id.text1);
Typeface tf = Typeface.createFromAsset(getAssets(), "fonts/gillsans.ttf");
text.setTypeface(tf);
Run Code Online (Sandbox Code Playgroud) 登录Tridion时出现以下错误.请你帮助我好吗.
Error: Retrieving the COM class factory for component with CLSID {9926D1CF-F158-418F-A9A2-B653B497D982} failed due to the following error:
8000401a The server process could not be started because the configured identity is incorrect.
Check the username and password. (Exception from HRESULT: 0x8000401A).
System.Runtime.InteropServices.COMException (0x8000401A): Retrieving the COM class factory for component with CLSID {9926D1CF-F158-418F-A9A2-B653B497D982} failed due to the following error:
8000401a The server process could not be started because the configured identity is incorrect.
Check the username and password. (Exception from …
Run Code Online (Sandbox Code Playgroud) 我们设置了tridion来发布到两个服务器 - 发布目标设置为两个位置.
当我们尝试使用第二个环境测试CME服务器发布到服务器时,它正在发布,并且页面中正在生成组件链接标记.从第一个envirnment-dev CME服务器发布时,组件链接标记未在页面中生成.记录以下错误
WARN Admin - WAI: Could not find a presentation for SiteIdentifier[Protocol=http; Domain=*.*.*.*; Port=****; Path=/HTTPUpload.aspx]
2012-12-18 05:19:28,351 ERROR UserManager - No Data Access Object for Personalization
com.tridion.broker.StorageException: No Data Access Object for Personalization
at com.tridion.storage.filesystem.FSDAOFactory.getDAOForTypeMapping(FSDAOFactory.java:177) ~[cd_datalayer.jar:na]
at com.tridion.storage.StorageManagerFactory.getOriginalDAO(StorageManagerFactory.java:450) ~[cd_datalayer.jar:na]
at com.tridion.storage.StorageManagerFactory.getDAO(StorageManagerFactory.java:271) ~[cd_datalayer.jar:na]
at com.tridion.storage.StorageManagerFactory.getDefaultDAO(StorageManagerFactory.java:178) ~[cd_datalayer.jar:na]
at com.tridion.user.UserManager.checkUser(UserManager.java:56) ~[cd_wai.jar:na]
Run Code Online (Sandbox Code Playgroud)
事件查看器也在显示
Can't initialize application heartbeat monitoring: 0x80040154
Source:
SetupThreadHeartbeat
Run Code Online (Sandbox Code Playgroud)
我得到"不支持给定路径的格式." 当我只是尝试从我的SDL Tridion 2011 SP1下载多媒体图像时,下面是我得到的路径,不知道"N:"等即将到来.
D:\ delete\Images\N:\ dmc.FlipMedia.Clients.TestCMS\2009_WorkInProgress\creatives\05_May\16岁以下儿童免费访问英国\ assets_graphics\jpg\Kids_go_free_385x306.jpg
以下是代码:
public static void GetBinaryFromMultimediaComponent(string tcm, CoreServiceClient client, StreamDownloadServiceClient streamDownloadClient)
{
ComponentData multimediaComponent = client.ReadItem(tcm) as ComponentData;
// Generate you own file name, and file location
string file = "D:\\delete\\Images\\" + multimediaComponent.BinaryContent.Filename;//Here I am getting above path
// Write out the existing file from Tridion
FileStream fs = File.Create(file);//Here getting the exception
byte[] binaryContent = null;
if (multimediaComponent.BinaryContent.FileSize != -1)
{
Stream tempStream = streamDownloadClient.DownloadBinaryContent(tcm);
var memoryStream = new MemoryStream();
tempStream.CopyTo(memoryStream); …
Run Code Online (Sandbox Code Playgroud) 我想在javascript或jquery中复制本地存储概念(类似于HTML5).
但不幸的是,我不知道如何开始这个.
任何人都可以建议如何使用javascript或jquery(不使用HTML5)实现本地存储?
以下是我的要求.
@echo off
cls
Set Sleep=0
:start
echo This is a loop
xx.exe yyyyy.dll /p:InputDataSource=Table:table.xml
Set /A Sleep+=1
echo DisplayingSleepvalue
echo %Sleep%
goto start
Run Code Online (Sandbox Code Playgroud)
在这里,我想要执行xx.exe yyyyy.dll /p:InputDataSource=Table:table.xml
此行30次 ....任何人都可以帮助我.
谢谢,
Manasa
我真的不知道,问题是什么?我收到以下错误:
File "C:\Python27\lib\xml\dom\expatbuilder.py", line 223, in parseString
parser.Parse(string, True)
ExpatError: junk after document element: line 5, column 0
Run Code Online (Sandbox Code Playgroud)
我不见JUNK!有帮助吗?我疯了......
text = """<questionaire>
<question>
<questiontext>Question1</questiontext>
<answer>Your Answer: 99</answer>
</question>
<question>
<questiontext>Question2</questiontext>
<answer>Your Answer: 64</answer>
</question>
<question>
<questiontext>Question3</questiontext>
<answer>Your Answer: 46</answer>
</question>
<question>
<questiontext>Bitte geben</questiontext>
<answer>Your Answer: 544</answer>
<answer>Your Answer: 943</answer>
</question>
</questionaire>"""
cleandata = text.split('<questionaire>')
cleandatastring= "".join(cleandata)
stripped = cleandatastring.strip()
planhtml = stripped.split('</questionaire>')[0]
clean= planhtml.strip()
from xml.dom import minidom
doc = minidom.parseString(clean)
for question in doc.getElementsByTagName('question'):
for answer in question.getElementsByTagName('answer'):
if …
Run Code Online (Sandbox Code Playgroud) tridion ×4
tridion-2011 ×3
android ×2
javascript ×2
batch-file ×1
dropshadow ×1
gridview ×1
html-parsing ×1
image ×1
image-size ×1
jquery ×1
minidom ×1
object ×1
python ×1
regex ×1
textview ×1