我是一名软件开发人员,目前我要求为一个不需要安装的零售商开发此类数据管理软件.意味着客户需要预先安装在笔式驱动器中的软件,当我的客户端从任何PC访问该笔式驱动器时,他必须能够访问整个软件而无需任何原因或安装.
我怎么能开发这样的软件?是否可以在.net中开发此类软件(我熟悉它)?
我想通过javascript使用以下代码打印div标签内容.
var divToPrint1 = $('#PrintDoc').html();
var newWin = window.open('Share Certificate #001', '', 'width=10px,height=10px');
newWin.document.open();
newWin.document.write('<html><body onload="window.print();">' + divToPrint1 + '</body></html>');
newWin.document.close();
setTimeout(function () { newWin.close(); }, 10);
Run Code Online (Sandbox Code Playgroud)
打印代码工作正常.但现在我想使用javascript代码从打印中删除网址,日期和标题.可能吗?任何人都可以帮我解决以下问题吗?
我尝试在Android 6.0上的外部SD卡上写一切,但我无法写上它.
我对stackoverflow进行了研究,发现了很多东西,但都没有.这是我的代码
String extPath = System.getenv("SECONDARY_STORAGE") + "/Android/data/com.gvm.externalstorage.externalstoragetest/";
File file = new File(extPath,"myFiles");
if (!file.exists()) {
boolean dirResult = file.mkdirs();
Log.e("Directory Exist", dirResult + " Directory created");
} else {
Log.e("Directory Exist", "Exist");
Log.e("Direcotry Path",file.getAbsolutePath());
}
//String displayname = fileName.replace("%20", " ");
File outputFile = new File(file, "mytest5.txt");
outputFile.createNewFile();
Run Code Online (Sandbox Code Playgroud)
此代码适用于Android 5.0,但不适用于Android 6.0.
然后我也尝试了这个路径,这给了我权限错误,我已经为运行时权限设置了所有权限和托管代码.
/mnt/media_rw/6AC9-083B
File write failed: java.io.IOException: open failed: EACCES (Permission denied)
Run Code Online (Sandbox Code Playgroud)
如果有人可以帮助我,那么在过去的3天里我会这样做很棒.
谢谢,Anvesh