Thread View: fj.lang.visualbasic
3 messages
3 total messages
Started by Akira Gotoh
Sun, 18 Jan 1998 00:00
Plus!の導入判定方法はありませんか?
Author: Akira Gotoh
Date: Sun, 18 Jan 1998 00:00
Date: Sun, 18 Jan 1998 00:00
11 lines
861 bytes
861 bytes
はじめまして。 MSのWin95用のPlus!が導入されているか否かの判定方法は ないでしょうか? レジストリのキーでも結構ですし、アプリケーションの インストール情報を知る方法でも結構です。 使用言語はVB5です。 後藤あきら (foxlum@cyborg.or.jp)
Re: Plus!の導入判定方法はありませんか?
Author: Takeshi Shigihara
Date: Mon, 19 Jan 1998 00:00
Date: Mon, 19 Jan 1998 00:00
45 lines
2268 bytes
2268 bytes
WIN32 API の SystemParametersInfo に SPI_GETWINDOWSEXTENSION
というフラグがあります。
私は、VBを知らないので、VBでの宣言を記述することができません。
とりあえず、オンラインマニュアルからC言語での関数宣言を引き写し
ておきます。
BOOL SystemParametersInfo(
UINT uiAction, // system parameter to query or set
UINT uiParam, // depends on action to be taken
PVOID pvParam, // depends on action to be taken
UINT fWinIni // user profile update flag
);
SPI_GETWINDOWSEXTENSION Windows 95 only:
Indicates whether the Windows extension, Windows Plus!, is installed.
Set the uiParam parameter to 1. The pvParam parameter is not used.
The function returns TRUE if the extension is installed,
or FALSE if it is not.
引数 uiAction には SPI_GETWINDOWSEXTENSION を
引数 uiParam には 1をセットします。
pvParam は使われません。
(また、fWinIni は FALSE を与えれば良いでしょう。)
関数から真が返る場合、Plus!がインストールされており、
偽の場合にはインストールされていません。
Akira Gotoh wrote:
>
> はじめまして。
>
> MSのWin95用のPlus!が導入されているか否かの判定方法は
> ないでしょうか?
> レジストリのキーでも結構ですし、アプリケーションの
> インストール情報を知る方法でも結構です。
>
> 使用言語はVB5です。
>
> 後藤あきら (foxlum@cyborg.or.jp)
----- Takeshi Shigihara
OFFICE cygnus@masternet.or.jp
HOME cygnus@po.jah.ne.jp --------
Re: Plus!の導入判定方法はありませんか?
Author: Akira Gotoh
Date: Mon, 19 Jan 1998 00:00
Date: Mon, 19 Jan 1998 00:00
37 lines
1997 bytes
1997 bytes
Takeshi Shigihara wrote: >WIN32 API の SystemParametersInfo に SPI_GETWINDOWSEXTENSION >というフラグがあります。 > >私は、VBを知らないので、VBでの宣言を記述することができません。 >とりあえず、オンラインマニュアルからC言語での関数宣言を引き写し >ておきます。 レスありがとうございました。 早速試してみました。結果はOKです。 これから悩むかもしれない方(いないかも)のために実験したコードを 紹介しておきます。VBでの宣言も次の通りです。 Public Const SPI_GETWINDOWSEXTENSION = 92 Declare Function SystemParametersInfo Lib "user32" _ Alias "SystemParametersInfoA" ( _ ByVal uAction As Long, _ ByVal uParam As Long, _ ByVal lpvParam As Any, _ ByVal fuWinIni As Long) As Long 'PLus!のインストールを判定する関数例(Windows 95 Only) Public Function IsInstalledPlus() As Boolean If SystemParametersInfo(SPI_GETWINDOWSEXTENSION, _ 1, ByVal 0&, 0) <> False Then IsInstalledPlus = True End If End Sub IsInstalledPlus関数を呼び出して、インストールされていたらTrueを、 インストールされていなかった場合にはFalseを返します。 今回は有り難うございました。 後藤あきら (foxlum@cyborg.or.jp)
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads