SunTaag  
Front Page
Tag | Location | Media | Guestbook | Admin   
 
'Programming'에 해당하는 글(6)
2018.06.26   Visual Studio 에서 0xC00000FD: Stack overflow 대처하기
2016.04.05   Textbox Automatic Scroll to Bottom
2015.07.06   매트랩 figure 창 최대화(크기 조절)
2015.05.31   URL, URLConnection in Java
2014.08.25   Textbox ctrl + A
2014.07.29   PHP를 이용한 MySQL Database 생성


Visual Studio 에서 0xC00000FD: Stack overflow 대처하기


C코드에 float 2^14, 2^15 개짜리 배열 생성했더니 Stack overflow 발생


메모리에서 스택영역이 부족하단 소리인데...


Heap 영역으로 옮겨도 되지만 동적메모리 할당은 귀찮음


VS에서 디폴트로 제공하는 스택 메모리 크기는 1MB!


그래서 늘려주면됨






1. 프로젝트 우클릭 -> 속성



2. 구성 속성 -> 링커 -> 시스템 -> 스택 예약 크기



Byte 단위로 써줘야되서

10MB = 10 * 1024 * 1024 = 10485760(대략 천만) 으로 수정





Textbox Automatic Scroll to Bottom

textBox.SelectionStart = textBox.Text.Length;

textBox.ScrollToCaret();

'Programming > C#' 카테고리의 다른 글

Textbox ctrl + A  (0) 2014.08.25


매트랩 figure 창 최대화(크기 조절)

figure(); set(gcf,'units','normalized','outerposition',[0 0 1 1]);


뒤에 [0 0 1 1] 행렬은 아래와 같이

각 요소는 화면 전체 비율에서 백분율을 뜻한다.





URL, URLConnection in Java

import java.net.*;

import java.io.*;

 

public class URLRead {

public static void main(String[] args) throws Exception {

URL ocu = new URL("http://shiptaek.tistory.com/");

BufferedReader in = new BufferedReader(new InputStreamReader(ocu.openStream()));

String inputLine;

while ((inputLine = in.readLine()) != null)

System.out.println(inputLine);

in.close();

}

}

 

 

 

 

 

 

 

import java.net.*;

import java.io.*;

public class URLConnectionRead {

public static void main(String[] args) throws Exception {

URL ocu = new URL("http://shiptaek.tistory.com/");

URLConnection con = ocu.openConnection();

BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));

String inputLine;

while ((inputLine = in.readLine()) != null)

System.out.println(inputLine);

in.close();

}

}




Textbox ctrl + A


        private void textBox1_KeyDown(object sender, KeyEventArgs e)

        {

            if (e.Control && e.KeyCode == Keys.A)

            {

                textBox1.SelectAll();

            }

        }

'Programming > C#' 카테고리의 다른 글

Textbox Automatic Scroll to Bottom  (0) 2016.04.05


PHP를 이용한 MySQL Database 생성

<?

/* Database 정보 */

$host = "localhost";

$user = "root";

$pass = "********";

$database = "experiment";

$tbl_tutor "subject";

/* MySQL 접속 */

$db = mysql_connect($host,$user,$pass) or die("서버 접속 에러 in create_table.php");

$sql "create database ".$database;

// 쿼리를 실행해서 결과값을 $result에 할당

$result = mysql_query($sql, $db);

if(!$result) // 데이터베이스 생성결과가 오류이면

{

echo "error) ".$sql."<br>";

echo mysql_errno()." : ".mysql_error()."<br>";

}

else

echo $database." 데이터베이스가 작성되었습니다.<br>";

echo "<br>";


/* Database 선택 */

mysql_select_db($database,$db);


/* 테이블 생성*/

$sql="create table ".$tbl_tutor."(".

"name text not null,".

"age int not null,".

"birth_year int not null,".

"gender varchar(1) not null,".

"address text not null,".

"phone text not null".

")";


// 쿼리를 실행해서 결과값을 $result에 할당

$result = mysql_query($sql, $db);

if(!$result) // 테이블 생성결과가 오류이면

{

echo "error) ".$sql."<br>";

echo mysql_errno()." : ".mysql_error()."<br>";

}

else

echo $tbl_tutor." 테이블이 작성되었습니다.<br>";

echo "<br>";


?>



BLOG main image
 Notice
 Category
분류 전체보기 (20)
Algorithm (3)
Signal Processing (0)
Programming (6)
Research (1)
Youtube (2)
ETC. (8)
 TAGS
 Calendar
«   2025/05   »
1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31
 Recent Entries
 Recent Comments
 Archive
 Link Site
 Visitor Statistics
Total :
Today :
Yesterday :
rss