Hi , I am trying to save the output of "help('tkinter')" in a text file. But i get error. I want to know if there is a Way to get the output of help file redirected to a file , or save in a variable. By the way , the code i tried was this .It pretty basic try . [CODE]>>> file1=open("C:\\Documents and Settings\\achowdhury\\Desktop\\Help xlrd.txt",'w') >>> file1.writelines(help('xlrd'))[/CODE] I get the output as the full help of the module, followed by error , [COLOR="red"] Traceback (most recent call last): File "<pyshell#12>", line 1, in <module> file1.writelines(help('xlrd')) TypeError: writelines() requires an iterable …

Member Avatar
Member Avatar
+0 forum 4

I have a problem with this code. Why this shows random symbols when i give view data ! ?[CODE]#include<iostream> #include<conio.h> #include<windows.h> #include "gotoxy.h" #include<cstdio> #include<cstring> #include<cstdlib> #include<fstream.h> using namespace std; //function declarations void out(char *); void matrix(int,int); class student { public: //class variable declaration in public part int roll,fee,ht,wt; char adminno[10],name[30],yn,imark[30],save,blood[10],n[30],age[3],sch[300],clas[10],s[7],address[50],fn[30],mn[30], joinclass[10],secondlang[10],primlang[10],ph[15],mobil[11],fo[20],mo[20],brosis[30],date[9],time[9],dob[9],fpos; //constructor student() { roll=ht=wt=0; strcpy(primlang,"English"); } // Getting student information from user void adform() { top: fflush(stdin); system("cls"); out ("\n Admission Number : "); cin >> adminno; fflush(stdin); out (" Student's name : "); gets(n); fflush(stdin); out(" Class Joining : "); gets(joinclass); out(" Primary Language : English\n"); fflush(stdin); …

Member Avatar
Member Avatar
+0 forum 10

I am currently having problems displaying a file correctly once i have written a dictionary to the file. For this program the input file needs to have the format: ID: Date: Dayskept: ProductName e.g. 1:12/12/2011:12:A This is fine the first time I read the example file into a dictionary, but once i save the dictionay into a new file and try to open this file i get the output: 1:"date":12/12/2011, "life":12, "name":A Is there an easy way to format the data in the dictionary before it is written to file? Thanks for any advice given :) [CODE]def loadProduct(fileName): global cheeseDictionary …

Member Avatar
Member Avatar
+0 forum 6

Hi, I have a web application using JBoss, Java and struts. I've managed to upload the file using struts, but is it possible to view the data from the uploaded file BEFORE inserting the data into database? or do I need to store them into a temp database first, then view the data, then insert them into the real database? Thanks in advance.

Member Avatar
+0 forum 0

Hi guys, I've been searching for hours now and haven't yet found a good source of C# information for what I need to do. The general gist is this: I have 1 Client app (a simple windows form which gathers data) and 1 Server console app (which holds the business logic) The client needs to send a file (which is a serialized class object called info.sco) to the server and then call a specific server method on that file. Example: User enters data into a form on the client app Client app adds the data to a custom class User …

Member Avatar
Member Avatar
+0 forum 2

Good morning all, i have a text file contains following data..... sec TID ATTRIBUTE 69013 1-3039-1 REGISTER 69013 1-3039-1 100 69013 1-3039-1 401 69013 1-3039-2 REGISTER 69013 1-3039-2 100 69013 2-3039-1 REGISTER 69013 3-3039-1 REGISTER 69013 4-3039-1 REGISTER 69013 1-3039-2 200 69013 2-3039-1 100 69013 2-3039-1 401 .................. .................. 69023 193-3039-2 100 69023 193-3039-2401 69023 222-3039-1 REGISTER 69023 177-3039-2 100 69024 177-3039-2401 69024 214-3039-1 100 69024 214-3039-1 401 69024 214-3039-2 REGISTER 69024 223-3039-1 100 69024 223-3039-1 401 69024 223-3039-2 REGISTER ...................................................................................... i want an REG. , 401 and 200 arrays which contains TIDs values for first 10 seconds, that is …

