我正在尝试为Chrome(版本34.0.1847.131 m)安装GWT Developer插件,我收到以下错误"此计算机不支持此应用程序.安装已被禁用.检测到以下问题:"和"NPAPI插件是这个应用程序所必需的".有没有解决的办法?
我已按照一个答案的建议安装了Microsoft Visual C++ 2008 SP1 Redistributable Package.
我也试图在Explorer(版本11)中运行,它要求我下载Firefox的GWT Developer插件.然后,需要在新窗口中打开内容.然后我选择打开"gwt-dev-plugin.xpi".当它完成下载后,它要求我保存它(如果我打开它只是再次下载).有没有解决的办法?
我在Windows 8.1上运行.
我正在使用代码加载图像(请参见下文)我通过stackoverflow找到了.但是,我现在注意到"getWidget()"已被弃用.而不是等到这个不再可用,我想现在解决这个问题.我该怎么用而不是"getWidget()"?
// Add a finish handler which will load the image once the upload finishes
existingdefaultUploader.addOnFinishUploadHandler(onReplaceFinishUploaderHandler);
existingdefaultUploader.getFileInput().getWidget().setStyleName("customButton");
existingdefaultUploader.getFileInput().getWidget().setSize("100px", "20px");
Run Code Online (Sandbox Code Playgroud)
问候,
格林
我试图更新数据库一旦我更改RichTextBox并退出RichTextBox(即,我不想强迫用户按"更新按钮").但是,我的代码The method addValueChangeHandler(new ValueChangeHandler<String>(){}) is undefined for the type RichTextArea在第一行抛出异常.
textBoxExistingDescription.addValueChangeHandler(new ValueChangeHandler<String>() {
public void onValueChange(ValueChangeEvent<String> event) {
//If a record for this Youth Member specific detail line exists then update it else add it.
if (ymAwardDetails.getYmsdId() != null) {
AsyncCallback<Void> callback = new YMSpecificHandler<Void>(ScoutAwardView.this);
rpc.updateYMSpecific(ymAwardDetails.getYmsdId(), ymAwardDetails.getYmsdDetail(), callback);
}else{
AsyncCallback<Void> callback = new YMSpecificHandler<Void>(ScoutAwardView.this);
rpc.addYMSpecific(youthMemberID, ymAwardDetails.getAdId(), ymAwardDetails.getYmsdDetail(), callback);
}
}
});
Run Code Online (Sandbox Code Playgroud)
有没有另外一种方法可以做到这一点?
我有一个创建数据透视表的MS Excel宏。在数据透视表中,我要过滤多个项目。因此,首先需要将所有项目设置为false,然后将要包括的项目设置为true。所以目前我有:
With ActiveSheet.PivotTables("PivotTable2").PivotFields("Test Cycle")
.PivotItems("FXA BI_MH Pre UAT C1").Visible = False
.PivotItems("FXA BI_MH Pre UAT C2").Visible = False
.PivotItems("FXA Reg C1").Visible = False
.PivotItems("MC3").Visible = False
.PivotItems("PT Cycle 1").Visible = False
.PivotItems("Regression Test (APO)").Visible = False
.PivotItems("SIT CR").Visible = False
.PivotItems("SIT Cycle 2").Visible = False
.PivotItems("UAT - Data Conv").Visible = False
.PivotItems("UAT Pre-Test - Additional").Visible = False
.PivotItems("UAT Pre-Test - Final").Visible = False
.PivotItems("UAT Pre-Test - Iteration 2").Visible = False
End With
ActiveSheet.PivotTables("PivotTable2").PivotFields("Test Cycle"). _
EnableMultiplePageItems = True
Run Code Online (Sandbox Code Playgroud)
但是,“测试周期”项会更改,如果引入了新项,则会自动包含在内,因为我尚未将其设置为false。有没有一种方法可以将所有选择都设置为false,类似(不起作用): …
我正在尝试向 jQuery .validate 添加一个方法来检查 Summernote(所见即所得编辑器)文本区域是否为空,并且我无法触发该方法(我放置在其中的警报不显示)。控制台中没有错误。
方法是:
//Add validation method to check for an empty Award Description
$.validator.addMethod("htmlEditorEmpty", function(value, element) {
alert("checking");
return this.optional(element) || value.summernote('isEmpty');
}, "Please enter details");
Run Code Online (Sandbox Code Playgroud)
这是由(这项工作之前和之后的其他验证)调用的:
awardDescription: {
htmlEditorEmpty: true,
maxlength: 1500,
},
Run Code Online (Sandbox Code Playgroud)
检查 HTML:
<div class="col-lg-3 col-md-3 col-sm-3 col-xs-3">
<div class="form-group">
<div>
<textarea class="summernote" id="awardDescription" name="awardDescription" rows="3"></textarea>
</div>
</div>
</div>
Run Code Online (Sandbox Code Playgroud)
我已将其放置在submitHandler 中:
if ($('#awardDescription').summernote('isEmpty')) {//using id
alert('contents is empty1');
}
if ($('awardDescription').summernote('isEmpty')) {//using name
alert('contents is empty2');
}
Run Code Online (Sandbox Code Playgroud)
第一个有效(即,仅在为空时显示),而第二个始终显示(即,即使输入值时)。我包含此信息是因为我相信 .validate 使用名称而不是 id。我可能错了。
我刚安装了GWT 2.6,现在收到错误"描述资源路径位置类型文件war\WEB-INF\lib\gwt-servlet.jar与GWT SDK库gwt-servlet.jar的大小不同;也许是一个不同的版本?gwt-servlet.jar/AwardTracker/war/WEB-INF/lib未知的Google Web Toolkit问题"
我下载了GWT 2.6 zip,然后将目录"GWT-2.6.0"复制到"Eclipse\eclipse-jee-juno-SR1-win32\eclipse\plugins"中.然后我右键单击该项目并选择"properties/Google/Web Toolkit/Configure SDKs .../Add".然后我浏览了"GWT-2.6.0"目录,添加并选中它.
我按照Braj的解决方案,并在重新编译时收到以下错误:
编译模块org.AwardTracker.AwardTracker验证单元:在第一遍中忽略了2个带有编译错误的单元.使用-strict或-logLevel进行编译设置为TRACE或DEBUG以查看所有错误.计算'gwtupload.client.DecoratedFileUpload.DecoratedFileUploadImpl'的所有可能重新绑定结果重新绑定gwtupload.client.DecoratedFileUpload.DecoratedFileUploadImpl无法找到完全匹配规则.使用基于后退值的"最接近"规则.您可能需要实现特定绑定,以防后备行为不替换'gwtupload/client/DecoratedFileUpload.java'中缺少的绑定[错误]错误[错误]第347行:重新绑定结果'gwtupload.client.DecoratedFileUpload.DecoratedFileUploadImpl '不能抽象
通过下载gwtupload-1.0.1.jar,使用"Add External JARS"将其添加到库并删除旧的gwtupload-0.6.6.jar来解决上述问题.然后我重新编译并编译工作.但是,现在我的"MyCustomisedUploadServlet"出现了错误(之前没有出现此错误):
protected static final String XML_ERROR_ITEM_NOT_FOUND = "<" + TAG_ERROR + ">item not found</" + TAG_ERROR + ">";
Run Code Online (Sandbox Code Playgroud)
其余代码是:
package org.AwardTracker.server;
import gwtupload.server.UploadAction;
import gwtupload.server.exceptions.UploadActionException;
import gwtupload.shared.UConsts;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.util.Hashtable;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.commons.fileupload.FileItem;
/**
* This is an example of how to use UploadAction class.
*
* This servlet saves all received files in …Run Code Online (Sandbox Code Playgroud) 我发送一封包含HTML文本和附件的电子邮件并收到错误消息:
java.io.UnsupportedEncodingException: text/html
Run Code Online (Sandbox Code Playgroud)
代码是:
public void emailMessage(String emailSubject, String message, String emailaddress, String imagePath) {
//Send an email
try {
//Send an email
SimpleEmail email = new SimpleEmail();
email.setHostName("mail.org");
email.setSmtpPort(25); //No authentication required
email.setFrom("address.org");
email.addTo(emailaddress);
email.setSubject(emailSubject);
email.setCharset("utf-8");
// Set the email message text.
MimeBodyPart messagePart = new MimeBodyPart();
messagePart.setText(message, "text/html");
// Set the email attachment file
FileDataSource fileDataSource = new FileDataSource(imagePath);
MimeBodyPart attachmentPart = new MimeBodyPart();
attachmentPart.setDataHandler(new DataHandler(fileDataSource));
attachmentPart.setFileName(fileDataSource.getName());
// Create Multipart E-Mail.
MimeMultipart multipart = new MimeMultipart();
multipart.addBodyPart(messagePart);
multipart.addBodyPart(attachmentPart); …Run Code Online (Sandbox Code Playgroud) 我正在使用MS Excel 2007和Microsoft Visula Basic 6.5.
我想在工作表中选择一行,然后使用宏在此工作表和其他三个工作表中插入一行.我正在尝试下面的代码但是当我运行它时,我在"工作表"("Rel.计划会议")上得到错误"运行时错误'1004':应用程序定义或对象定义错误".范围(Lst).启用".
Sub Copy1()
Dim Lst As Long
'save the rowNo
Lst = ActiveCell.Row
Worksheets("Rel. Planning Meeting").Activate
Worksheets("Rel. Planning Meeting").Range(Lst).Activate
ActiveCell.EntireRow.Insert
Worksheets("Master Release Plan - HTSTG").Activate
Worksheets("Master Release Plan - HTSTG").Range(Lst).Activate
ActiveCell.EntireRow.Insert
Worksheets("Inst. Gateway").Activate
Worksheets("Inst. Gateway").Range(Lst).Activate
ActiveCell.EntireRow.Insert
Worksheets("CAB").Activate
Worksheets("CAB").Range(Lst).Activate
ActiveCell.EntireRow.Insert
Worksheets("Rel. Planning Meeting").Range("A3:G5000").Copy _
Destination:=Worksheets("Master Release Plan - HTSTG").Range("A3")
Worksheets("Master Release Plan - HTSTG").Range("A3:O5000").Copy _
Destination:=Worksheets("Inst. Gateway").Range("A3")
Worksheets("Inst. Gateway").Range("A3:T5000").Copy _
Destination:=Worksheets("CAB").Range("A3")
End Sub
Run Code Online (Sandbox Code Playgroud)
我已经尝试过"Dim Lst As Range"然后我得到错误"运行时错误'91':对象变量或With block变量未设置"on"Lst = ActiveCell.Row".
非常感谢您的帮助.
问候,
格林
新守则:
Sub …Run Code Online (Sandbox Code Playgroud) 下面的代码需要27秒才能加载51张图像,每张图像约为22 KB(我插入的开始和结束警报之间的时间间隔).是否有可能使它更有效率(我希望它在3秒内得到它)?
起初我以为是数据库,所以我把警报放进去确认并发现它是这个代码.
问候,
格林
public void renderYMAwardsTable(List<YouthMemberAwards> ymAwardsList) {
if (!ymAwardsList.isEmpty()) {
flexTableLink.clear();
int linkRow = 0;
int linkCol = 0;
flexTableLeadership.clear();
int leadershipRow = 0;
int leadershipCol = 0;
flexTableBoomerang.clear();
int boomerangRow = 0;
int boomerangCol = 0;
flexTableAchievement.clear();
int achievementRow = 0;
int achievementCol = 0;
flexTableSpecialInterest.clear();
int specialInterestRow = 0;
int specialInterestCol = 0;
totalAwards = 0;
Window.alert("Start populating page.");
for (final YouthMemberAwards ymAwards : ymAwardsList) {
// Display awards and, if applicable, date awarded
if …Run Code Online (Sandbox Code Playgroud) java ×6
gwt ×5
eclipse ×2
excel ×2
excel-vba ×2
vba ×2
email ×1
gwtupload ×1
html ×1
html-email ×1
jquery ×1
summernote ×1
validation ×1