我有一个应用程序,在一个形式(Form1)我有很多checkBoxes和textBoxes,Form2我只有一个textBox ,但我想从Form1textBoxes中放入一些内容并放在textBox中Form2,像这样,但在表单之间:
textBox1.Text = "Test: " + textBox1 + "\n" + textBox3;
Run Code Online (Sandbox Code Playgroud)
由于textBox1在Form2与第二textBox1和textBox3的Form1,但我怎么能这样做呢?谢谢.
我正在使用Flex构建自己的语言,但我想知道一些事情:
我有一个关于Lazarus的项目,我想用gcc编译一个源代码,为此我有一个TOpenDialog被叫OpenDialog1和一个TProcess被调用的AProcess.
我用这段代码调用gcc:
procedure TFormMain.btCompileClick(Sender: TObject);
begin
if OpenDialog1.Execute then
begin
AProcess := TProcess.Create(nil);
try
AProcess.CommandLine := 'gcc.exe ' + OpenDialog1.FileName;
AProcess.Options := AProcess.Options + [poWaitOnExit, poUsePipes];
AProcess.Execute;
OutputMemo.Lines.BeginUpdate;
OutputMemo.Lines.Clear;
OutputMemo.Lines.LoadFromStream(AProcess.Output);
OutputMemo.Lines.EndUpdate;
finally
AProcess.Free;
end;
end;
end;
Run Code Online (Sandbox Code Playgroud)
它编译好(Lazzarus上的项目),但是当我测试它时,通过尝试编译源test.c,位于C:\Documents and Settings\Nathan Campos\Desktop,我得到了这个OutputMemo:
'C:\ Documents':没有这样的文件或目录
然后,OpenDialog1没有得到空格的完整路径,或者gcc无法在带空格的文件夹上找到它.
有什么建议可以帮助我吗?
我正在构建一个需要打开的程序Form_Create,填充一个TListView被调用FileList的目录,我要填充的目录是编译的程序是+ \Files,因为我从来没用过TListView我想知道如何做到这一点?
我正在使用一个标题colors.h来组织我的源代码.标题是这样的:
#define DEFAULT 0x07
#define BLACK 0
#define GRAY 7
#define BLUE 9
#define GREEN 10
#define CYAN 11
#define RED 12
#define MAGENTA 13
#define YELLOW 14
Run Code Online (Sandbox Code Playgroud)
我将标题放在主要源代码的同一目录中kernel.c,并将其包括在内:
#include <colors.h>
Run Code Online (Sandbox Code Playgroud)
但是当我尝试编译时,我得到了这个:
ubuntu @eeepc:〜/ Development/Test $ gcc -o kernel.o -c kernel.c -Wall -Wextra -nostdlib -nostartfiles -nodefaultlibs
kernel.c:1:20:error:colors.h:没有这样的文件或目录
Ubuntu的@ EeePC的:〜/开发/测试$
我能做些什么来解决这个问题?
我现在正在学习Ruby,因为我看到它是一种非常强大的语言,但现在我想知道我们拥有的Ruby移动端口以及什么设备.
PS:我有HTC S711,HP iPAQ Hx2,诺基亚E61,诺基亚N95,Palm T | X,Palm Z22,HP Jornada 720 ......,如果我可以在这些平台上使用它,那就更好了,但我愿意购买其他设备,因为我是一个移动瘾君子.
我想制作一个简单的脚本,当用户单击"提交"按钮时,从文本框发布推文,但都使用Javascript,没有任何服务器端语言.我怎么能这样做?
我正在尝试在我的C++代码中实现jsoncpp库,我编写了一段简单的代码来试试它,它甚至都没有编译.
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#ifndef json_included
#define json_included
#include "jsoncpp\include\json\json.h"
#endif
//#include "json\jsonC\json.h"
int main(int argc, char **argv)
{
std::string example = "{\"array\":[\"item1\", \"item2\"], \"not an array\":\"asdf\"}";
Json::Value value;
Json::Reader reader;
bool parsed = reader.parse(example, value, false);
std::cout << parsed;
return 0;
}
Run Code Online (Sandbox Code Playgroud)
我得到的错误是:
undefined reference to `Json::Reader::parse(std::string const&, Json::Value&, bool)'
undefined reference to `Json::Reader::Reader()'
undefined reference to `Json::Value::~Value()'
undefined reference to `Json::Value::Value(Json::ValueType)'
Run Code Online (Sandbox Code Playgroud)
我对C++有点新意,在include语句中有什么我想念的吗?或者jsonCpp需要额外的东西吗?
感谢您的时间!
我已经尝试过David Walsh Blog的代码:
<?php
/* connect to gmail */
$hostname = '{imap.gmail.com:993/imap/ssl}INBOX';
$username = 'davidwalshblog@gmail.com';
$password = 'davidwalsh';
/* try to connect */
$inbox = imap_open($hostname,$username,$password) or die('Cannot connect to Gmail: ' . imap_last_error());
/* grab emails */
$emails = imap_search($inbox,'ALL');
/* if emails are returned, cycle through each... */
if($emails) {
/* begin output var */
$output = '';
/* put the newest emails on top */
rsort($emails);
/* for every email... */
foreach($emails as $email_number) { …Run Code Online (Sandbox Code Playgroud) 我正在GitHub上README.mediawiki为我的项目编写一个名为plainBlog的文件,但我想在其上添加一些内联代码.这是什么语法?另外,XML代码的语法是什么(多行)?
内联代码的一个例子位于github/markup,我们有这样的行:gem install wikicloth