关闭

如何取LR web_reg_sava_param的值

332人阅读 评论(0) 收藏 举报
Action()
{
int x,j;
char cname[20];

x=web_reg_save_param ("data",
                    "LB=username=",
                    "RB=,",
                    "Ord=ALL",
                    LAST);
    web_url("lrdemo",
        "URL=http://localhost:8088/lrdemo",
        "Resource=0",
        "RecContentType=text/html",
        "Referer=",
        "Snapshot=t1.inf",
        "Mode=HTML",
        LAST);
  x=atoi(lr_eval_string("{data_count}"));
  lr_error_message("the length:%d",x);
for(j=1;j<=x;j++){
    sprintf(cname,"{data_%d}",j);
    lr_error_message(lr_eval_string(cname));
   // lr_error_message("data in %d is %s",j,lr_eval_string(cname));
                    
}

//lr_error_message("%s",lr_eval_string("{data_count}"));
    //lr_error_message(lr_eval_string("{data_1}"));
    // lr_error_message(lr_eval_string("{data_2}"));

    return 0;
}

--------------------华丽的分割线-------


Action()
{
int x,j;
char cname[20];

x=web_reg_save_param ("data",
                    "LB=username=",
                    "RB=,",
                    "Ord=ALL",
                    LAST);
    web_url("lrdemo",
        "URL=http://localhost:8088/lrdemo",
        "Resource=0",
        "RecContentType=text/html",
        "Referer=",
        "Snapshot=t1.inf",
        "Mode=HTML",
        LAST);
  x=atoi(lr_eval_string("{data_count}"));
  lr_error_message("the length:%d",x);
for(j=1;j<=x;j++){
    sprintf(cname,"{data_%d}",j);
    if(strcmp(lr_eval_string(cname),"peter")==0){
        lr_error_message ("peter exists.............................");
    }else{
        lr_error_message(lr_eval_string(cname));
        lr_error_message ("peter never exists.........................");
    }
    lr_error_message(lr_eval_string(cname));
   // lr_error_message("data in %d is %s",j,lr_eval_string(cname));
                    
}

//lr_error_message("%s",lr_eval_string("{data_count}"));
    //lr_error_message(lr_eval_string("{data_1}"));
    // lr_error_message(lr_eval_string("{data_2}"));

    return 0;
}
0
0

查看评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
    个人资料
    • 访问:109926次
    • 积分:1481
    • 等级:
    • 排名:千里之外
    • 原创:16篇
    • 转载:148篇
    • 译文:0篇
    • 评论:3条
    最新评论