Member Avatar
Member Avatar
+0 forum 1

i have written a program in c++ using the concept of file handling. this program is about managing a basic electronic hardware store stock and showing the sales report. i am not able to understand why the [B]contents of my file are not being displayed, modified, deleted, or even printing the bill or sales report[/B]... though i have tried to find answers to my problems in the previous threads i have not achieved much.. please read the code and suggest the necessary editing.. your help will be highly appreciated.. [CODE] #include<iostream> #include<fstream> //#include<conio> #include<string.h> #include<iomanip> #include<cstdio> using namespace std; class …

Member Avatar
Member Avatar
+0 forum 4

I have a project to have a file read using argc and argv. Then sort it and do some other things. I'm having trouble with the very first step. Loading the file. This is what I have so far. Any help you be great. [CODE] #include <stdio.h> #include <stdbool.h> void openFile(int argc, char *argv[]); int main(int argc, char *argv[]) { openFile(argc, argv); printf("\n\n"); return 0; } void openFile(int argc, char *argv[]) { int i; printf("\nThe number of arguments is %d", argc); printf("\nThe name of the program is %s", argv[0]); for ( i = 1; i < argc; i++) printf("\nUser value …

Member Avatar
Member Avatar
+0 forum 6

Hello all, I am attempting to write a program that takes the filenames of a number of files in a folder and sends the filenames to a text file. I am using freepascal compiler, can anyone help me?

Member Avatar
+0 forum 0

I am trying to create a program to log the medal tally of the cwg. However,I'm still getting wind of using binary files. It seems as if nothing is being read from or written into them. Below is my entire code. It would be of help if somone could direct me as to what it is I've done wrong here. [CODE]#include<fstream.h> #include<conio.h> #include<stdio.h> #include<string.h> #include<dos.h> class contestant { char name[20]; char country[20]; char sex[10]; int age; int badminton; int archery; int swim; int wrestling; int boxing; int weightlft; int tennis; int shooting; int tt; int athletics; public: contestant() { badminton=0; …

Member Avatar
Member Avatar
+0 forum 3

When my code (below) is executed, a error message is triggered which says "The operation completed successfully." To give this some context, hFileMap is valid; I have checked this with my debugger, and other operations can easily be performed correctly on this handle that yield correct results. The only weird thing is that MapViewOfFile returns a null pointer. Since I use this memory mapped file as a way of communicating between two applications, this function is critical. Please note that I am no beginner to coding, and this same program successfully implements multi-threading as well as on-the-fly (dynamic) function creation …

Member Avatar
Member Avatar
+0 forum 2

Hi I have to develop a code for file configuration in PHP. My basic text file is stored in C:\abc my text file name format is Mobile#_Code.request Example: 923135470808_9033.request Now I want to read code 9033 from the name of text file which always be there after _ and before .request After getting code I will get data from MySQL DB and want to put this result in the form of message in the text file like "Hi 9033 your remaining balance is 50USD" Now after putting message in same file I want to rename the file name as 923135470808_9033.done …

Member Avatar
Member Avatar
+0 forum 5

hi i am writing a program that reads integers(signed or unsigend) from file. my input file contains these numbers(without brackets) [41 35 -66 -124 -31 108 -42 -82 82 -112 73 -15 -15 -69 -23] and my code is: [CODE]#include <stdlib.h> #include <stdio.h> #include <conio.h> #include <string.h> main() { FILE * hFile; int c; long n = 0; hFile = fopen("input15Numbers.txt", "r"); if (hFile == NULL) { printf("Failed to Open the File"); } else { while (!feof(hFile)) { c = fgetc (hFile); if (c != ' ') { fscanf (hFile, "%i", &c); printf("%i", c); printf("\n"); } fclose(hFile); getch(); } }[/CODE] …

Member Avatar
Member Avatar
+0 forum 1

The End.