小编mox*_*mlb的帖子

Postgresql数据库导出到.sql文件

我想将我的数据库导出为.sql文件.有人能帮我吗?我发现的解决方案不起作用.请详细说明.在Windows 7上.谢谢

postgresql postgresql-9.1

14
推荐指数
3
解决办法
3万
查看次数

我如何比较Swift 3中的两个日期(NSDate)并获得它们之间的日子?

如何比较Swift 3中的两个日期?我找到了许多其他Swift版本的解决方案,但它们对我不起作用.

let clickedDay:String = currentcell.DayLabel.text!
    let currentDate = NSDate()
    let currentDay = "" //want the current day
    let dateFormatter = DateFormatter()        
    var dateAsString = ""        
    if Int(clickedDay)! < 10 {            
        dateAsString = "0" + clickedDay + "-11-2016 GMT"
    }
    else {            
        dateAsString = clickedDay + "-11-2016 GMT"
    }

    dateFormatter.dateFormat = "dd-MM-yyyy zzz"
    let clickedDate = dateFormatter.date(from: dateAsString)        
    if currentDate as Date >= clickedDate! as Date {

        return true
    }
    else {
        //Want to get the days between the currentDate …
Run Code Online (Sandbox Code Playgroud)

xcode nsdate date-comparison swift swift3

7
推荐指数
1
解决办法
9896
查看次数

C#从目录读取文件夹(名称)

我有以下代码:

        string directory;
        FolderBrowserDialog fbd = new FolderBrowserDialog();
        if (fbd.ShowDialog() == System.Windows.Forms.DialogResult.OK)
        {
            directory = fbd.SelectedPath;

            txtSource.Text = directory;

            DirectoryInfo d = new DirectoryInfo(directory);
            FileInfo[] Files = d.GetFiles();

            List<String> str = new List<string>();
            foreach (FileInfo file in Files)
            {
                str.Add(file.Name);
            }
        }
Run Code Online (Sandbox Code Playgroud)

我在FolderBrowseDialog其中选择文件夹的路径。在此选定的文件夹中还有3个其他文件夹。我想读出这些文件夹的名称。我不想知道或读出文件名。

.net c# folderbrowserdialog

5
推荐指数
2
解决办法
7884
查看次数

停用 css/html 中的“element.style”?

我在 Chrome 开发者工具窗口的“样式”选项卡中看到以下 css 代码:

element.style {
    height: auto;
    width: 100%;
    margin-top: -148px;
}
Run Code Online (Sandbox Code Playgroud)

我想用 .css 文件中的 css 代码覆盖它:

.so-widget-sow-simple-masonry-simple-masonry-d75171398898 .sow-masonry-grid-item img {
    width: auto;
    height: 244px;
    margin-top: 0px;
    margin-left: auto;
    margin-right: auto; 
}
Run Code Online (Sandbox Code Playgroud)

但样式定义element.style已经存在了。我找不到 .js 这么快。有人能帮我吗?谢谢

html javascript css siteorigin

3
推荐指数
1
解决办法
6202
查看次数

如何获取 TextField 输入以及为什么滚动时输入重复?

我像这样创建 TableViewCells:

 override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
    let cell = tableView.dequeueReusableCell(withIdentifier: "ErnaehrungTableViewCell", for: indexPath) as! ErnaehrungTableViewCell
    let row = indexPath.row
    cell.LabelType.text = cellValues[indexPath.row]
    cell.TextValue.keyboardType = .decimalPad
    cell.TextValue.tag = indexPath.row

    cell.selectionStyle = .none
    cell.ButtonUnit.addTarget(self, action: #selector(ErnaehrungManualController.ButtonUnitClick), for: .touchUpInside)
    cell.ButtonUnit.tag = indexPath.row`
Run Code Online (Sandbox Code Playgroud)

LabelType 是一个标签,TextValue 是一个文本字段,ButtonUnit 是一个按钮。它看起来像这样: 在此处输入图片说明

如果我在前五个 TextField 中输入(如图所示)并滚动,则输入也位于其他行中。

我该如何解决?

如果我按下右上角的按钮 (Fertig),那么我想阅读所有 TextFields 的文本。我有这个代码,但我不工作:

for var i in 0...cellValues.count-1 {
        let indexPath = IndexPath(row: i, section: 0)
        let cell = tableView.dequeueReusableCell(withIdentifier: "ErnaehrungTableViewCell", for: indexPath) as! ErnaehrungTableViewCell …
Run Code Online (Sandbox Code Playgroud)

xcode textfield ios swift

1
推荐指数
1
解决办法
1582
查看次数