Skip to content

Instantly share code, notes, and snippets.

View fortheday's full-sized avatar
🤩

magicpotato fortheday

🤩
View GitHub Profile
// (WindowsInternet + VCL + MP_LIB 사용)
//---------------------------------------------------------------------------
#include <vcl.h>
#include <wininet.h>
#include <stdio.h>
#include "mp_File.h"
#include "MainForm.h"
#pragma comment (lib, "wininet.lib")
//---------------------------------------------------------------------------
#pragma resource "*.dfm"
// 기본형
#include <shellapi.h>
#include <shlobj.h>
ShellExecute(Handle, "open", "http://magicpotato.com/p", NULL, NULL, SW_SHOWDEFAULT);
// [용주] 음...저건 이미 띄어진 익스플로어창이 있다면 거기서 뜨는 문제가 있고 무조건 익스플로어 새창을 띄어서 하고 싶다면 요론식으로....
{
ShellExecute(NULL, "open", "IEXPLORE.EXE", "http://magicpotato.com/p", NULL, SW_SHOW);
// C++Builder code
struct sockaddr_in addr;
SOCKET s;
int i;
memset(&addr, NULL, sizeof(struct sockaddr));
addr.sin_family = AF_INET;
addr.sin_addr.s_addr = INADDR_ANY;
addr.sin_port = htons(0);
auto usHi = *(WORD *)"Hi";