小编Pre*_*gha的帖子

如何修改Google Android代码

我是google android的新手有人请告诉我如何编辑谷歌android代码来开发我自己的应用程序?

android

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

如何分隔名字和姓氏

我将代码名称和姓氏放在同一个字符串中,中间是昏迷,如"JohnSmith"

我需要插入数据库来分开

你能告诉我如何编码吗?

谢谢

维杰

c# database split

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

Visual C#错误:System.Windows.Forms.Button不包含ToInt32的定义

IM在工作decimal,以binary converter完美的作品在控制台上,然后我得到我的核心数学运算,这些错误:

System.Windows.Forms.Button不包含定义,ToInt32并且没有可以找到ToInt32接受类型的第一个参数的扩展方法System.Windows.Forms.Button(您是否缺少using指令或程序集引用?)行:93

方法'ToString'没有重载需要2个参数行:94

System.Windows.Forms.Button不包含'ToInt32'的定义,也没有接受第一个类型为'System.Windows.Forms.Button'的扩展方法'ToInt32'(你是否缺少using指令或者装配参考?)线:103

这是代码:

    public void Convert_Click(object sender, EventArgs e)
    {
        string Input;
        bool IsNotBinary;
        string Answer;
        Start:
        Input = UserInput.Text;
        int InputLength = Input.Length;
        if (InputLength > 10)
        {
            UserInput.Text = "Overflow";
            goto Start;
        }
        int Int;
        bool IsANumber = int.TryParse(Input, out Int);
        if (IsANumber == false)
        {
            UserInput.Text = "Invalid Character";
            goto Start;
        }
        IsNotBinary = Input.Contains("3");
        if (IsNotBinary == true)
        {
            goto End;

        } …
Run Code Online (Sandbox Code Playgroud)

c#

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

C++如何为类中的静态变量赋值?

在VC++ CLR项目中我有一个类temp,我试图将静态变量temp1设置为5.我得到一个编译错误:

错误32错误LNK2020:未解析的令牌(0A0005FB)"public:static int temp :: temp1"(?temp1 @ temp @@ 2HA)C:\ Users\user100\Documents\Visual Studio 2012\NewProject 32 bit\create min bars from data2 \从数据创建最小条形\从data5.obj创建最小条形

错误33错误LNK2001:未解析的外部符号"public:static int temp :: temp1"(?temp1 @ temp @@ 2HA)C:\ Users\user100\Documents\Visual Studio 2012\NewProject 32位\从data2创建最小栏\从数据创建最小条形\从data5.obj创建最小条形

我该如何解决?

class temp
    {
        public:
        static int temp1;
    };

int main(array<System::String ^> ^args)
{

temp::temp1=5;
}
Run Code Online (Sandbox Code Playgroud)

c++ static managed-c++ visual-c++

0
推荐指数
2
解决办法
5179
查看次数

没有构造函数C++的实例

我有个问题.

"IntelliSense:没有构造函数的实例"Tree :: Tree"匹配参数列表的参数类型是:(float [3],float [3],float,float,int,double,int,int)".

第三行:

float ColorS[3]={1,1,1},ColorF[3]={1,0,0};
for(unsigned int i=0;i<20;i++){
    Tree a(ColorS,        ColorF,
           5.0f,          5.0f,
           rand()%180+90, 0.67,
           rand()%4+2,    rand()%6+2);
    las.push_back(a);
    a.cordx=rand()%50-25;
    a.cordz=rand()%50-25;
}
Run Code Online (Sandbox Code Playgroud)

这是我在Tree.h的课程:

class Tree{
.
.
.
Tree(float [3],float [3],float,float,float,int,int);
.
.
.
};
Run Code Online (Sandbox Code Playgroud)

这就是我在Tree.cpp中的建设者:

Tree::Tree(float fromColor[3], float toColor[3], 
           float h=5.0f,       float angle=60*rad,
           float ratio=0.67f,  int amount=4, 
           int maxLevel=5){
.
.
.
Run Code Online (Sandbox Code Playgroud)

===

编辑:现在我有这个问题:

'Tree :: Tree':没有重载函数需要5个参数

第二行:

for(unsigned int i=0;i<20;i++){
Tree a(5.0f,   1.0f,
       0.67f,   rand()%4+2,
       rand()%6+2);
    las.push_back(a);
    a.cordx=rand()%50-25;
    a.cordz=rand()%50-25;
}
Run Code Online (Sandbox Code Playgroud)

这是我在Tree.h中的课程:

class Tree{
    ...
    Tree(float,float,float,int,int); …
Run Code Online (Sandbox Code Playgroud)

c++ constructor class

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

如何使用MD5密码签署我的代码?

回答问题我有点新意,所以请耐心等待.我已经阅读了帖子,我已经看到mysql_已经不再使用了.我知道,所以不要告诉我不要使用它.

无论如何,我有这个代码,每当我尝试使用它注册时,密码都不会在MD5中进行哈希处理.我删除了

$mdhash = md5('$name');
Run Code Online (Sandbox Code Playgroud)

因为我想要你的帮助

这是代码:

<?php

    session_start();

    include('./dbconnect/global.php');

    if (isset ($_POST['submit'])) {
    $comment = mysql_escape_string (trim ($_POST['username']));
    $id = 0;
    $date = date("Y-m-d");
        if(!empty($_POST['username']) && !empty($_POST['password']) && !empty($_POST['email'])){
            if ($_POST['username']=="telamon" or $_POST['username']=="brick") {
                die("This username is banned");
            }
                $name = mysql_escape_string (trim ($_POST['password']));
                $mdehash = md5($name);
                $email = mysql_escape_string (trim ($_POST['email']));
                $picture = $_POST['def'];
                $tweet = 'NoTweetsTweeted';
                $g = mysql_query( "SELECT * FROM admin WHERE username='".$comment."'") or die(mysql_error());

                if (mysql_num_rows($g) >= 1) {
                    $errMsg = "<p style='color:#999999;'>That username …
Run Code Online (Sandbox Code Playgroud)

php mysql md5

-2
推荐指数
1
解决办法
180
查看次数

C# - 将目录中每个文件的名称列入数组?

如何将目录中的文件列入数组?仅限文件,我可以不关心文件夹.我在python中知道它是:

for file in os.listdir('Blah'):
    #BlahBlahBlah
Run Code Online (Sandbox Code Playgroud)

但是,我不确定如何在C#中这样做.谢谢您的帮助!

c# file

-3
推荐指数
2
解决办法
6522
查看次数

标签 统计

c# ×3

c++ ×2

android ×1

class ×1

constructor ×1

database ×1

file ×1

managed-c++ ×1

md5 ×1

mysql ×1

php ×1

split ×1

static ×1

visual-c++ ×1